|
Feellgood
|
#include <triangle.h>
Public Member Functions | |
| Tri (const std::vector< Nodes::Node > &_p_node, const int _NOD, const int _idx, std::initializer_list< int > _i) | |
| void | interpolation (std::function< Eigen::Vector3d(Nodes::Node)> getter, Eigen::Ref< Eigen::Matrix< double, Nodes::DIM, NPI >> result) const |
| void | interpolation (std::function< double(Nodes::Node)> getter, Eigen::Ref< Eigen::Matrix< double, NPI, 1 >> result) const |
| void | integrales (Triangle::prm const ¶ms) |
| double | anisotropyEnergy (Triangle::prm const ¶m, Eigen::Ref< Eigen::Matrix< double, Nodes::DIM, NPI >> const u) const |
| Eigen::Matrix< double, NPI, 1 > | charges (const double &dMs, std::function< Eigen::Vector3d(const Nodes::Node &)> getter) const |
| void | correctionCharges (std::function< Eigen::Vector3d(Nodes::Node)> getter, Eigen::Matrix< double, Triangle::NPI, 1 > &localCharges, std::vector< double > &corr) |
| double | demagEnergy (Eigen::Ref< Eigen::Matrix< double, Nodes::DIM, NPI >> u, Eigen::Ref< Eigen::Matrix< double, NPI, 1 >> phi) const |
| double | potential (std::function< Eigen::Vector3d(Nodes::Node)> getter, int i) const |
| bool | operator< (const Tri &f) const |
| bool | operator== (const Tri &f) const |
| Eigen::Vector3d | calc_norm (void) const |
| void | getPtGauss (Eigen::Ref< Eigen::Matrix< double, Nodes::DIM, NPI >> result) const |
| double | calc_surf (void) const |
Public Member Functions inherited from element< N, NPI > | |
| 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 | infos (void) |
| bool | existNodes (void) const |
Public Attributes | |
| double | surf |
| double | dMs |
| Eigen::Vector3d | n |
Public Attributes inherited from element< N, NPI > | |
| 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 |
Private Member Functions | |
| void | orientate (void) |
| Eigen::Vector3d | normal_vect () const |
Additional Inherited Members | |
Protected Member Functions inherited from element< N, NPI > | |
| const Nodes::Node & | getNode (const int i) const |
| void | zeroBasing (void) |
Tri is a class containing the index references to nodes, its surface and its normal unit vector, it has a triangular shape and should not be degenerated, orientation must be defined in adequation with the mesh
|
inline |
constructor used by readMesh Warning: mesh::indexReorder method call it with both _NOD = 0 and _p_node.size() > 0 TODO: get rid of _NOD and rewrite mesh::indexReorder
| [in] | _p_node | vector of nodes |
| [in] | _NOD | it is equal to _p_node.size() except if _NOD == 0 |
| [in] | _idx | region index in region vector |
| [in] | _i | node index |
| double Tri::anisotropyEnergy | ( | Triangle::prm const & | param, |
| Eigen::Ref< Eigen::Matrix< double, Nodes::DIM, NPI >> const | u | ||
| ) | const |
anisotropy energy of the triangle
| [in] | param | |
| [in] | u |
|
inline |
computes the norm to the triangle, returns a unit vector
|
inline |
computes surface of the triangle
|
virtual |
computes surface charges, return result on NPI
| [in] | dMs | |
| [in] | getter |
Implements element< N, NPI >.
| void Tri::correctionCharges | ( | std::function< Eigen::Vector3d(Nodes::Node)> | getter, |
| Eigen::Matrix< double, Triangle::NPI, 1 > & | localCharges, | ||
| std::vector< double > & | corr | ||
| ) |
computes correction on surface charges from localCharges input, result directly stored in corr
| [in] | getter | |
| [in] | localCharges | |
| corr | [in|out] |
| double Tri::demagEnergy | ( | Eigen::Ref< Eigen::Matrix< double, Nodes::DIM, NPI >> | u, |
| Eigen::Ref< Eigen::Matrix< double, NPI, 1 >> | phi | ||
| ) | const |
demagnetizing energy of the triangle
| [in] | u | |
| [in] | phi |
|
inlinevirtual |
returns Gauss points in result = vec_nod*Trianglea
Implements element< N, NPI >.
| void Tri::integrales | ( | Triangle::prm const & | params | ) |
computes the integral contribution of the triangular triangle, the only contribution comes from Neel surface anisotropy
| [in] | params |
|
inline |
interpolation function on the output of the getter, mind the transposition: result = transpose(scalar_nod) * a
| [in] | getter | |
| [out] | result |
|
inline |
interpolation function on the output of the getter. result = vec_nod * a
| [in] | getter | |
| [out] | result |
|
inlineprivate |
return normal to the triangle, not normalized
|
inline |
Compares indices on lexicographic order : ind[0] then ind[1] then ind[2].
|
inline |
two triangles are equal if there exists an indices permutation where node indices are the same Warning: it does not take into account orientation (direct or indirect)
|
inlineprivatevirtual |
do nothing function: orientation is done in mesh::indexReorder
Implements element< N, NPI >.
| double Tri::potential | ( | std::function< Eigen::Vector3d(Nodes::Node)> | getter, |
| int | i | ||
| ) | const |
computes correction on potential
| double Triangle::Tri::dMs |
difference (d for delta) of magnetization at the triangle between corresponding tetrahedrons
| Eigen::Vector3d Triangle::Tri::n |
normal vector (unit vector)
| double Triangle::Tri::surf |
surface of the element