11#ifndef CL_FEM_DOFMGR_EIGENVALUES_HPP
12#define CL_FEM_DOFMGR_EIGENVALUES_HPP
81 int_t mNumMinVals = 1 ;
82 int_t mNumMaxVals = 1 ;
83 int_t mNumMaxIter = 300 ;
91 bool mSubspaceSizeExplicit = false ;
92 bool mToleranceExplicit = false ;
93 bool mNumMaxIterExplicit = false ;
108 real mEpsilon = 1e-4 ;
113 int_t mSubspaceSize = 20 ;
127 real mFoldEpsilon = 1e-10 ;
142 size_t mBasisBudget = 512UL * 1024UL * 1024UL ;
160 bool mDiagnosticUnavailable = false ;
170 const char * mRunLabel =
"eigenvalue" ;
180 bool mSymmetric = false ;
205 Solver * mShiftInvertSolver = nullptr ;
219 bool mSubspaceInfeasible = false ;
226 int_t mFailureCount = 0 ;
227 int_t mMaxFailures = 3 ;
233 string mBackendLabel =
"ARPACK" ;
254 bool mMatrixFlag = false ;
255 bool mFirstRun = true ;
257 Solver * mSolver = nullptr ;
259 int_t mOriginalBase = 0 ;
279 const SpMatrix * mDistSource = nullptr ;
280 int_t mDistNumRows = 0 ;
281 int_t mDistNumNonzeros = 0 ;
458 configure(
const int_t aJob,
460 const int_t aNumEigenValues,
461 int_t & aSubspaceSize,
463 real & aTolerance ) ;
470 run(
const int_t aJob,
const real aSigma );
476 run_arpack(
const int_t aJob,
const real aSigma );
479 run_parpack(
const int_t aJob,
const real aSigma );
487 reduce_extremum(
const int_t aJob,
const int_t aNumConverged );
495 report_unavailable(
const int_t aOutcome );
515 run_shift_invert(
int_t & aOutcome );
518 restore_indexing_base();
549 inline const string &
552 return mBackendLabel ;
Unified interface to the sparse direct solvers.
Definition cl_Solver.hpp:34
Sparse matrix in CSR or CSC format.
Definition cl_SpMatrix.hpp:52
this class creates the DOFs based on the passed equation object.
Definition cl_FEM_DofManager.hpp:55
int_t number_of_converged_values() const
how many of the requested values actually converged
Definition cl_FEM_DofMgr_EigenValues.hpp:542
void set_num_minvals(const index_t aNumMinVals)
Definition cl_FEM_DofMgr_EigenValues.cpp:131
real compute_smallest_eigenvalues()
compute the eigenvalues at one end of the spectrum and return the extremal magnitude found there.
Definition cl_FEM_DofMgr_EigenValues.cpp:914
EigenOutcome outcome() const
how the last compute_conditioning() ended.
Definition cl_FEM_DofMgr_EigenValues.hpp:566
const string & backend_label() const
"ARPACK" or "PARPACK", whichever drove the last call
Definition cl_FEM_DofMgr_EigenValues.hpp:550
const Vector< real > & lambda_imag() const
Definition cl_FEM_DofMgr_EigenValues.hpp:534
const Vector< real > & lambda_real() const
real and imaginary parts of the values found by the last call above.
Definition cl_FEM_DofMgr_EigenValues.hpp:526
void set_max_iterations(const index_t aNumMaxIter)
restart budget handed to ( p )dnaupd.
Definition cl_FEM_DofMgr_EigenValues.cpp:202
EigenValues & operator=(const EigenValues &)=delete
void set_tolerance(const real aTolerance)
relative accuracy demanded of each Ritz value.
Definition cl_FEM_DofMgr_EigenValues.cpp:162
EigenValues(const EigenValues &)=delete
real compute_lambda_max()
Definition cl_FEM_DofMgr_EigenValues.cpp:1647
real compute_conditioning()
Definition cl_FEM_DofMgr_EigenValues.cpp:929
EigenValues(DofManager *aParent)
Definition cl_FEM_DofMgr_EigenValues.cpp:41
void set_num_maxvals(const index_t aNumMaxVals)
Definition cl_FEM_DofMgr_EigenValues.cpp:147
EigenValues(EigenValues &&)=delete
void set_symmetric(const bool aSymmetric)
declare the matrix symmetric, selecting dsaupd / dseupd over dnaupd / dneupd.
Definition cl_FEM_DofMgr_EigenValues.cpp:194
real compute_largest_eigenvalues()
Definition cl_FEM_DofMgr_EigenValues.cpp:922
void set_subspace_size(const index_t aSubspaceSize)
floor for the Krylov subspace.
Definition cl_FEM_DofMgr_EigenValues.cpp:178
void reset()
Definition cl_FEM_DofMgr_EigenValues.cpp:1803
EigenValues & operator=(EigenValues &&)=delete
bool is_symmetric() const
whether the spectral ratio this object returns may be called kappa_2.
Definition cl_FEM_DofMgr_EigenValues.hpp:558
Definition cl_SolverDistMatrix.hpp:147
constexpr index_t gInfoNumConverged
index of the number of converged Ritz values
Definition arpacktools.hpp:33
Definition cl_SolverDistMatrix.cpp:21
USER GUIDES:
Definition cl_Capacitor.cpp:16
int proc_t
Definition commtypes.hpp:29
ArpackWhat
Definition cl_FEM_DofMgr_EigenValues.hpp:52
@ LambaMinMagn
Definition cl_FEM_DofMgr_EigenValues.hpp:53
@ LambaMaxImag
Definition cl_FEM_DofMgr_EigenValues.hpp:58
@ LambaMaxMagn
Definition cl_FEM_DofMgr_EigenValues.hpp:54
@ LambaMinImag
Definition cl_FEM_DofMgr_EigenValues.hpp:57
@ LambaMinReal
Definition cl_FEM_DofMgr_EigenValues.hpp:55
@ LambaMaxReal
Definition cl_FEM_DofMgr_EigenValues.hpp:56
EigenOutcome
Definition cl_FEM_DofMgr_EigenValues.hpp:38
@ Complex
the winning Ritz value is not real
Definition cl_FEM_DofMgr_EigenValues.hpp:42
@ Infeasible
no legal ncv fits the basis budget, or no usable solver
Definition cl_FEM_DofMgr_EigenValues.hpp:44
@ NotPositiveDefinite
shift-invert returned lambda_min <= 0: the ratio is not a condition number
Definition cl_FEM_DofMgr_EigenValues.hpp:41
@ Ok
a usable value came back
Definition cl_FEM_DofMgr_EigenValues.hpp:39
@ Inconsistent
shift-invert returned lambda_min > rho, which cannot be
Definition cl_FEM_DofMgr_EigenValues.hpp:43
@ NotConverged
ARPACK ran out of restarts.
Definition cl_FEM_DofMgr_EigenValues.hpp:40
@ SolverFailed
Definition cl_FEM_DofMgr_EigenValues.hpp:45
uint32_t index_t
Definition typedefs.hpp:52
double real
Definition typedefs.hpp:36
int32_t int_t
Definition typedefs.hpp:51
#define BELFEM_QUIET_NAN
Definition typedefs.hpp:87