[petsc-users] Get solution and rhs in the ts monitor

Tang, Qi tangqi at msu.edu
Thu Nov 10 02:18:32 CST 2022


Hi,

How could I get rhs and solution in a ksp solve of ts?

I am testing a linear problem (TS_Linear) using a bdf integrator. I tried to get the operator, rhs, and solution in the ts monitor through TSGetKSP and KSPGet***. But r = Ax-b is much larger than the ksp norm. I know the solver works fine.

Did I misunderstand something about how TS works here? Perhaps one of the vectors is changed after the ksp solve? If so, is there a simple way to get rhs and solution that ksp of ts solved?

Thanks,
Qi


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20221110/7a54456b/attachment.html>


More information about the petsc-users mailing list