Most Popular
1500 questions
25
votes
5 answers
What language should I use when teaching an undergraduate course in computer programming?
Going to teach students of undergraduate level a course titled Introduction to Computer Programming. I am confused a bit. In Computational Physics scientists use C/C++ or Python or Fortran,CUDA etc..... this is time to build their base. What should…
Afnan Bashir
- 353
- 3
- 6
25
votes
2 answers
Libraries for solving sparse linear systems
There are a number of different libraries out there that solve a sparse linear system of equations, however I'm finding it difficult to figure out what the differences are.
As far as I can tell there are three major packages: Trilinos, PETSc, and…
Andrew Spott
- 1,155
- 1
- 9
- 22
24
votes
8 answers
Software package for constrained optimization?
I am looking to solve a constrained optimization problem where I know the bounds on some of the variables (specifically a boxed constraint).
$$ \arg \min_u f(u,x) $$
subject to
$$ c(u,x) = 0 $$
$$ a \le d(u,x) \le b $$
where $u$ is a vector of…
Sean Farley
- 1,370
- 12
- 16
24
votes
3 answers
Intel Fortran Compiler: tips on optimization at compilation
I will start with my personal experience in our lab. Back in the ifort 9 and 10 days, we used to be quite aggressive with the optimizations, compiling with -O3 and processor specific flags (-xW -xSSE4.2 for example). But starting with ifort 11, we…
FrenchKheldar
- 1,308
- 1
- 9
- 22
24
votes
4 answers
Algorithms for (adaptive?) function plotting
I am looking for algorithms to draw standard 2d-graphs for functions that may or may not have singularities. The purpose is to write a "Mini-CAS", so I have no a priori knowledge of the types of functions, the users want to graph.
This problem is…
soegaard
- 345
- 3
- 13
24
votes
1 answer
What is the general idea of Nitsche's method in numerical analysis?
I know that the Nitsche's method is a very attractive methods since it allows to take into account Dirichlet type boundary conditions or contact with friction boundary conditions in a weak way without the use of Lagrange multipliers. And its…
Anh-Thi DINH
- 801
- 2
- 8
- 14
24
votes
3 answers
Using unconventional programming languages for scientific computation
Note: the following post may include controversial opinions, so please
note that they are only my opinions, and not intended to offend
anyone.
I'm being programming in some form or the other since around 1999. I
initially used R, and then later,…
Faheem Mitha
- 731
- 5
- 14
24
votes
4 answers
When do orthogonal transformations outperform Gaussian elimination?
As we know, orthogonal transformations methods (Givens rotations and Housholder reflections) for systems of linear equations are more expensive than Gaussian elimination, but theoretically have nicer stability properties in the sense that they do…
faleichik
- 1,832
- 13
- 23
24
votes
2 answers
Discontinuous Galerkin: Nodal vs Modal advantages and disadvantages
There are two general approaches to representing solutions in the discontinuous galerkin method: nodal and modal.
Modal: Solutions are represented by sums of modal coefficients multiplied by a set of polynomials, e.g. $u(x,t) = \sum_{i=1}^N u_i(t)…
Aurelius
- 2,365
- 1
- 15
- 19
23
votes
3 answers
Can diagonal plus fixed symmetric linear systems be solved in quadratic time after precomputation?
Is there an $O(n^3+n^2 k)$ method to solve $k$ linear systems of the form $(D_i + A) x_i = b_i$ where $A$ is a fixed SPD matrix and $D_i$ are positive diagonal matrices?
For example, if each $D_i$ is scalar, it suffices to compute the SVD of $A$. …
Geoffrey Irving
- 3,969
- 18
- 41
23
votes
6 answers
Future of OpenCL?
The OpenCL programming paradigm promises to be a royalty free opens standard for heterogenous computing. Should we invest our time in developing software based on OpenCL? Pros/cons?
Allan P. Engsig-Karup
- 3,226
- 19
- 31
23
votes
1 answer
Why is Newton's method not converging?
I am using PETSc's nonlinear solver package SNES to solve a system of nonlinear equations obtained by discretizing a partial differential equation. How can I determine why the solver is not converging and what can I do to successfully solve my…
Jed Brown
- 25,650
- 3
- 72
- 130
23
votes
9 answers
Basic explanation of shape function
I just started studying FEM in a more structured basis compared to what I used to do during my undergraduate courses. I am doing this because, despite the fact that I can use the "FEM" in commercial (and other non-commercial) software, I would like…
Alfonso Santiago
- 332
- 1
- 2
- 7
22
votes
2 answers
What simple methods are there for adaptively sampling a 2D function?
I have a two-dimensional function $f(x,y)$ whose values I would like to sample. The function is very expensive to compute and it has a complex shape, so I need to find a way to get the most information about its shape using the least number of…
Szabolcs
- 2,620
- 2
- 19
- 34
22
votes
4 answers
The definition of stiff ODE system
Consider an IVP for ODE system $y'=f(x,y)$, $y(x_0)=y_0$. Most commonly this problem is considered stiff when Jacobi matrix $\frac{\partial f}{\partial y}(x_0,y_0)$ has both eigenvalues with very large negative real part and eigenvalues with very…
faleichik
- 1,832
- 13
- 23