[petsc-users] Control Output of '-ksp_view_mat binary'
Matthew Knepley
knepley at gmail.com
Thu Nov 17 09:35:43 CST 2016
On Thu, Nov 17, 2016 at 8:32 AM, Robert Annewandter <
robert.annewandter at opengosim.com> wrote:
> Hi,
>
> Is there a way to fine tune '-ksp_view_mat binary' so it only gives me an
> output at a defined time?
>
> I'm implementing a Two-Stage Preconditioner for PFLOTRAN (a subsurface
> flow and transport simulator which uses PETsc). Currently I like to compare
> convergence of the preconditioning in PFLOTRAN against a prototyped version
> in MATLAB. In PFLOTRAN I export the Jacobian, and residual before they get
> handed-over to PETsc, which get imported in MATLAB to do the Two-Stage
> Preconditioning.
>
> However, I know I can do exports closer to PETsc with the options
> '-ksp_view_mat binary' and '-ksp_view_rhs binary'. Unfortunately I get
> outputs for the whole simulation in one file, instead of only at a
> well-defined Newton-Raphson iteration (as done in PFLOTRAN).
>
> Is there a way to tell PETsc with above options when to export the
> Jacobian and residual?
>
> Any pointers much appreciated!
>
It sounds like you could give the particular solve you want to look at a
prefix:
http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPSetOptionsPrefix.html
and then give
-myprefix_ksp_view_mat binary
Thanks,
Matt
> Thank you!
> Robert
>
--
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20161117/200d0c5e/attachment.html>
More information about the petsc-users
mailing list