CEPS
24.01
Cardiac ElectroPhysiology Simulator
|
Source term, essentially a ScalarField.
Definition at line 49 of file SourceTerm.hpp.
#include <SourceTerm.hpp>
Public Member Functions | |
SourceTerm (SAFunc< _Result > *functor, const CepsVector< DegreeOfFreedom * > *domain, CepsUnknownIndex unknown, CepsBool isStim=false, CepsBool isLaplaceMatrix=false, CepsBool bufferize=false) | |
Construct a new Source Term object. More... | |
~SourceTerm () override | |
Delete data. More... | |
void | setFlag (const CepsSourceTermFlag &flag) |
Set the source term flag. More... | |
CepsSourceTermFlag | getFlag () const |
Get the source term flag. More... | |
CepsUnknownIndex | getUnknownId () const |
Get the name of the unknown. More... | |
CepsBool | hasOption (CepsSourceTermFlag flag) const |
Knowing the behavior relating to source term flag. More... | |
Public Member Functions inherited from Field< _Result, DegreeOfFreedom > | |
Field (FunctionType *functor, const _Domain *domain, CepsBool bufferize=false) | |
Construct a new Field object, with a vector, functor cannot be null. More... | |
virtual | ~Field ()=default |
Destructor. More... | |
void | addDomain (const _Domain *domain) |
Add another domain of definition. More... | |
void | clearDomains () |
Removes domains and support. More... | |
FunctionType * | getFunctor () const |
Get the functor inside the object. More... | |
void | setFunctor (ceps::Function< _Result(CepsStandardArgs)> *functor) |
Set the functor inside the object. More... | |
void | setScaleFactor (CepsReal scaleFactor) |
Scale the result. More... | |
CepsReal | getScaleFactor () const |
Get the scale factor used. More... | |
CepsBool | isBuffered () const |
Tells if field is bufferized. More... | |
CepsBool | hasBufferedData () const |
Tells if field is bufferized and data has already been computed. More... | |
CepsEnum | getFunctorFlags () const |
Get flags of the function. More... | |
CepsBool | hasFunctorOption (CepsFunctionFlag flag) const |
Knowing the behavior relating to the time variable. More... | |
CepsBool | isSpaceVariable () const |
Knowing the behavior relating to the space variable. More... | |
CepsBool | isTimeVariable () const |
Knowing the behavior relating to the time variable. More... | |
CepsBool | needsSolution () const |
Knowing the behavior relating to the solution vector. More... | |
void | getValues (CepsVector< _Result > &values, CepsReal t, const CepsVector< DegreeOfFreedom * > &points={}) |
Get the values for given row indices. If no support was given, simply call the functor for all dofs. More... | |
_Result | getValue (DegreeOfFreedom *point, CepsReal t) |
Get single value for given row index. /!\ If not nullptr, the solution vector should HAVE ALREADY CALLED getLocalData() !! More... | |
void | computeSupport (AbstractSelector< _Iterator > *selector, CepsBool canStartEmpty=false) |
Computes the support in the domains of definition, using the given selector. More... | |
virtual void | actualize (CepsReal t) |
Precompute field data. More... | |
CepsVector< _Result > & | getBufferedData () |
Ref to buffered data. More... | |
CepsVector< CepsGlobalIndex > & | getSupportIndices () |
Get indices of support. More... | |
const CepsVector< DegreeOfFreedom * > & | getSupport () |
Get suppor. More... | |
const CepsVector< const CepsVector< DegreeOfFreedom * > * > & | getDomains () |
Get the spans on which the field is defined. More... | |
Protected Attributes | |
CepsSourceTermFlag | m_sourceFlag |
source term flag More... | |
CepsUnknownIndex | m_unknown |
Unknown for which the source term applies. More... | |
Protected Attributes inherited from Field< _Result, DegreeOfFreedom > | |
FunctionType * | m_functor |
doesn't belong to this object More... | |
CepsReal | m_scaleFactor |
An optional scale factor. More... | |
CepsVector< DegreeOfFreedom * > | m_support |
List of "points" where the field applies. More... | |
CepsVector< CepsGlobalIndex > | m_supportIndices |
List of "points" indices. More... | |
CepsBool | m_supportComputed |
True if computeSupport has been called. More... | |
CepsVector< _Result > | m_buffer |
Get buffer with data evaluated. More... | |
CepsBool | m_precompute |
Do we bufferize data ? More... | |
CepsBool | m_isPrecomputed |
Check if values were already evaluated. More... | |
CepsVector< const CepsVector< DegreeOfFreedom * > * > | m_domains |
Ranges on which the field is defined. More... | |
Friends | |
class | SourceTermManager |
Friend class. More... | |
Additional Inherited Members | |
Public Types inherited from Field< _Result, DegreeOfFreedom > | |
using | FunctionType = SAFunc< _Result > |
The type returned by the functor. More... | |
using | _Domain = CepsVector< DegreeOfFreedom * > |
The objects on which is defined the support (GeomCell, GeomNode, DegreeOfFreedom) More... | |
using | _Iterator = typename CepsVector< DegreeOfFreedom * >::const_iterator |
The objects on which is defined the support (GeomCell, GeomNode, DegreeOfFreedom) More... | |
Protected Member Functions inherited from Field< _Result, DegreeOfFreedom > | |
virtual void | evaluateAll (CepsReal t, CepsVector< _Result > &results) |
Evaluate on all domain or support, put results in given vector. More... | |
virtual void | evaluateOn (const _Domain *domain, CepsReal t, CepsUInt offset, CepsVector< _Result > &results) |
Precompute field data. More... | |
SourceTerm< _Result >::SourceTerm | ( | SAFunc< _Result > * | functor, |
const CepsVector< DegreeOfFreedom * > * | domain, | ||
CepsUnknownIndex | unknown, | ||
CepsBool | isStim = false , |
||
CepsBool | isLaplaceMatrix = false , |
||
CepsBool | bufferize = false |
||
) |
Construct a new Source Term object.
functor | functor wrapped |
domain | list of dofs where the source term applies |
unknown | the unknown for which the source term applies |
isStim | stimulation type |
isLaplaceMatrix | to be multiplied by stiffness FE matrix |
bufferize | store values |
|
override |
Delete data.
CepsSourceTermFlag SourceTerm< _Result >::getFlag | ( | ) | const |
Get the source term flag.
CepsUnknownIndex SourceTerm< _Result >::getUnknownId | ( | ) | const |
Get the name of the unknown.
CepsBool SourceTerm< _Result >::hasOption | ( | CepsSourceTermFlag | flag | ) | const |
Knowing the behavior relating to source term flag.
void SourceTerm< _Result >::setFlag | ( | const CepsSourceTermFlag & | flag | ) |
Set the source term flag.
|
friend |
Friend class.
Definition at line 91 of file SourceTerm.hpp.
|
protected |
source term flag
Definition at line 94 of file SourceTerm.hpp.
|
protected |
Unknown for which the source term applies.
Definition at line 95 of file SourceTerm.hpp.