SNESReset#

Resets a SNES context to the snessetupcalled = 0 state and removes any allocated Vecs and Mats

Synopsis#

#include "petscsnes.h"  
PetscErrorCode SNESReset(SNES snes)

Collective

Input Parameter#

  • snes - iterative context obtained from SNESCreate()

Notes#

Call this if you wish to reuse a SNES but with different size vectors

Also calls the application context destroy routine set with SNESSetComputeApplicationContext()

See Also#

SNES: Nonlinear Solvers, SNES, SNESDestroy(), SNESCreate(), SNESSetUp(), SNESSolve()

Level#

intermediate

Location#

src/snes/interface/snes.c

Implementations#

SNESReset_Composite() in src/snes/impls/composite/snescomposite.c
SNESReset_FAS() in src/snes/impls/fas/fas.c
SNESReset_NGS() in src/snes/impls/gs/snesgs.c
SNESReset_NEWTONLS() in src/snes/impls/ls/ls.c
SNESReset_MS() in src/snes/impls/ms/ms.c
SNESReset_Multiblock() in src/snes/impls/multiblock/multiblock.c
SNESReset_NASM() in src/snes/impls/nasm/nasm.c
SNESReset_NCG() in src/snes/impls/ncg/snesncg.c
SNESReset_NGMRES() in src/snes/impls/ngmres/snesngmres.c
SNESReset_NEWTONTRDC() in src/snes/impls/ntrdc/ntrdc.c
SNESReset_Patch() in src/snes/impls/patch/snespatch.c
SNESReset_QN() in src/snes/impls/qn/qn.c
SNESReset_NRichardson() in src/snes/impls/richardson/snesrichardson.c
SNESReset_Shell() in src/snes/impls/shell/snesshell.c
SNESReset_VINEWTONRSLS() in src/snes/impls/vi/rs/virs.c
SNESReset_VINEWTONSSLS() in src/snes/impls/vi/ss/viss.c
SNESReset_VI() in src/snes/impls/vi/vi.c


Index of all SNES routines
Table of Contents for all manual pages
Index of all manual pages