BSpline Finite Element Exterior Calculus
Loading...
Searching...
No Matches
m_mform_eigensolver::eigensolver Type Reference

Type that wraps SLEPc functionality for solving (generalized) eigenvalue problems. More...

Public Member Functions

procedure init (this, amat, bmat, constraint1, constraint2, constraint3, coord_transform, options)
 Initialize the eigensolver.
 
procedure solve (this, rtol, max_iter, nr_pairs, verbosity)
 Solve the eigenvalue problem.
 
procedure get_eigenpair (this, index, val_r, fun_r, val_i, fun_i, err_est)
 Get an eigenpair.
 
procedure get_eigenvalues (this, vals_r, vals_i)
 Get all computed eigenvalues.
 
procedure destroy (this)
 Destroy the eigensolver and free associated resources.
 

Public Attributes

type(mformspace) space_row
 The SLEPc eigensolver context.
 
type(mformconstraint), allocatable constraint
 The optional constraint.
 
integer nr_pairs
 
type(eigeninitoptionsoptions
 

Detailed Description

Type that wraps SLEPc functionality for solving (generalized) eigenvalue problems.

Member Function/Subroutine Documentation

◆ destroy()

procedure m_mform_eigensolver::eigensolver::destroy ( class(eigensolver), intent(inout) this)

Destroy the eigensolver and free associated resources.

Parameters
thisThe EigenSolver object

◆ get_eigenpair()

procedure m_mform_eigensolver::eigensolver::get_eigenpair ( class(eigensolver), intent(in) this,
integer, intent(in) index,
real(wp), intent(out) val_r,
type(mformfun), intent(out) fun_r,
real(wp), intent(out), optional val_i,
type(mformfun), intent(out), optional fun_i,
real(wp), intent(out), optional err_est )

Get an eigenpair.

Parameters
thisThe EigenSolver object
indexThe index of the eigenpair to get (1-based)
val_rThe real part of the eigenvalue
fun_rThe real part of the eigenfunction
val_i_(optional)_ The imaginary part of the eigenvalue
fun_i_(optional)_ The imaginary part of the eigenfunction
err_est_(optional)_ The error estimate for the eigenpair

◆ get_eigenvalues()

procedure m_mform_eigensolver::eigensolver::get_eigenvalues ( class(eigensolver), intent(in) this,
real(wp), dimension(:), intent(out), allocatable vals_r,
real(wp), dimension(:), intent(out), optional, allocatable vals_i )

Get all computed eigenvalues.

Parameters
thisThe EigenSolver object
vals_rThe real parts of the eigenvalues
vals_i_(optional)_ The imaginary parts of the eigenvalues

◆ init()

procedure m_mform_eigensolver::eigensolver::init ( class(eigensolver), intent(inout) this,
class(abstractmatrix), intent(in) amat,
class(abstractmatrix), intent(in), optional bmat,
class(mformconstraintlocal), intent(in), optional constraint1,
class(mformconstraintlocal), intent(in), optional constraint2,
class(mformconstraintlocal), intent(in), optional constraint3,
class(coordtransformabstract), intent(in), optional coord_transform,
type(eigeninitoptions), intent(in), optional options )

Initialize the eigensolver.

Parameters
thisThe EigenSolver object
amatThe matrix A in the eigenvalue problem: $A x = \lambda x$
bmat_(optional)_ The matrix B in the eigenvalue problem: $A x = \lambda B x$
[in]constraint1_(optional)_ An optional constraint to be applied to the solution
[in]constraint2_(optional)_ An optional constraint to be applied to the solution
[in]constraint3_(optional)_ An optional constraint to be applied to the solution
[in]coord_transform_(optional)_ The coordinate transformation associated with the m-form spaces
options_(optional)_ The options for initializing the eigensolver (default: auto-select based on traits)

◆ solve()

procedure m_mform_eigensolver::eigensolver::solve ( class(eigensolver), intent(inout) this,
real(wp), intent(in), optional rtol,
integer, intent(in), optional max_iter,
integer, intent(in), optional nr_pairs,
integer, intent(in), optional verbosity )

Solve the eigenvalue problem.

Parameters
thisThe EigenSolver object
rtol_(optional)_ The relative tolerance (default: 1.e-8)
max_iter_(optional)_ The maximum number of iterations (default: size of the space)
nr_pairs_(optional)_ The number of eigenpairs to compute (default: 6)
verbosity_(optional)_ The verbosity level (default: VERBOSITY_WARN_ON_FAILURE)
  • VERBOSITY_WARN_NEVER
  • VERBOSITY_WARN_ON_FAILURE
  • VERBOSITY_WARN_ALWAYS
  • VERBOSITY_ERROR_ON_FAILURE

Member Data Documentation

◆ space_row

type(mformspace) m_mform_eigensolver::eigensolver::space_row

The SLEPc eigensolver context.

The PETSc matrix (possibly constrained) The m-form space of the residual


The documentation for this type was generated from the following file: