Feellgood
|
Template abstract class, mother class for tetraedrons and facettes. More...
#include <element.h>
Public Member Functions | |
element (const std::vector< Nodes::Node > &_p_node, const int _idx, std::initializer_list< int > &_i) | |
constexpr int | getN (void) const |
constexpr int | getNPI (void) const |
void | buildMatP (Eigen::Ref< Eigen::Matrix< double, 2 *N, 3 *N >> P) |
void | assemblage_mat (const int NOD, std::vector< Eigen::Triplet< double >> &K) const |
void | assemblage_vect (const int NOD, Eigen::Ref< Eigen::VectorXd > L) const |
void | infos () const |
virtual void | getPtGauss (Eigen::Ref< Eigen::Matrix< double, Nodes::DIM, NPI >> result) const =0 |
Public Attributes | |
std::vector< int > | ind |
int | idxPrm |
Eigen::Matrix< double, NPI, 1 > | weight |
Eigen::Matrix< double, 2 *N, 2 *N > | Kp |
Eigen::Matrix< double, 2 *N, 1 > | Lp |
Protected Member Functions | |
const Nodes::Node & | getNode (const int i) const |
bool | existNodes (void) |
void | zeroBasing (void) |
Private Member Functions | |
virtual void | orientate ()=0 |
Private Attributes | |
const std::vector< Nodes::Node > & | refNode |
Template abstract class, mother class for tetraedrons and facettes.
template parameters are N number of sommits and NPI number of interpolation points. It contains a list of indices to the N nodes of the element, a reference to the full nodes vector, and index refering to the associated material parameters. All indices are zero based, derived class constructor should call zerobasing() if needed. It contains also the vector and matrix weight, Kp, Lp, P related to finite element computations. weight values are not initialized, they have to be set by derived class constructor. Member function getPtGauss() returns Gauss points. orientate() is a pure virtual function, it should manipulate indices to orientate positively the element.
|
inlineexplicit |
constructor
_p_node | vector of nodes |
_idx | index to params |
_i | indices to the nodes |
|
inline |
assemble the big sparse matrix K from tetra or facette inner matrix Kp
[in] | NOD | nb nodes |
[out] | K | COO matrix |
|
inline |
assemble the big vector L from tetra or facette inner vector Lp
[in] | NOD | nb nodes |
[out] | L | vector |
|
inline |
build matrix P direcly from ep,eq in nodes P is block diagonal: ( Epx Epy Epz ) ( Eqz Eqy Eqz ) with each block E(p|q)(x|y|z) a N*N diagonal matrix see here http://eigen.tuxfamily.org/dox-devel/TopicTemplateKeyword.html for the wierd template syntax
[out] | P | block diagonal matrix |
|
inlineprotected |
returns true if mesh node vector is not empty
|
inlineconstexpr |
getter for N
|
inlineprotected |
returns reference to node at ind[i] from mesh node vector
|
inlineconstexpr |
getter for NPI
|
pure virtual |
computes Gauss point of the element, return in result
Implemented in Tetra::Tet, and Facette::Fac.
|
inline |
info: print node indices of the element and the vector index of the associated param
|
privatepure virtual |
a method to orientate the element
Implemented in Tetra::Tet, and Facette::Fac.
|
inlineprotected |
zeroBasing: index convention Matlab/msh (one based) -> C++ (zero based)
int element< N, NPI >::idxPrm |
index of the material parameters of the element
std::vector<int> element< N, NPI >::ind |
indices to the nodes
Eigen::Matrix<double,2*N,2*N> element< N, NPI >::Kp |
matrix for integrales
Eigen::Matrix<double,2*N,1> element< N, NPI >::Lp |
vector for integrales
|
private |
vector of nodes
Eigen::Matrix<double,NPI,1> element< N, NPI >::weight |
weights hat function of the element