Classes

SLEPcWrappers Namespace Reference
[SLEPcWrappers]

Classes

class  SolverBase
class  SolverKrylovSchur
class  SolverArnoldi
class  SolverLanczos
class  SolverPower
class  TransformationBase
class  TransformationShift
class  TransformationShiftInvert
class  TransformationSpectrumFolding
class  TransformationCayley

Detailed Description

Base class for solver classes using the SLEPc solvers which are selected based on flags passed to the eigenvalue problem solver context. Derived classes set the right flags to set the right solver. Note that: the AdditionalData structure is a dummy structure that currently exists for backward/forward compatibility only.

The SLEPc solvers are intended to be used for solving the generalized eigenspectrum problem $(A-\lambda B)x=0$, for $x\neq0$; where $A$ is a system matrix, $B$ is a mass matrix, and $\lambda, x$ are a set of eigenvalues and eigenvectors respectively. The emphasis is on methods and techniques appropriate for problems in which the associated matrices are sparse. Most of the methods offered by the SLEPc library are projection methods or other methods with similar properties; and wrappers are provided to interface to SLEPc solvers that handle both of these problem sets.

SLEPcWrappers can be implemented in application codes in the following way:

  SolverControl solver_control (1000, 1e-9);
  SolverArnoldi system (solver_control, mpi_communicator);
  system.solve (A, B, lambda, x, size_of_spectrum);
 

for the generalized eigenvalue problem $Ax=B\lambda x$, where the variable const unsigned int size_of_spectrum tells SLEPc the number of eigenvector/eigenvalue pairs to solve for: See also step-36 for a hands-on example.

An alternative implementation to the one above is to use the API internals directly within the application code. In this way the calling sequence requires calling several of SolverBase functions rather than just one. This freedom is intended for use of the SLEPcWrappers that require a greater handle on the eigenvalue problem solver context. See also the API of:

  template <typename OutputVector>
  void
  SolverBase::solve (const PETScWrappers::MatrixBase &A,
                     const PETScWrappers::MatrixBase &B,
                     std::vector<double>             &kr,
                     std::vector<OutputVector>       &vr,
                     const unsigned int               n_eigenvectors)
  { ... }
 

as an example on how to do this.

For further information and explanations on handling the SLEPcWrappers, see also the PETScWrappers, on which they depend.

Author:
Toby D. Young 2008, 2009, 2010; and Rickard Armiento 2008.
Note:
Various tweaks and enhancments contributed by Eloy Romero and Jose E. Roman 2009, 2010.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

deal.II documentation generated on Fri Feb 3 2012 06:04:16 by doxygen 1.7.2