On Thursday, October 20, 2016 at 9:48:55 PM UTC-5, Wolfgang Bangerth wrote:

    What is the norm of the first right hand side? You now set the tolerance in

    the first iteration to a fixed value of 1e-16, but how does this compare to
    the previous value of 1e-12*system_rhs.l2_norm()?


The system_rhs.l2_norm() before the first call to CGSolverat in the zero time
step was 1.82492e-09, so that the 1e-12*system_rhs.l2_norm() became in the
order of 1e-21 by which CGSOlver didn't converge.

OK. I have no suggestion, though, why one or the other would lead to convergence or non-convergence of CG.


    That still seems wrong to me. As I mentioned in a previous email, you
    ought to
    make sure that the matrix you build is the matrix you *want* to build.


I was wondering how to make sure the matrix I built is what I meant.

You need to compare properties of your bilinear form with those of your matrix. For example, if your bilinear form is symmetric, then your matrix is as well -- and that is something you can test. If your bilinear form is positive definite, then your matrix needs to be as well and as a consequence CG needs to converge. If CG does not seem to converge but your bilinear form is s.p.d., you know you have a bug in your matrix assembly. If CG converges on one processor but not on two for the same problem, then you know you have a bug in the parallel matrix assembly. Etc.

Since you haven't stated your bilinear form or the problem you are solving, I can't tell you whether the matrix is supposed to be s.p.d.

Best
 W.


--
------------------------------------------------------------------------
Wolfgang Bangerth          email:                 [email protected]
                           www: http://www.math.colostate.edu/~bangerth/

--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to