Sorry 
http://www.mcs.anl.gov/petsc/petsc-dev/docs/manualpages/SNES/SNESMonitorSet.html


On Mar 18, 2014, at 10:56 PM, Mani Chandra <[email protected]> wrote:

> I can't find SNESSetMonitor in petsc-dev. I get the following error even 
> after including petscsnes.h
> 
> error: ‘SNESSetMonitor’ was not declared in this scope
> 
> Moreover, there is no manpage for it on the petsc-dev SNES website: 
> http://www.mcs.anl.gov/petsc/petsc-dev/docs/manualpages/SNES/index.html
> 
> Has it been removed?
> 
> 
> On Tue, Mar 18, 2014 at 9:11 PM, Barry Smith <[email protected]> wrote:
> 
> On Mar 18, 2014, at 7:54 PM, Mani Chandra <[email protected]> wrote:
> 
> > The residual of the system of equation that I feed into TS with 
> > TSSetIFunction. I have a system of equations and I want to probe where most 
> > of the residual is coming from. The reason is that after certain time of 
> > evolution, the initial residual at the beginning of each time step 
> > increases by orders of magnitude than what it used to be at the beginning 
> > of the time step at early times. For ex, say at t=200, the SNES norm at the 
> > beginning of a TS timestep with the theta method would be something like 
> > 1.0812 and at t = 300, it would be 2e5 at the beginning. SNES then has to 
> > work much harder to reach the abs norm levels and so I want to investigate 
> > what is happening.
> 
>    So this is the initial residual in the nonlinear solve. 
> -snes_monitor_residual works for plotting if it is 2d otherwise write your 
> own custom SNES monitor routine and call TSGetSNES, SNESSetMonitor().
> 
>    Barry
> 
> >
> >
> > On Tue, Mar 18, 2014 at 7:48 PM, Jed Brown <[email protected]> wrote:
> > Mani Chandra <[email protected]> writes:
> >
> > > Is there anyway I can get the residual at the beginning of the time step? 
> > > I
> > > tried TSSetPreStage and TSSetPreStep but they didn't work. Setting
> > > TSSetPreStage would crash the program even if there is nothing in the
> > > routine that I set and TSSetPreStep would give me the residual at the end
> > > of the previous time step. I want to take a look at the residual at the
> > > beginning of the new time step before the nonlinear solver starts.
> >
> > Residual of what?  What are you going to do with it?
> >
> 
> 

Reply via email to