/**
* Indicate which part of the spectrum is to be computed. By
- * default largest magnitude eigenvalues are computed. For other
- * allowed values see the SLEPc documentation.
+ * default largest magnitude eigenvalues are computed.
+ *
+ * @note For other allowed values see the SLEPc documentation.
*/
void
set_which_eigenpairs (EPSWhich set_which);
+ /**
+ * Specify the type of the eigenspectrum problem. This can be used
+ * to exploit known symmetries of the matrices that make up the
+ * standard/generalized eigenspectrum problem. By default a
+ * non-Hermitian problem is assumed.
+ *
+ * @note For other allowed values see the SLEPc documentation.
+ */
+ void
+ set_problem_type (EPSProblemType set_problem);
+
/**
* Solve the linear system for n_eigenvectors
* eigenstates. Parameter <code>n_converged</code> contains the
*/
EPSWhich set_which;
+ /**
+ * Set the eigenspectrum problem type.
+ */
+ EPSProblemType set_problem;
+
/**
* The matrix $A$ of the generalized eigenvalue problem
* $Ax=B\lambda x$, or the standard eigenvalue problem $Ax=\lambda
std::vector<OutputVector> &vr,
const unsigned int n_eigenvectors = 1)
{
+ // Panic if no eigenpairs are wanted.
+ AssertThrow (n_eigenvectors != 0, ExcSLEPcWrappersUsageError());
+
unsigned int n_converged = 0;
// Set the matrices of the problem
std::vector<OutputVector> &vr,
const unsigned int n_eigenvectors = 1)
{
+ // Panic if no eigenpairs are wanted.
+ AssertThrow (n_eigenvectors != 0, ExcSLEPcWrappersUsageError());
+
unsigned int n_converged = 0;
// Set the matrices of the problem
solver_control (cn),
mpi_communicator (mpi_communicator),
set_which (EPS_LARGEST_MAGNITUDE),
+ set_problem (EPS_NHEP),
opA (NULL),
opB (NULL),
initial_vector (NULL),
set_which = eps_which;
}
+ void
+ SolverBase::set_problem_type (const EPSProblemType eps_problem)
+ {
+ set_problem = eps_problem;
+ }
+
void
SolverBase::solve (const unsigned int n_eigenvectors,
unsigned int *n_converged)