#include "petscdm.h" #include "petscdmlabel.h" #include "petscds.h" PetscErrorCode DMComputeError(DM dm, Vec sol, PetscReal errors[], Vec *errorVec)Collective on DM
dm | - The DM | |
sol | - The solution vector |
errors | - An array of length Nf, the number of fields, or NULL for no output; on output contains the error in each field |
errorVec | - A vector to hold the cellwise error (may be NULL) |
Note: The exact solutions come from the PetscDS object, and the time comes from DMGetOutputSequenceNumber().