MFEM v4.10.0
Finite element discretization library
Loading...
Searching...
No Matches
mfem::VectorComponentCoefficient Class Reference

Scalar coefficient defined as component of a vector coefficient. More...

#include <coefficient.hpp>

Inheritance diagram for mfem::VectorComponentCoefficient:
[legend]
Collaboration diagram for mfem::VectorComponentCoefficient:
[legend]

Public Member Functions

 VectorComponentCoefficient (VectorCoefficient &A)
 Construct with a vector coefficient.
 
 VectorComponentCoefficient (VectorCoefficient &A, int c)
 Construct with a vector coefficient and a component index c.
 
void SetTime (real_t t) override
 Set the time for internally stored coefficients.
 
void SetACoef (VectorCoefficient &A)
 Reset the vector coefficient.
 
VectorCoefficientGetACoef () const
 Return the vector coefficient.
 
void SetComponent (int c)
 Set the component.
 
int GetComponent () const
 Return the component.
 
real_t Eval (ElementTransformation &T, const IntegrationPoint &ip) override
 Evaluate the component coefficient at ip.
 
- Public Member Functions inherited from mfem::Coefficient
 Coefficient ()
 
real_t GetTime ()
 Get the time for time dependent coefficients.
 
int GetVDim ()
 Returns dimension of the vector.
 
real_t Eval (ElementTransformation &T, const IntegrationPoint &ip, real_t t)
 Evaluate the coefficient in the element described by T at the point ip at time t.
 
virtual void Project (QuadratureFunction &qf)
 Fill the QuadratureFunction qf by evaluating the coefficient at the quadrature points.
 
virtual ~Coefficient ()
 

Additional Inherited Members

- Protected Attributes inherited from mfem::Coefficient
real_t time
 

Detailed Description

Scalar coefficient defined as component of a vector coefficient.

Definition at line 1883 of file coefficient.hpp.

Constructor & Destructor Documentation

◆ VectorComponentCoefficient() [1/2]

mfem::VectorComponentCoefficient::VectorComponentCoefficient ( VectorCoefficient & A)
inline

Construct with a vector coefficient.

Definition at line 1893 of file coefficient.hpp.

◆ VectorComponentCoefficient() [2/2]

mfem::VectorComponentCoefficient::VectorComponentCoefficient ( VectorCoefficient & A,
int c )

Construct with a vector coefficient and a component index c.

Definition at line 1311 of file coefficient.cpp.

Member Function Documentation

◆ Eval()

real_t mfem::VectorComponentCoefficient::Eval ( ElementTransformation & T,
const IntegrationPoint & ip )
overridevirtual

Evaluate the component coefficient at ip.

Implements mfem::Coefficient.

Definition at line 1333 of file coefficient.cpp.

◆ GetACoef()

VectorCoefficient * mfem::VectorComponentCoefficient::GetACoef ( ) const
inline

Return the vector coefficient.

Definition at line 1906 of file coefficient.hpp.

◆ GetComponent()

int mfem::VectorComponentCoefficient::GetComponent ( ) const
inline

Return the component.

Definition at line 1912 of file coefficient.hpp.

◆ SetACoef()

void mfem::VectorComponentCoefficient::SetACoef ( VectorCoefficient & A)
inline

Reset the vector coefficient.

Definition at line 1903 of file coefficient.hpp.

◆ SetComponent()

void mfem::VectorComponentCoefficient::SetComponent ( int c)

Set the component.

Definition at line 1318 of file coefficient.cpp.

◆ SetTime()

void mfem::VectorComponentCoefficient::SetTime ( real_t t)
overridevirtual

Set the time for internally stored coefficients.

Reimplemented from mfem::Coefficient.

Definition at line 1327 of file coefficient.cpp.


The documentation for this class was generated from the following files: