Skip to main content
`Ctrl`+`K`

# DMSNESSetFunctionContextDestroy

set `SNES` residual evaluation context destroy function

## Synopsis

    #include "petscsnes.h"
    #include "petscdm.h"
    PetscErrorCode DMSNESSetFunctionContextDestroy(DM dm, PetscCtxDestroyFn *f)

Not Collective

## Input Parameters

- dm - `DM` to be used with `SNES`

- f - residual evaluation context destroy function, see `PetscCtxDestroyFn` for its calling sequence

## See Also

SNES: Nonlinear Solvers, `DMSNES`, `DMSNESSetFunction()`, `SNESSetFunction()`, `PetscCtxDestroyFn`

## Level

developer

## Location

src/snes/utils/dmsnes.c

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