|
Feellgood
|
#include <linear_algebra.h>
Public Member Functions | |
| LinAlgebra (Settings &s, Mesh::mesh &my_msh) | |
| void | checkBoundaryConditions (void) const override |
| void | prepareElements (const Eigen::Vector3d &Hext, const timing &t_prm) const |
| void | prepareElements (const double A_Hext, const timing &t_prm) const |
| void | buildInitGuess (std::vector< double > &G) const |
| bool | solve (const timing &t_prm) |
| void | set_DW_vz (const double vz) |
| double | get_v_max (void) const |
| void | base_projection () const |
Public Member Functions inherited from solver< DIM_PB_MAG > | |
| solver (Mesh::mesh &_msh, const std::vector< Tetra::prm > &_pTetra, const std::vector< Triangle::prm > &_pTri, const std::string &name, const double _tol, const bool v, const int max_iter, const std::function< bool(Mesh::Edge)> &edge_filter=[](Mesh::Edge) { return true;}) | |
Private Attributes | |
| Nodes::index | idx_dir |
| std::vector< double > | Xw |
| const int | verbose |
| double | DW_vz |
| double | v_max |
| const std::vector< Eigen::Matrix< double, Nodes::DIM, Tetra::NPI > > & | extSpaceField |
| std::vector< int > | lvd |
Additional Inherited Members | |
Protected Member Functions inherited from solver< DIM_PB_MAG > | |
| algebra::MatrixShape | build_shape (const std::function< bool(Mesh::Edge)> &edge_filter) const |
| void | buildMat (std::array< int, N > &ind, Eigen::Matrix< double, DIM_PROBLEM *N, DIM_PROBLEM *N > &Ke) |
| void | buildVect (std::array< int, N > &ind, std::vector< double > &Le) |
Protected Attributes inherited from solver< DIM_PB_MAG > | |
| Mesh::mesh * | msh |
| const int | NOD |
| const std::vector< Tetra::prm > & | paramTet |
| const std::vector< Triangle::prm > & | paramTri |
| const bool | verbose |
| algebra::iteration< double > | iter |
| algebra::SparseMatrix | K |
| std::vector< double > | L_rhs |
Static Protected Attributes inherited from solver< DIM_PB_MAG > | |
| static const int | DIM_PB |
convenient class to grab altogether some part of the calculations involved using algebra::bicg solver at each timestep. The solver is handled by solver method, and is using algebra sparse matrices(Row major). Times are reduced times, the unknown is the velocity du/dtau in reduced time. The bicg algorithm is monitored by iter object. When debugging it might be usefull to set iter verbosity differently from LinAlgebra Solver (see constructor list initialization)
|
inline |
constructor When debugging it might be usefull to set iter verbosity differently
| [in] | s | |
| [in] | my_msh |
| void LinAlgebra::base_projection | ( | ) | const |
computes local vector basis {ep,eq} in the tangeant plane for projection on the elements
| void LinAlgebra::buildInitGuess | ( | std::vector< double > & | G | ) | const |
build init guess for bicg solver
| [out] | G |
|
inlineoverridevirtual |
check LLG boundary conditions
Implements solver< DIM_PB_MAG >.
|
inline |
getter for v_max
| void LinAlgebra::prepareElements | ( | const double | A_Hext, |
| const timing & | t_prm | ||
| ) | const |
computes inner data structures of tetraedrons and triangular triangles (K matrices and L vectors) this member function is overloaded to fit to two different situations, either if std::function passed to element = tetra is corresponding to the simple case of constant external field applied to the magnetic region or space dependant. Here is the variable space applied field.
| [in] | A_Hext | amplitude applied field (might be time dependant) |
| [in] | t_prm |
| void LinAlgebra::prepareElements | ( | const Eigen::Vector3d & | Hext, |
| const timing & | t_prm | ||
| ) | const |
computes inner data structures of tetraedrons and triangular triangles (K matrices and L vectors) this member function is overloaded to fit to two different situations, either if std::function passed to element = tetra is corresponding to the simple case of constant external field applied to the magnetic region or space dependant. Here is the constant space applied field.
| [in] | Hext | applied field |
| [in] | t_prm |
|
inline |
setter for DW_dz
| [in] | vz |
| bool LinAlgebra::solve | ( | const timing & | t_prm | ) |
call the solver, uses stabilized biconjugate gradient solver (bicg) with diagonal preconditionner, sparse matrix and vector are filled with multiThreading. Sparse matrix is row major.
| [in] | t_prm |
|
private |
speed of the domain wall [m/s]
|
private |
external applied space field, values on gauss points, size is number of tetraedrons
|
private |
recentering index direction if any
|
private |
list of the Dirichlet indices where (vp,vq) are zero, initialized by constructor
|
private |
maximum speed of the magnetization in the whole physical object
|
private |
verbosity
|
private |
solution of the system to solve