I have a sparse system (about 78% of zero entries) that is complex and symmetric (but not Hermitian). The following figure shows the structure of the problem. The off-diagonal blocks are incidence matrices, the diagonal blocks are dense complex matrices with elements whose absolute value ranges from $1 \times 10^{-14}$ to $1 \times 10^{3}$.
I've built a code using PETSc (made sure to configure --with-scalar-type=complex
), it compiles and runs, but the solver either diverges or, if converged, gives nonsensical results.
The version of the code that uses dense routines (LAPACK, no PETSc) gives the expected results. The structure of the matrix generated by PETSc (see figure above) is as expected. The right hand side is zero except for a single entry (the first). The worst condition number I've seen for that system is $1\times 10^{7}$; but its, usually, $1\times 10^{4}$.
To solve that particular type of problem (sparse complex symmetric, not Hermitian), what is the recommended method (solver) to use? Can I use it with PETSc?
This answer mentions that
For complex problems, iterative methods are considerably less robust compared to direct methods.
Why is that?
Additional info that may be relevant
No preconditioning is used. Also, when I configure PETSc --with-scalar-type=real
, the system gives somewhat correct results with Minimum Residual method (MINRES) when the imaginary part of the system is small compared to the real.