All Questions
1,029
questions
8
votes
1
answer
6k
views
Computational methods for finding the energy eigenvalues of the time-independent Schrodinger equation with arbitrary potential
I have seen in some papers that the energy levels in some arbitrary potential are specified. How can one find the energy levels in such arbitrary potentials. For example, $V(x)=\sin^2(x/2)$ with $x\in[...
58
votes
4
answers
9k
views
What guidelines should I follow when choosing a sparse linear system solver?
Sparse linear systems turn up with increasing frequency in applications. One has a lot of routines to choose from for solving these systems. At the highest level, there is a watershed between direct (...
68
votes
10
answers
16k
views
What are some good strategies for improving the serial performance of my code?
I work in computational science, and as a result, I spend a non-trivial amount of my time trying to increase the scientific throughput of many codes, as well as understanding the efficiency of these ...
172
votes
8
answers
141k
views
Recommendations for a usable, fast C++ matrix library?
Does anyone have recommendations on a usable, fast C++ matrix library?
What I mean by usable is the following:
Matrix objects have an intuitive interface (ex.: I can use rows and columns while ...
30
votes
2
answers
16k
views
Why is my iterative linear solver not converging?
What can go wrong when using preconditoned Krylov methods from KSP (PETSc's linear solver package) to solve a sparse linear system such as those obtained by discretizing and linearizing partial ...
29
votes
1
answer
7k
views
Conservation of a physical quantity when using Neumann boundary conditions applied to the advection-diffusion equation
I don't understand the different behaviour of the advection-diffusion equation when I apply different boundary conditions. My motivation is the simulation of a real physical quantity (particle density)...
10
votes
1
answer
5k
views
full rank update to cholesky decomposition
Let $A$ be a real, symmetric, positive definite matrix. It has at least 500 rows, possibly much more. I compute its Cholesky decomposition, which allows me to calculate
$det(A)$
$A^{-1}X$ for some ...
50
votes
2
answers
13k
views
What does "symplectic" mean in reference to numerical integrators, and does SciPy's odeint use them?
In this comment I wrote:
...default SciPy integrator, which I'm assuming only uses symplectic methods.
in which I am refering to SciPy's odeint, which uses ...
18
votes
6
answers
2k
views
How to reorder variables to produce a banded matrix of minimum bandwidth?
I'm trying to solve a 2D Poisson equation by finite differences. In the process, I obtain a sparse matrix with only $5$ variables in each equation. For example, if the variables were $U$, then the ...
16
votes
1
answer
5k
views
How can I estimate the condition number of a large sparse matrix using PETSc?
I have a PETSc Mat and would like to estimate its condition number.
78
votes
5
answers
21k
views
How much better are Fortran compilers really?
This question is an extension of two discussions that came up recently in the replies to "C++ vs Fortran for HPC". And it is a bit more of a challenge than a question...
One of the most often-heard ...
43
votes
18
answers
3k
views
Where can one obtain good data sets/test problems for testing algorithms/routines?
In evaluating the quality of a piece of software you are about to use (whether it's something you wrote or a canned package) in computational work, it is often a good idea to see how well it works on ...
23
votes
3
answers
3k
views
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 ...
9
votes
3
answers
11k
views
Poisson equation finite-difference with pure Neumann boundary conditions
I'm trying to solve a 1D Poisson equation with pure Neumann boundary conditions. I've found many discussions of this problem, e.g.
1) Poisson equation with Neumann boundary conditions
2) Writing the ...
6
votes
1
answer
1k
views
Meshing options to generate number of the sides of and element (tetgen-triangle)
I wrote a finite element code in fortran 90.
This code is really fast, except the meshing process.
I used triangle and tetgen for meshing in 2D and 3D, respectively, so this process is fast, of ...