AbsEqua< T_ > Class Template Reference
Mother abstract class to describe equation. More...
Inheritance diagram for AbsEqua< T_ >:
Public Member Functions | |
| AbsEqua () | |
| Default constructor. | |
| AbsEqua (class Mesh &mesh) | |
| Constructor with mesh instance. | |
| virtual | ~AbsEqua () |
| Destructor. | |
| void | setMesh (class Mesh &m) |
| Define mesh and renumber DOFs after removing imposed ones. | |
| Mesh & | getMesh () const |
| Return reference to Mesh instance. | |
| LinearSolver< T_ > & | getLinearSolver () |
| Return reference to linear solver instance. | |
| void | setSolver (int ls, int pc=IDENT_PREC) |
| Choose solver for the linear system. | |
| int | solveEigenProblem (int nb_eigv, bool g=false) |
| Compute eigenvalues and eigenvectors. | |
| double | getEigenValue (int n) const |
| Return the n-th eigenvalue. | |
| void | getEigenVector (int n, Vect< double > &v) const |
| Store the eigenvector corresponding to a given eigenvalue. | |
| class Eigen & | getEigenSolver () |
| Return reference to eigenproblem solver. | |
Detailed Description
template<class T_>
class OFELI::AbsEqua< T_ >
Mother abstract class to describe equation.
- Template Parameters:
-
<T_> Data type (double, float, complex<double>, ...)
Member Function Documentation
| void setSolver | ( | int | ls, |
| int | pc = IDENT_PREC |
||
| ) |
Choose solver for the linear system.
- Parameters:
-
[in] ls Solver of the linear system. To choose among the enumerated values: DIRECT_SOLVER, CG_SOLVER, GMRES_SOLVER - = DIRECT_SOLVER, Use a facorization solver [default]
- = CG_SOLVER, Conjugate Gradient iterative solver
- = CGS_SOLVER, Squared Conjugate Gradient iterative solver
- = BICG_SOLVER, BiConjugate Gradient iterative solver
- = BICG_STAB_SOLVER, BiConjugate Gradient Stabilized iterative solver
- = GMRES_SOLVER, GMRES iterative solver
- = QMR_SOLVER, QMR iterative solver
[in] pc Preconditioner to associate to the iterative solver. if the direct solver was chosen for the first argument this argument is not used. Otherwise choose among the enumerated values: - = IDENT_PREC, Identity preconditioner (no preconditioning [ default ]
- = DIAG_PREC, Diagonal preconditioner
- = ILU_PREC, Incomplete LU factorization preconditioner
| int solveEigenProblem | ( | int | nb_eigv, |
| bool | g = false |
||
| ) |
Compute eigenvalues and eigenvectors.
Eigenvalues and vectors are computed using the Bathe's subspace iteration method.
- Parameters:
-
[in] nb_eigv Number of eigenvalues to compute [in] g Option to choose whether to solve a generalized eigenvalue problem (true) or a standard one (false). The generalized eigenvalue problem corresponds to the case where a consistent mass matrix (rather than a lumped one) is computed. Default value is false.
| double getEigenValue | ( | int | n | ) | const |
Return the n-th eigenvalue.
This functions works only if the member function getEigen was called with an argument nb_eigv greater or equal to n. Otherwise it returns 0.
| void getEigenVector | ( | int | n, |
| Vect< double > & | v | ||
| ) | const |
Store the eigenvector corresponding to a given eigenvalue.
- Parameters:
-
[in] n Label of the eigenvalue [out] v Vect instance containing the corresponding eigenvector. This vector is resized.
- OFELI
- AbsEqua
Copyright © 1998-2012 Rachid Touzani