LehrFEM++ 1.0.0
A simple Finite Element Library for teaching
|
Computes the Galerkin LSE for the Dirac Operator and the load vector. More...
#include </home/nico/bildung/SemVI/thesis/lehrfempp/projects/hldo_sphere/operators/dirac_operator.h>
Public Member Functions | |
DiracOperator () | |
Constructor creates basic mesh (Octaeder with radius 1.0) and zero valued functions f. More... | |
void | Compute () |
Computes the Galerkin LSE. More... | |
void | SetMesh (std::shared_ptr< const lf::mesh::Mesh > mesh_p) |
Sets the mesh and creates dof_handler. More... | |
void | SetLoadFunctions (std::function< complex(const Eigen::Matrix< double, 3, 1 > &)> f0, std::function< Eigen::Matrix< complex, 3, 1 >(const Eigen::Matrix< double, 3, 1 > &)> f1, std::function< complex(const Eigen::Matrix< double, 3, 1 > &)> f2) |
Sets the load functions. More... | |
Eigen::Matrix< complex, Eigen::Dynamic, 1 > | GetLoadVector () |
returns the Loadvector More... | |
lf::assemble::COOMatrix< complex > | GetGalerkinMatrix () |
returns the Galerkin Matrix More... | |
Private Attributes | |
std::shared_ptr< const lf::mesh::Mesh > | mesh_p_ |
std::function< complex(const Eigen::Matrix< double, 3, 1 > &)> | f0_ |
std::function< Eigen::Matrix< complex, 3, 1 >(const Eigen::Matrix< double, 3, 1 > &)> | f1_ |
std::function< complex(const Eigen::Matrix< double, 3, 1 > &)> | f2_ |
lf::assemble::COOMatrix< complex > | coo_matrix_ |
Eigen::Matrix< complex, Eigen::Dynamic, 1 > | phi_ |
Computes the Galerkin LSE for the Dirac Operator and the load vector.
\[ \begin{pmatrix} & \int\limits_{\partial \mathbf{S}} \mathbf{u} \cdot \mathbf{grad}_{\Gamma} v \, dS & \\ \int_{\partial \mathbf{S}} \mathbf{grad}_{\Gamma} u \cdot \mathbf{v} \, dS & & \int\limits_{\partial \mathbf{S}} \mu \ \ \text{curl}_{\Gamma} \mathbf{v} \, dS \\ & \int\limits_{\partial \mathbf{S}} \text{curl}_{\Gamma} \mathbf{u} \ \ \nu \, dS & \end{pmatrix} , \begin{pmatrix} \int\limits_{\partial \mathbf{S}} f v \, dS \\ \int\limits_{\partial \mathbf{S}} \mathbf{f} \cdot \mathbf{v} \, dS \\ \int\limits_{\partial \mathbf{S}} \varphi \nu \, dS \end{pmatrix} \]
Details regarding the mathematical derivations can be found in the thesis Hodge-Laplacians and Dirac Operators on the Surface of the 3-Sphere
section 4.3.4.
Definition at line 60 of file dirac_operator.h.
|
inline |
Constructor creates basic mesh (Octaeder with radius 1.0) and zero valued functions f.
Definition at line 68 of file dirac_operator.h.
References f0_, f1_, f2_, mesh_p_, and projects::hldo_sphere::mesh::SphereTriagMeshBuilder::setRefinementLevel().
void projects::hldo_sphere::operators::DiracOperator::Compute | ( | ) |
Computes the Galerkin LSE.
The Galerkin matrix can be accessable with GetGalerkinMatrix() The load vector can be accessable with GetLoadVector()
Definition at line 7 of file dirac_operator.cc.
References lf::assemble::AssembleVectorLocally(), coo_matrix_, f0_, f1_, f2_, lf::base::RefEl::kPoint(), lf::base::RefEl::kSegment(), lf::base::RefEl::kTria(), mesh_p_, lf::assemble::DofHandler::NumDofs(), phi_, lf::assemble::COOMatrix< SCALAR >::setZero(), and lf::assemble::COOMatrix< SCALAR >::triplets().
Referenced by projects::hldo_sphere::operators::DiracOperatorSourceProblem::Compute().
|
inline |
returns the Galerkin Matrix
This is the Matrix of the LSE
Definition at line 148 of file dirac_operator.h.
References coo_matrix_.
Referenced by projects::hldo_sphere::operators::DiracOperatorSourceProblem::Compute().
|
inline |
returns the Loadvector
This is the righthandside of the LSE
Definition at line 137 of file dirac_operator.h.
References phi_.
Referenced by projects::hldo_sphere::operators::DiracOperatorSourceProblem::Compute().
|
inline |
Sets the load functions.
f0 | load function in \( L^2 \) |
f1 | load functions in \( L^2_t \) vector valued |
f2 | load functions in \( L^2 \) |
Definition at line 117 of file dirac_operator.h.
Referenced by projects::hldo_sphere::operators::DiracOperatorSourceProblem::Compute().
void projects::hldo_sphere::operators::DiracOperator::SetMesh | ( | std::shared_ptr< const lf::mesh::Mesh > | mesh_p | ) |
Sets the mesh and creates dof_handler.
mesh_p | pointer to the mesh |
requries all cells in the mesh are triangles requries mesh global dimension to be 3
Definition at line 131 of file dirac_operator.cc.
References lf::base::RefEl::kTria(), mesh_p_, and lf::base::RefEl::RefEl().
Referenced by projects::hldo_sphere::operators::DiracOperatorSourceProblem::Compute().
|
private |
Definition at line 157 of file dirac_operator.h.
Referenced by Compute(), and GetGalerkinMatrix().
|
private |
Definition at line 152 of file dirac_operator.h.
Referenced by Compute(), DiracOperator(), and SetLoadFunctions().
|
private |
Definition at line 155 of file dirac_operator.h.
Referenced by Compute(), DiracOperator(), and SetLoadFunctions().
|
private |
Definition at line 156 of file dirac_operator.h.
Referenced by Compute(), DiracOperator(), and SetLoadFunctions().
|
private |
Definition at line 151 of file dirac_operator.h.
Referenced by Compute(), DiracOperator(), and SetMesh().
|
private |
Definition at line 158 of file dirac_operator.h.
Referenced by Compute(), and GetLoadVector().