v0.14.0
Public Member Functions | Public Attributes | List of all members
Smoother::SmootherBlockData Struct Reference

#include <tools/src/Smoother.hpp>

Collaboration diagram for Smoother::SmootherBlockData:
[legend]

Public Member Functions

 SmootherBlockData ()
 
MoFEMErrorCode getOptions ()
 
virtual ~SmootherBlockData ()
 
 SmootherBlockData ()
 
MoFEMErrorCode getOptions ()
 
virtual ~SmootherBlockData ()
 

Public Attributes

bool sTabilised
 
Vec frontF
 
Vec tangentFrontF
 
bool ownVectors
 

Detailed Description

Definition at line 12 of file Smoother.hpp.

Constructor & Destructor Documentation

◆ SmootherBlockData() [1/2]

Smoother::SmootherBlockData::SmootherBlockData ( )
inline

Definition at line 19 of file Smoother.hpp.

20  : sTabilised(false), frontF(PETSC_NULL), tangentFrontF(PETSC_NULL),
21  ownVectors(false) {
22  ierr = getOptions();
23  CHKERRABORT(PETSC_COMM_SELF, ierr);
24  }

◆ ~SmootherBlockData() [1/2]

virtual Smoother::SmootherBlockData::~SmootherBlockData ( )
inlinevirtual

Definition at line 41 of file Smoother.hpp.

41  {
42  if (ownVectors) {
43  ierr = VecDestroy(&frontF);
44  CHKERRABORT(PETSC_COMM_WORLD, ierr);
45  ierr = VecDestroy(&tangentFrontF);
46  CHKERRABORT(PETSC_COMM_WORLD, ierr);
47  }
48  }

◆ SmootherBlockData() [2/2]

Smoother::SmootherBlockData::SmootherBlockData ( )
inline

Definition at line 19 of file Smoother.hpp.

20  : sTabilised(false), frontF(PETSC_NULL), tangentFrontF(PETSC_NULL),
21  ownVectors(false) {
22  ierr = getOptions();
23  CHKERRABORT(PETSC_COMM_SELF, ierr);
24  }

◆ ~SmootherBlockData() [2/2]

virtual Smoother::SmootherBlockData::~SmootherBlockData ( )
inlinevirtual

Definition at line 41 of file Smoother.hpp.

41  {
42  if (ownVectors) {
43  ierr = VecDestroy(&frontF);
44  CHKERRABORT(PETSC_COMM_WORLD, ierr);
45  ierr = VecDestroy(&tangentFrontF);
46  CHKERRABORT(PETSC_COMM_WORLD, ierr);
47  }
48  }

Member Function Documentation

◆ getOptions() [1/2]

MoFEMErrorCode Smoother::SmootherBlockData::getOptions ( )
inline

Definition at line 26 of file Smoother.hpp.

26  {
28  ierr = PetscOptionsBegin(PETSC_COMM_WORLD, "",
29  "Get stabilisation element options", "none");
30  CHKERRG(ierr);
31  PetscBool smoothing_on = sTabilised ? PETSC_TRUE : PETSC_FALSE;
32  CHKERR PetscOptionsBool("-smoothing_stabilise",
33  "all nodes controlled by smoothing element", "",
34  smoothing_on, &smoothing_on, PETSC_NULL);
35  sTabilised = (smoothing_on == PETSC_TRUE) ? true : false;
36  ierr = PetscOptionsEnd();
37  CHKERRG(ierr);
39  }

◆ getOptions() [2/2]

MoFEMErrorCode Smoother::SmootherBlockData::getOptions ( )
inline

Definition at line 26 of file Smoother.hpp.

26  {
28  ierr = PetscOptionsBegin(PETSC_COMM_WORLD, "",
29  "Get stabilisation element options", "none");
30  CHKERRG(ierr);
31  PetscBool smoothing_on = sTabilised ? PETSC_TRUE : PETSC_FALSE;
32  CHKERR PetscOptionsBool("-smoothing_stabilise",
33  "all nodes controlled by smoothing element", "",
34  smoothing_on, &smoothing_on, PETSC_NULL);
35  sTabilised = (smoothing_on == PETSC_TRUE) ? true : false;
36  ierr = PetscOptionsEnd();
37  CHKERRG(ierr);
39  }

Member Data Documentation

◆ frontF

Vec Smoother::SmootherBlockData::frontF

Definition at line 15 of file Smoother.hpp.

◆ ownVectors

bool Smoother::SmootherBlockData::ownVectors

Definition at line 17 of file Smoother.hpp.

◆ sTabilised

bool Smoother::SmootherBlockData::sTabilised

Definition at line 14 of file Smoother.hpp.

◆ tangentFrontF

Vec Smoother::SmootherBlockData::tangentFrontF

Definition at line 16 of file Smoother.hpp.


The documentation for this struct was generated from the following file:
Smoother::SmootherBlockData::frontF
Vec frontF
Definition: Smoother.hpp:15
Smoother::SmootherBlockData::ownVectors
bool ownVectors
Definition: Smoother.hpp:17
Smoother::SmootherBlockData::sTabilised
bool sTabilised
Definition: Smoother.hpp:14
CHKERR
#define CHKERR
Inline error check.
Definition: definitions.h:548
Smoother::SmootherBlockData::tangentFrontF
Vec tangentFrontF
Definition: Smoother.hpp:16
Smoother::SmootherBlockData::getOptions
MoFEMErrorCode getOptions()
Definition: Smoother.hpp:26
MoFEM::Exceptions::ierr
static MoFEMErrorCodeGeneric< PetscErrorCode > ierr
Definition: Exceptions.hpp:76
MoFEMFunctionReturn
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:429
CHKERRG
#define CHKERRG(n)
Check error code of MoFEM/MOAB/PETSc function.
Definition: definitions.h:496
MoFEMFunctionBegin
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:359