Feellgood
|
#include <linear_algebra.h>
Public Member Functions | |
LinAlgebra (Settings &s, Mesh::mesh &my_msh) | |
void | prepareElements (Eigen::Vector3d const &Hext, timing const &t_prm) |
void | prepareElements (double const A_Hext, timing const &t_prm) |
void | buildInitGuess (Eigen::Ref< Eigen::VectorXd > G) const |
int | solver (timing const &t_prm) |
void | set_DW_vz (double vz) |
double | get_v_max (void) |
void | setExtSpaceField (Settings &s) |
void | base_projection () |
Private Attributes | |
Nodes::index | idx_dir |
const int | NOD |
const int | MAXITER |
const double | TOL |
double | ILU_tol |
double | ILU_fill_factor |
const int | verbose |
const std::vector< Tetra::prm > & | prmTetra |
const std::vector< Facette::prm > & | prmFacette |
Mesh::mesh * | refMsh |
double | DW_vz |
double | v_max |
std::vector< Eigen::Matrix< double, Nodes::DIM, Tetra::NPI > > | extSpaceField |
convenient class to grab altogether some part of the calculations involved using eigen BiCGSTAB solver at each timestep. The solver is handled by solver method, and is using Eigen::SparseMatrix, Row major matrix. This matrix is prepared in 'batch mode', using a vector of triplets (also called COO write sparse matrix).
|
inline |
constructor
[in] | s | |
[in] | my_msh |
void LinAlgebra::base_projection | ( | ) |
computes local vector basis {ep,eq} in the tangeant plane for projection on the elements
void LinAlgebra::buildInitGuess | ( | Eigen::Ref< Eigen::VectorXd > | G | ) | const |
build init guess for bicgstab solver
|
inline |
getter for v_max
void LinAlgebra::prepareElements | ( | double const | A_Hext, |
timing const & | t_prm | ||
) |
computes inner data structures of tetraedrons and triangular facettes (K matrices and L vectors)
[in] | A_Hext | amplitude applied field |
[in] | t_prm |
void LinAlgebra::prepareElements | ( | Eigen::Vector3d const & | Hext, |
timing const & | t_prm | ||
) |
computes inner data structures of tetraedrons and triangular facettes (K matrices and L vectors)
[in] | Hext | applied field |
[in] | t_prm |
|
inline |
setter for DW_dz
[in] | vz |
void LinAlgebra::setExtSpaceField | ( | Settings & | s | ) |
when external applied field is of field_type R4toR3 values of field_space are stored in spaceField
[in] | s |
int LinAlgebra::solver | ( | timing const & | t_prm | ) |
solver, uses eigen stabilized biconjugate gradient solver (bicgstab) with ILU preconditionner, sparse matrix and vector are filled with multiThreading. Sparse matrix is row major.
[in] | t_prm |
|
private |
speed of the domain wall
|
private |
external applied space field, values on gauss points, size is number of tetraedrons
|
private |
recentering index direction if any
|
private |
ILU preconditionner filling factor
|
private |
ILU preconditionner tolerance
|
private |
maximum number of iteration for bicgstab
|
private |
number of nodes, also an offset for filling sparseMatrix, initialized by constructor
|
private |
material parameters of the facettes
|
private |
material parameters of the tetrahedrons
|
private |
direct access to the mesh
|
private |
solver tolerance
|
private |
maximum speed of the magnetization in the whole physical object
|
private |
verbosity