v0.8.4
Files | Classes | Functions
Post Process
Collaboration diagram for Post Process:

Files

file  PostProcOnRefMesh.cpp
 Postprocess fields on refined mesh made for 10 Node tets.
 
file  PostProcOnRefMesh.hpp
 Post-process fields on refined mesh.
 

Classes

struct  PostProcCommonOnRefMesh
 Set of operators and data structures used for post-processing. More...
 
struct  PostProcCommonOnRefMesh::OpGetFieldGradientValues
 operator to post-process (save gradients on refined post-processing mesh) field gradient More...
 
struct  PostProcCommonOnRefMesh::OpGetFieldValues
 operator to post-process (save gradients on refined post-processing mesh) field gradient More...
 
struct  PostProcTemplateOnRefineMesh< ELEMENT >
 Generic post-processing class. More...
 
struct  PostProcVolumeOnRefinedMesh
 Post processing. More...
 
struct  PostProcFatPrismOnRefinedMesh
 Postprocess on prism. More...
 
struct  PostProcFaceOnRefinedMesh
 Postprocess on face. More...
 

Functions

MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::addFieldValuesPostProc (const std::string field_name, Vec v=PETSC_NULL)
 Add operator to post-process L2, H1, Hdiv, Hcurl field value. More...
 
MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::addFieldValuesPostProc (const std::string field_name, const std::string tag_name, Vec v=PETSC_NULL)
 Add operator to post-process L2 or H1 field value. More...
 
MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::addFieldValuesGradientPostProc (const std::string field_name, Vec v=PETSC_NULL)
 Add operator to post-process L2 or H1 field gradient. More...
 
MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::addFieldValuesGradientPostProc (const std::string field_name, const std::string tag_name, Vec v=PETSC_NULL)
 Add operator to post-process L2 or H1 field gradient. More...
 
MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::writeFile (const std::string file_name)
 wrote results in (MOAB) format, use "file_name.h5m" More...
 

Detailed Description

Function Documentation

◆ addFieldValuesGradientPostProc() [1/2]

template<class ELEMENT>
MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::addFieldValuesGradientPostProc ( const std::string  field_name,
Vec  v = PETSC_NULL 
)

Add operator to post-process L2 or H1 field gradient.

Parameters
field_name
vIf vector is given, values from vector are used to set tags on mesh

Note: Name of the tag to store values on post-process mesh is the same as field name

Definition at line 194 of file PostProcOnRefMesh.hpp.

195  {
197  ELEMENT::getOpPtrVector().push_back(
199  postProcMesh, mapGaussPts, field_name, field_name + "_GRAD",
200  getCommonData(), v));
202  }
operator to post-process (save gradients on refined post-processing mesh) field gradient ...
moab::Interface & postProcMesh
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:522
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return() ...
Definition: definitions.h:528
std::vector< EntityHandle > mapGaussPts
virtual PostProcCommonOnRefMesh::CommonData & getCommonData()

◆ addFieldValuesGradientPostProc() [2/2]

template<class ELEMENT>
MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::addFieldValuesGradientPostProc ( const std::string  field_name,
const std::string  tag_name,
Vec  v = PETSC_NULL 
)

Add operator to post-process L2 or H1 field gradient.

Parameters
field_name
tag_nameto store results on post-process mesh
vIf vector is given, values from vector are used to set tags on mesh

Definition at line 213 of file PostProcOnRefMesh.hpp.

215  {
217  ELEMENT::getOpPtrVector().push_back(
219  postProcMesh, mapGaussPts, field_name, tag_name, getCommonData(),
220  v));
222  }
operator to post-process (save gradients on refined post-processing mesh) field gradient ...
moab::Interface & postProcMesh
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:522
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return() ...
Definition: definitions.h:528
std::vector< EntityHandle > mapGaussPts
virtual PostProcCommonOnRefMesh::CommonData & getCommonData()

◆ addFieldValuesPostProc() [1/2]

template<class ELEMENT>
MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::addFieldValuesPostProc ( const std::string  field_name,
Vec  v = PETSC_NULL 
)

Add operator to post-process L2, H1, Hdiv, Hcurl field value.

Parameters
field_name
vIf vector is given, values from vector are used to set tags on mesh

Note: Name of the tag to store values on post-process mesh is the same as field name

Definition at line 152 of file PostProcOnRefMesh.hpp.

153  {
155  ELEMENT::getOpPtrVector().push_back(
157  field_name, field_name,
158  getCommonData(), v));
160  }
operator to post-process (save gradients on refined post-processing mesh) field gradient ...
moab::Interface & postProcMesh
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:522
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return() ...
Definition: definitions.h:528
std::vector< EntityHandle > mapGaussPts
virtual PostProcCommonOnRefMesh::CommonData & getCommonData()

◆ addFieldValuesPostProc() [2/2]

template<class ELEMENT>
MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::addFieldValuesPostProc ( const std::string  field_name,
const std::string  tag_name,
Vec  v = PETSC_NULL 
)

Add operator to post-process L2 or H1 field value.

Parameters
field_name
tag_nameto store results on post-process mesh
vIf vector is given, values from vector are used to set tags on mesh

Definition at line 171 of file PostProcOnRefMesh.hpp.

173  {
175  ELEMENT::getOpPtrVector().push_back(
177  field_name, tag_name,
178  getCommonData(), v));
180  }
operator to post-process (save gradients on refined post-processing mesh) field gradient ...
moab::Interface & postProcMesh
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:522
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return() ...
Definition: definitions.h:528
std::vector< EntityHandle > mapGaussPts
virtual PostProcCommonOnRefMesh::CommonData & getCommonData()

◆ writeFile()

template<class ELEMENT>
MoFEMErrorCode PostProcTemplateOnRefineMesh< ELEMENT >::writeFile ( const std::string  file_name)

wrote results in (MOAB) format, use "file_name.h5m"

Parameters
file_namefile name (should always end with .h5m)
Returns
error code

Definition at line 232 of file PostProcOnRefMesh.hpp.

232  {
234  // #ifdef MOAB_HDF5_PARALLEL
235  rval = postProcMesh.write_file(file_name.c_str(), "MOAB",
236  "PARALLEL=WRITE_PART");
237  CHKERRG(rval);
238  // #else
239  // #warning "No parallel HDF5, not most efficient way of writing files"
240  // if(mField.get_comm_rank()==0) {
241  // rval = postProcMesh.write_file(file_name.c_str(),"MOAB","");
242  // CHKERRG(rval);
243  // }
244  // #endif
246  }
moab::Interface & postProcMesh
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:522
#define CHKERRG(n)
Check error code of MoFEM/MOAB/PETSc function.
Definition: definitions.h:565
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return() ...
Definition: definitions.h:528
static MoFEMErrorCodeGeneric< moab::ErrorCode > rval
Definition: Common.hpp:78