[petsc-users] Dynamically changing coarse and levels DMMG preconditioners

Joey Hegarty Joey.Hegarty at al.com.au
Wed Aug 11 18:19:41 CDT 2010


Thanks Matt / Jed for the rapid reply, that's what I was looking for.

Cheers,
Joey

From: petsc-users-bounces at mcs.anl.gov [mailto:petsc-users-bounces at mcs.anl.gov] On Behalf Of Matthew Knepley
Sent: Wednesday, 11 August 2010 11:57 AM
To: PETSc users list
Subject: Re: [petsc-users] Dynamically changing coarse and levels DMMG preconditioners

On Tue, Aug 10, 2010 at 8:46 PM, Joey Hegarty <Joey.Hegarty at al.com.au<mailto:Joey.Hegarty at al.com.au>> wrote:
Hi folks,

I'm looking for a way to update the coarse and levels preconditioners used during the DMMG solve after PETSc has been initialized.

I can update some options dynamically like so:

       KSP ksp = DMMGGetKSP(dmmg);
       KSPSetTolerances(ksp, ...);
       KSPGMRESSetRestart(ksp, ...);

But I do not see a clear way of updating the coarse and levels preconditioner types in a similar way.  Am I missing something obvious?  Apologise if this has been asked before.

dmmg is just an array. DMMGGetKSP() is a macro that does

  dmmg[L-1].ksp

for a DMMG of L levels. For the coarse level, you can use dmmg[0]. We should have something
better, but this will work for now.

  Matt

Cheers,
Joey



--
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/20100812/d0c82192/attachment.htm>


More information about the petsc-users mailing list