ezarpack/mpi/parpack.hpp - low level C++ interface to FORTRAN routines of PARPACK

namespace f77

External ARPACK-NG subroutines p*aupd()

These subroutines implement the Reverse Communication Interface for the Implicitly Restarted Arnoldi Iteration in MPI parallelized mode.

void pdsaupd_(const MPI_Fint&, int&, const char*, const int&, const char*, const int&, const double&, double[], const int&, double[], const int&, int[], int[], double[], double[], const int&, int&)

External ARPACK-NG FORTRAN 77 subroutine pdsaupd().

void pdnaupd_(const MPI_Fint&, int&, const char*, const int&, const char*, const int&, const double&, double[], const int&, double[], const int&, int[], int[], double[], double[], const int&, int&)

External ARPACK-NG FORTRAN 77 subroutine pdnaupd().

void pznaupd_(const MPI_Fint&, int&, const char*, const int&, const char*, const int&, const double&, dcomplex*, const int&, dcomplex*, const int&, int[], int[], dcomplex*, dcomplex*, const int&, double[], int&)

External ARPACK-NG FORTRAN 77 subroutine pznaupd().

External ARPACK-NG subroutines p*eupd()

These MPI parallelized subroutines return the converged approximations to eigenvalues of \( \hat O \mathbf{z} = \lambda \hat B\mathbf{z} \) and (optionally):

  1. the corresponding approximate eigenvectors;

  2. an orthonormal basis for the associated approximate invariant subspace;

  3. both.

void pdseupd_(const MPI_Fint&, const int&, const char*, const int[], double[], double[], const int&, const double&, const char*, const int&, const char*, const int&, const double&, double[], const int&, double[], const int&, int[], int[], double[], double[], const int&, int&)

External ARPACK-NG FORTRAN 77 subroutine pdseupd().

void pdneupd_(const MPI_Fint&, const int&, const char*, const int[], double[], double[], double[], const int&, const double&, const double&, double[], const char*, const int&, const char*, const int&, const double&, double[], const int&, double[], const int&, int[], int[], double[], double[], const int&, int&)

External ARPACK-NG FORTRAN 77 subroutine pdneupd().

void pzneupd_(const MPI_Fint&, const int&, const char*, const int[], dcomplex*, dcomplex*, const int&, const dcomplex&, dcomplex*, const char*, const int&, const char*, const int&, const double&, dcomplex*, const int&, dcomplex*, const int&, int[], int[], dcomplex*, dcomplex*, const int&, double[], int&)

External ARPACK-NG FORTRAN 77 subroutine pzneupd().

Functions

template<bool Symmetric = false>
inline void paupd(const MPI_Comm &comm, rci_flag &ido, const char *bmat, int n, const char *which, int nev, double tol, double *resid, int ncv, double *v, int ldv, int *iparam, int *ipntr, double *workd, double *workl, int lworkl, int &info)

C++ wrapper for the Reverse Communication Interface ARPACK-NG subroutines pdsaupd_() and pdnaupd_().

Template Parameters:

Symmetric – If true, calls pdsaupd_(), otherwise calls pdnaupd_().

Parameters:
  • comm – MPI communicator.

  • ido – Reverse communication flag.

  • bmat – Specifies the type of the semi-inner product matrix B.

  • n – Dimension of the MPI rank-local vector block.

  • which – Specifies which of the Ritz values of OP to compute.

  • nev – Number of eigenvalues of OP to be computed.

  • tol – Stopping criterion: relative tolerance of the Ritz value.

  • resid – MPI rank-local block of the initial residual vector.

  • ncv – How many Lanczos/Arnoldi vectors to generate at each iteration.

  • v – Contains the final set of Lanczos/Arnoldi basis vectors (MPI rank-local portion).

  • ldv – Leading dimension of v as declared in the calling program.

  • iparam – Array of input/output parameter flags.

  • ipntr – Pointer to mark the starting locations in the workd and workl arrays for matrices/vectors used by the Lanczos/Arnoldi iteration.

  • workd – Array to be used in the basic Lanczos/Arnoldi iteration for reverse communication (MPI rank-local portion).

  • workl – Work array.

  • lworkl – Dimension of workl.

  • info – Initial residual vector type (input) and error codes (output).

inline void paupd(const MPI_Comm &comm, rci_flag &ido, const char *bmat, int n, const char *which, int nev, double tol, dcomplex *resid, int ncv, dcomplex *v, int ldv, int *iparam, int *ipntr, dcomplex *workd, dcomplex *workl, int lworkl, double *rwork, int &info)

C++ wrapper for the Reverse Communication Interface ARPACK-NG subroutine pznaupd_().

Parameters:
  • comm – MPI communicator.

  • ido – Reverse communication flag.

  • bmat – Specifies the type of the semi-inner product matrix B.

  • n – Dimension of the MPI rank-local vector block.

  • which – Specifies which of the Ritz values of OP to compute.

  • nev – Number of eigenvalues of OP to be computed.

  • tol – Stopping criterion: relative tolerance of the Ritz value.

  • resid – MPI rank-local block of the initial residual vector.

  • ncv – How many Arnoldi vectors to generate at each iteration.

  • v – Contains the final set of Arnoldi basis vectors (MPI rank-local portion).

  • ldv – Leading dimension of v as declared in the calling program.

  • iparam – Array of input/output parameter flags.

  • ipntr – Pointer to mark the starting locations in the workd and workl arrays for matrices/vectors used by the Arnoldi iteration.

  • workd – Array to be used in the basic Arnoldi iteration for reverse communication (MPI rank-local portion).

  • workl – Work array.

  • lworkl – Dimension of workl.

  • rwork – Work array of dimension ncv.

  • info – Initial residual vector type (input) and error codes (output).

inline void peupd(const MPI_Comm &comm, int rvec, const char *howmny, const int *select, double *d, double *z, int ldz, double sigma, const char *bmat, int n, const char *which, int nev, double tol, double *resid, int ncv, double *v, int ldv, int *iparam, int *ipntr, double *workd, double *workl, int lworkl, int &info)

C++ wrapper for the post-processing ARPACK-NG subroutine pdseupd_().

Parameters:
  • comm – MPI communicator.

  • rvec – Specifies whether to compute Ritz vectors.

  • howmny – Specifies how many Ritz vectors are wanted.

  • select – Selection of Ritz vectors to be computed.

  • d – Approximate Ritz values (output).

  • z – Approximate B-orthonormal Ritz vectors (output, MPI rank-local portion).

  • ldz – The leading dimension of the array Z.

  • sigma – Shift for spectral transformations.

  • bmat – Specifies the type of the semi-inner product matrix B.

  • n – Dimension of the MPI rank-local vector block.

  • which – Specifies which of the Ritz values of OP to compute.

  • nev – Number of eigenvalues of OP to be computed.

  • tol – Stopping criterion: relative tolerance of the Ritz value.

  • resid – MPI rank-local block of the initial residual vector.

  • ncv – How many Lanczos vectors to generate at each iteration.

  • v – Contains the final set of Lanczos basis vectors (MPI rank-local portion).

  • ldv – Leading dimension of v as declared in the calling program.

  • iparam – Array of input/output parameter flags.

  • ipntr – Pointer to mark the starting locations in the workd and workl arrays for matrices/vectors used by the Lanczos iteration.

  • workd – Array to be used in the basic Lanczos iteration for reverse communication (MPI rank-local portion).

  • workl – Work array.

  • lworkl – Dimension of workl.

  • info – Initial residual vector type (input) and error codes (output).

inline void peupd(const MPI_Comm &comm, int rvec, const char *howmny, const int *select, double *dr, double *di, double *z, int ldz, double sigmar, double sigmai, double *workev, const char *bmat, int n, const char *which, int nev, double tol, double *resid, int ncv, double *v, int ldv, int *iparam, int *ipntr, double *workd, double *workl, int lworkl, int &info)

C++ wrapper for the post-processing ARPACK-NG subroutine pdneupd_().

Parameters:
  • comm – MPI communicator.

  • rvec – Specifies whether to compute Ritz/Schur vectors.

  • howmny – Specifies the form of the basis for the invariant subspace.

  • select – Selection of Ritz vectors to be computed.

  • dr – Real parts of approximate Ritz values (output).

  • di – Imaginary parts of approximate Ritz values (output).

  • z – Approximate B-orthonormal Ritz vectors (output, MPI rank-local portion).

  • ldz – The leading dimension of the array Z.

  • sigmar – Real part of the shift for spectral transformations.

  • sigmai – Imaginary part of the shift for spectral transformations.

  • workev – Work array.

  • bmat – Specifies the type of the semi-inner product matrix B.

  • n – Dimension of the MPI rank-local vector block.

  • which – Specifies which of the Ritz values of OP to compute.

  • nev – Number of eigenvalues of OP to be computed.

  • tol – Stopping criterion: relative tolerance of the Ritz value.

  • resid – MPI rank-local block of the initial residual vector.

  • ncv – How many Arnoldi vectors to generate at each iteration.

  • v – Contains the final set of Arnoldi basis vectors (MPI rank-local portion).

  • ldv – Leading dimension of v as declared in the calling program.

  • iparam – Array of input/output parameter flags.

  • ipntr – Pointer to mark the starting locations in the workd and workl arrays for matrices/vectors used by the Arnoldi iteration.

  • workd – Array to be used in the basic Arnoldi iteration for reverse communication (MPI rank-local portion).

  • workl – Work array.

  • lworkl – Dimension of workl.

  • info – Initial residual vector type (input) and error codes (output).

inline void peupd(const MPI_Comm &comm, int rvec, const char *howmny, const int *select, dcomplex *d, dcomplex *z, int ldz, dcomplex sigma, dcomplex *workev, const char *bmat, int n, const char *which, int nev, double tol, dcomplex *resid, int ncv, dcomplex *v, int ldv, int *iparam, int *ipntr, dcomplex *workd, dcomplex *workl, int lworkl, double *rwork, int &info)

C++ wrapper for the post-processing ARPACK-NG subroutine pzneupd_().

Parameters:
  • comm – MPI communicator.

  • rvec – Specifies whether to compute Ritz/Schur vectors.

  • howmny – Specifies the form of the basis for the invariant subspace.

  • select – Selection of Ritz vectors to be computed.

  • d – Approximate Ritz values (output).

  • z – Approximate B-orthonormal Ritz vectors (output, MPI rank-local portion).

  • ldz – The leading dimension of the array Z.

  • sigma – Shift for spectral transformations.

  • workev – Work array.

  • bmat – Specifies the type of the semi-inner product matrix B.

  • n – Dimension of the MPI rank-local vector block.

  • which – Specifies which of the Ritz values of OP to compute.

  • nev – Number of eigenvalues of OP to be computed.

  • tol – Stopping criterion: relative tolerance of the Ritz value.

  • resid – MPI rank-local block of the initial residual vector.

  • ncv – How many Arnoldi vectors to generate at each iteration.

  • v – Contains the final set of Arnoldi basis vectors (MPI rank-local portion).

  • ldv – Leading dimension of v as declared in the calling program.

  • iparam – Array of input/output parameter flags.

  • ipntr – Pointer to mark the starting locations in the workd and workl arrays for matrices/vectors used by the Arnoldi iteration.

  • workd – Array to be used in the basic Arnoldi iteration for reverse communication (MPI rank-local portion).

  • workl – Work array.

  • lworkl – Dimension of workl.

  • rwork – Work array of dimension ncv.

  • info – Initial residual vector type (input) and error codes (output).