On Sun, Jan 1, 2017 at 1:00 PM, Barry Smith <[email protected]> wrote:

>
>    What are LandSNESFunction() and LandSNESJacobian()?
>

These are the same methods that I give to TS (IFunction and IJacobian),
 except there is no mass matrix in IJacobian. What do I do here? I do not
have a shift.

But I see that IFunction is not correct. I am solving du/dt - C(u) = 0.  My
IFunction applies C(u)*u, but LandSNESFunction should just return zero,
maybe?




>
>    Note that Picard
>
>        Solves the equation A(x) x = b(x) via the defect correction
> algorithm A(x^{n}) (x^{n+1} - x^{n}) = b(x^{n}) - A(x^{n})x^{n}
>
>    The functions you need to provide are (compute the vector) b(x)  and
> (compute the matrix) A(x).   A() is most definitely not the Jacobian of
> b(). To use Picard you have to rewrite the nonlinear equations that come
> out of the definition of the time-step in the form A(x) x = b(x).  This may
> require additions to TS, I don't know.
>
>    Barry
>
>
>
> > On Jan 1, 2017, at 8:56 AM, Mark Adams <[email protected]> wrote:
> >
> > I tried using Picard inside of TS, and SNES diverged. Is this supposed
> to be possible?  I tried to do do this by wrapping my operator in a SNES
> version and simply adding it like this.
> >
> > Mark
> >
> >   ierr = TSSetIFunction(ts,NULL,LandIFunction,ctx);CHKERRQ(ierr);
> >   ierr = TSSetIJacobian(ts,J,J,LandIJacobian,ctx);CHKERRQ(ierr);
> >     SNES snes;
> >     Vec vec;
> >     ierr = VecDuplicate(uu,&vec);CHKERRQ(ierr);
> >     ierr = TSGetSNES(ts,&snes);CHKERRQ(ierr);
> >     ierr = SNESSetPicard(snes, vec, LandSNESFunction, J, J,
> LandSNESJacobian, ctx);CHKERRQ(ierr);
> >
>
>

Reply via email to