SNESMeshFormFunction

This is a universal function evaluation routine that may be used with SNESSetFunction() as long as the user context has a DMMesh as its first record and the user has called DMMeshSetLocalFunction().

Synopsis

#include "petscdmda.h"    
#include "petscdmmesh.h"  
#include "petscpcmg.h"    
#include "petscdmmg.h"  
PetscErrorCode SNESMeshFormFunction(SNES snes, Vec X, Vec F, void *ptr)
Collective on SNES

Input Parameters

snes - the SNES context
X - input vector
F - function vector
ptr - pointer to a structure that must have a DMMesh as its first entry. This ptr must have been passed into SNESMeshFormFunction() as the context.

See Also

DMMeshSetLocalFunction(), DMMeshSetLocalJacobian(), SNESSetFunction(), SNESSetJacobian()

Level:intermediate
Location:
src/snes/utils/damgsnes.c
Index of all DMMG routines
Table of Contents for all manual pages
Index of all manual pages

Examples

src/snes/examples/tutorials/ex12.c.html
src/snes/examples/tutorials/ex52.c.html