#include "petscdm.h" PetscErrorCode DMRefineHookAdd(DM coarse,PetscErrorCode (*refinehook)(DM,DM,void*),PetscErrorCode (*interphook)(DM,Mat,DM,void*),void *ctx)Logically Collective
| coarse | - nonlinear solver context on which to run a hook when restricting to a coarser level | |
| refinehook | - function to run when setting up a coarser level | |
| interphook | - function to run to update data on finer levels (once per SNESSolve()) | |
| ctx | - [optional] user-defined context for provide data for the hooks (may be NULL) |
refinehook(DM coarse,DM fine,void *ctx);
| coarse | - coarse level DM | |
| fine | - fine level DM to interpolate problem to | |
| ctx | - optional user-defined function context |
interphook(DM coarse,Mat interp,DM fine,void *ctx)
| coarse | - coarse level DM | |
| interp | - matrix interpolating a coarse-level solution to the finer grid | |
| fine | - fine level DM to update | |
| ctx | - optional user-defined function context |
If this function is called multiple times, the hooks will be run in the order they are added.
This function is currently not available from Fortran.
Level:advanced
Location:src/dm/interface/dm.c
Index of all DM routines
Table of Contents for all manual pages
Index of all manual pages