Epetra Package Browser (Single Doxygen Collection) Development
Epetra_LAPACK.h
Go to the documentation of this file.
00001 /*
00002 //@HEADER
00003 // ************************************************************************
00004 // 
00005 //               Epetra: Linear Algebra Services Package 
00006 //                 Copyright 2001 Sandia Corporation
00007 // 
00008 // Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
00009 // the U.S. Government retains certain rights in this software.
00010 //
00011 // Redistribution and use in source and binary forms, with or without
00012 // modification, are permitted provided that the following conditions are
00013 // met:
00014 //
00015 // 1. Redistributions of source code must retain the above copyright
00016 // notice, this list of conditions and the following disclaimer.
00017 //
00018 // 2. Redistributions in binary form must reproduce the above copyright
00019 // notice, this list of conditions and the following disclaimer in the
00020 // documentation and/or other materials provided with the distribution.
00021 //
00022 // 3. Neither the name of the Corporation nor the names of the
00023 // contributors may be used to endorse or promote products derived from
00024 // this software without specific prior written permission.
00025 //
00026 // THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
00027 // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
00028 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
00029 // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
00030 // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
00031 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
00032 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
00033 // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
00034 // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
00035 // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
00036 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00037 //
00038 // Questions? Contact Michael A. Heroux (maherou@sandia.gov) 
00039 // 
00040 // ************************************************************************
00041 //@HEADER
00042 */
00043 
00044 #ifndef EPETRA_LAPACK_H
00045 #define EPETRA_LAPACK_H
00046 
00048 
00064 #include "Epetra_ConfigDefs.h"
00065 #include "Epetra_Object.h"
00066 
00067 class EPETRA_LIB_DLL_EXPORT Epetra_LAPACK {
00068     
00069   public:
00071 
00072 
00073 
00075   Epetra_LAPACK(void);
00076 
00077 
00079 
00081   Epetra_LAPACK(const Epetra_LAPACK& LAPACK);
00082 
00084   virtual ~Epetra_LAPACK(void);
00086 
00087 
00089 
00090   
00092   void POTRF( const char UPLO, const int N, float * A, const int LDA, int * INFO) const;
00094   void POTRF( const char UPLO, const int N, double * A, const int LDA, int * INFO) const;
00095 
00097   void POTRS( const char UPLO, const int N, const int NRHS, const float * A, const int LDA, float * X, const int LDX, int * INFO) const;
00099   void POTRS( const char UPLO, const int N, const int NRHS, const double * A, const int LDA, double * X, const int LDX, int * INFO) const;
00100 
00102   void POTRI( const char UPLO, const int N, float * A, const int LDA, int * INFO) const;
00104   void POTRI( const char UPLO, const int N, double * A, const int LDA, int * INFO) const;
00105 
00107   void POCON( const char UPLO, const int N, const float * A, const int LDA, const float ANORM, 
00108         float * RCOND, float * WORK, int * IWORK, int * INFO) const;
00110   void POCON( const char UPLO, const int N, const double * A, const int LDA, const double ANORM, 
00111         double * RCOND, double * WORK, int * IWORK, int * INFO) const;
00112 
00114   void POSV( const char UPLO, const int N, const int NRHS, float * A, const int LDA, float * X, const int LDX, int * INFO) const;
00116   void POSV( const char UPLO, const int N, const int NRHS, double * A, const int LDA, double * X, const int LDX, int * INFO) const;
00117 
00119   void POEQU(const int N, const float * A, const int LDA, float * S, float * SCOND, float * AMAX, int * INFO) const;
00121   void POEQU(const int N, const double * A, const int LDA, double * S, double * SCOND, double * AMAX, int * INFO) const;
00122 
00124   void PORFS(const char UPLO, const int N, const int NRHS, const float * A, const int LDA, const float * AF, const int LDAF, 
00125        const float * B, const int LDB, float * X, const int LDX, 
00126        float * FERR, float * BERR, float * WORK, int * IWORK, int * INFO) const;
00128   void PORFS(const char UPLO, const int N, const int NRHS, const double * A, const int LDA, const double * AF, const int LDAF, 
00129        const double * B, const int LDB, double * X, const int LDX,
00130        double * FERR, double * BERR, double * WORK, int * IWORK, int * INFO) const;
00131 
00133   void POSVX(const char FACT, const char UPLO, const int N, const int NRHS, float * A, const int LDA, float * AF, const int LDAF, 
00134        const char EQUED, float * S, float * B, const int LDB, float * X, const int LDX, float * RCOND, 
00135        float * FERR, float * BERR, float * WORK, int * IWORK, int * INFO) const;
00137   void POSVX(const char FACT, const char UPLO, const int N, const int NRHS, double * A, const int LDA, double * AF, const int LDAF, 
00138        const char EQUED, double * S, double * B, const int LDB, double * X, const int LDX, double * RCOND, 
00139        double * FERR, double * BERR, double * WORK, int * IWORK, int * INFO) const;
00141 
00143 
00144 
00146   void GELS( const char TRANS, const int M, const int N, const int NRHS, double* A, const int LDA, 
00147     double* B, const int LDB, double* WORK, const int LWORK, int * INFO) const;
00149   void GETRF( const int M, const int N, float * A, const int LDA, int * IPIV, int * INFO) const;
00151   void GETRF( const int M, const int N, double * A, const int LDA, int * IPIV, int * INFO) const;
00152 
00154   void GEQRF( const int M, const int N,  float * A, const int LDA,  float * TAU,  float * WORK, const int lwork, int * INFO) const;
00156   void GEQRF( const int M, const int N, double * A, const int LDA, double * TAU, double * WORK, const int lwork, int * INFO) const;
00157 
00159   void GETRS( const char TRANS, const int N, const int NRHS, const float * A, const int LDA, const int * IPIV, float * X, const int LDX, int * INFO) const;
00161   void GETRS( const char TRANS, const int N, const int NRHS, const double * A, const int LDA, const int * IPIV, double * X, const int LDX, int * INFO) const;
00162 
00164   void GETRI( const int N, float * A, const int LDA, int * IPIV, float * WORK, const int * LWORK, int * INFO) const;
00166   void GETRI( const int N, double * A, const int LDA, int * IPIV, double * WORK, const int * LWORK, int * INFO) const;
00167 
00169   void GECON( const char NORM, const int N, const float * A, const int LDA, const float ANORM, 
00170         float * RCOND, float * WORK, int * IWORK, int * INFO) const;
00172   void GECON( const char NORM, const int N, const double * A, const int LDA, const double ANORM, 
00173         double * RCOND, double * WORK, int * IWORK, int * INFO) const;
00174 
00176   void GESV( const int N, const int NRHS, float * A, const int LDA, int * IPIV, float * X, const int LDX, int * INFO) const;
00178   void GESV( const int N, const int NRHS, double * A, const int LDA, int * IPIV, double * X, const int LDX, int * INFO) const;
00179 
00181   void GEEQU(const int M, const int N, const float * A, const int LDA, float * R, float * C, float * ROWCND, float * COLCND, float * AMAX, int * INFO) const;
00183   void GEEQU(const int M, const int N, const double * A, const int LDA, double * R, double * C, double * ROWCND, double * COLCND, double * AMAX, int * INFO) const;
00184 
00186   void GERFS(const char TRANS, const int N, const int NRHS, const float * A, const int LDA, const float * AF, const int LDAF, 
00187        const int * IPIV, const float * B, const int LDB, float * X, const int LDX, 
00188        float * FERR, float * BERR, float * WORK, int * IWORK, int * INFO) const;
00190   void GERFS(const char TRANS, const int N, const int NRHS, const double * A, const int LDA, const double * AF, const int LDAF, 
00191        const int * IPIV, const double * B, const int LDB, double * X, const int LDX,
00192        double * FERR, double * BERR, double * WORK, int * IWORK, int * INFO) const;
00193 
00195   void GESVX(const char FACT, const char TRANS, const int N, const int NRHS, float * A, const int LDA, float * AF, const int LDAF, int * IPIV, 
00196        const char EQUED, float * R, float * C, float * B, const int LDB, float * X, const int LDX, float * RCOND, 
00197        float * FERR, float * BERR, float * WORK, int * IWORK, int * INFO) const;
00199   void GESVX(const char FACT, const char TRANS, const int N, const int NRHS, double * A, const int LDA, double * AF, const int LDAF, int * IPIV, 
00200        const char EQUED, double * R, double * C, double * B, const int LDB, double * X, const int LDX, double * RCOND, 
00201        double * FERR, double * BERR, double * WORK, int * IWORK, int * INFO) const;
00202 
00203 
00205   void GEHRD(const int N, const int ILO, const int IHI, float * A, const int LDA, float * TAU, float * WORK, const int LWORK, int * INFO) const;
00207   void GEHRD(const int N, const int ILO, const int IHI, double * A, const int LDA, double * TAU, double * WORK, const int LWORK, int * INFO) const;
00209 
00211 
00212 
00213   void HSEQR( const char JOB, const char COMPZ, const int N, const int ILO, const int IHI, float * H, const int LDH, float * WR, float * WI,
00214         float * Z, const int LDZ, float * WORK, const int LWORK, int * INFO) const;
00216   void HSEQR( const char JOB, const char COMPZ, const int N, const int ILO, const int IHI, double * H, const int LDH, double * WR, double * WI,
00217         double * Z, const int LDZ, double * WORK, const int LWORK, int * INFO) const;
00219 
00221 
00222 
00223   void ORGQR( const int M, const int N, const int K, float * A, const int LDA, float * TAU, float * WORK, const int LWORK, int * INFO) const;
00225   void ORGQR( const int M, const int N, const int K, double * A, const int LDA, double * TAU, double * WORK, const int LWORK, int * INFO) const;
00226 
00228   void ORGHR( const int N, const int ILO, const int IHI, float * A, const int LDA, float * TAU, float * WORK, const int LWORK, int * INFO) const;
00230   void ORGHR( const int N, const int ILO, const int IHI, double * A, const int LDA, double * TAU, double * WORK, const int LWORK, int * INFO) const;
00231 
00233   void ORMHR( const char SIDE, const char TRANS, const int M, const int N, const int ILO, const int IHI, const float * A, const int LDA, 
00234         const float * TAU, float * C,
00235         const int LDC, float * WORK, const int LWORK, int * INFO) const;
00237   void ORMHR( const char SIDE, const char TRANS, const int M, const int N, const int ILO, const int IHI, const double * A, const int LDA, 
00238         const double * TAU, double * C,
00239         const int LDC, double * WORK, const int LWORK, int * INFO) const;
00241   void LARFT( const char DIRECT, const char STOREV, const int N, const int K, double * V, const int LDV, double * TAU, double * T, const int LDT) const;
00243   void LARFT( const char DIRECT, const char STOREV, const int N, const int K, float * V, const int LDV, float * TAU, float * T, const int LDT) const;
00245 
00247 
00248 
00250 
00252   void TREVC( const char SIDE, const char HOWMNY, int * SELECT, const int N, const float * T, const int LDT, float *VL, const int LDVL,
00253         float * VR, const int LDVR, const int MM, int * M, float * WORK, int * INFO) const;
00255 
00257   void TREVC( const char SIDE, const char HOWMNY, int * SELECT, const int N, const double * T, const int LDT, double *VL, const int LDVL,
00258         double * VR, const int LDVR, const int MM, int  *M, double * WORK, int * INFO) const;
00259 
00261   void TREXC( const char COMPQ, const int N, float * T, const int LDT, float * Q, const int LDQ, int IFST, int ILST, 
00262         float * WORK, int * INFO) const;
00264   void TREXC( const char COMPQ, const int N, double * T, const int LDT, double * Q, const int LDQ, int IFST, int ILST, 
00265         double * WORK, int * INFO) const;
00267 
00269 
00270 
00272   void GESVD( const char JOBU, const char JOBVT, const int M, const int N, float * A, const int LDA, float * S, float * U,
00273         const int LDU, float * VT, const int LDVT, float * WORK, const int * LWORK, int * INFO) const;
00275   void GESVD( const char JOBU, const char JOBVT, const int M, const int N, double * A, const int LDA, double * S, double * U,
00276         const int LDU, double * VT, const int LDVT, double * WORK, const int * LWORK, int * INFO) const;
00277 
00279   void GGSVD(const char JOBU, const char JOBV, const char JOBQ, const int M, const int N, const int P, int * K, int * L,  double* A,  const int LDA,  double* B,  const int LDB,
00280                           double* ALPHA,  double* BETA,  double* U,  const int LDU, double* V, const int LDV, double* Q, const int LDQ, double* WORK, int* IWORK,
00281                           int* INFO) const;
00283   void GGSVD(const char JOBU, const char JOBV, const char JOBQ, const int M, const int N, const int P, int * K, int * L,  float* A,  const int LDA,  float* B,  const int LDB,
00284                           float* ALPHA,  float* BETA,  float* U,  const int LDU, float* V, const int LDV, float* Q, const int LDQ, float* WORK, int* IWORK,
00285                           int* INFO) const;
00287 
00289 
00290 
00291   void GEEV(const char JOBVL, const char JOBVR, const int N, double* A, const int LDA, double* WR, double* WI, 
00292       double* VL, const int LDVL, double* VR, const int LDVR, double* WORK, const int LWORK, int* INFO) const;
00294   void GEEV(const char JOBVL, const char JOBVR, const int N, float* A, const int LDA, float* WR, float* WI, 
00295       float* VL, const int LDVL, float* VR, const int LDVR, float* WORK, const int LWORK, int* INFO) const;
00296 
00298   void SPEV(const char JOBZ, const char UPLO, const int N, double* AP, double* W, double* Z, int LDZ, double* WORK, int* INFO) const;
00300   void SPEV(const char JOBZ, const char UPLO, const int N, float* AP, float* W, float* Z, int LDZ, float* WORK, int* INFO) const;
00301 
00303   void SPGV(const int ITYPE, const char JOBZ, const char UPLO, const int N, double* AP, double* BP, double* W, double* Z, const int LDZ, double* WORK, int* INFO) const;
00305   void SPGV(const int ITYPE, const char JOBZ, const char UPLO, const int N, float* AP, float* BP, float* W, float* Z, const int LDZ, float* WORK, int* INFO) const;
00306 
00308   void SYEV(const char JOBZ, const char UPLO, const int N, double* A, const int LDA, double* W, double* WORK, const int LWORK, int* INFO) const;
00310   void SYEV(const char JOBZ, const char UPLO, const int N, float* A, const int LDA, float* W, float* WORK, const int LWORK, int* INFO) const;
00311 
00313   void SYEVD(const char JOBZ, const char UPLO,  const int N,  double* A,  const int LDA,  double* W,  
00314        double* WORK,  const int LWORK,  int* IWORK, const int LIWORK, int* INFO) const;
00316   void SYEVD(const char JOBZ, const char UPLO,  const int N,  float* A,  const int LDA,  float* W,  
00317        float* WORK,  const int LWORK,  int* IWORK, const int LIWORK, int* INFO) const;
00318 
00320   void SYEVX(const char JOBZ, const char RANGE, const char UPLO,  const int N,  double* A,  const int LDA,  
00321        const double* VL,  const double* VU,  const int* IL,  const int* IU,
00322        const double ABSTOL,  int * M,  double* W,  double* Z,  const int LDZ, double* WORK, 
00323        const int LWORK, int* IWORK, int* IFAIL,
00324        int* INFO) const;
00326   void SYEVX(const char JOBZ, const char RANGE, const char UPLO,  const int N,  float* A,  const int LDA,  
00327        const float* VL,  const float* VU,  const int* IL,  const int* IU,
00328        const float ABSTOL,  int * M,  float* W,  float* Z,  const int LDZ, float* WORK, 
00329        const int LWORK, int* IWORK, int* IFAIL,
00330        int* INFO) const;
00331 
00333   void SYGV(const int ITYPE, const char JOBZ, const char UPLO, const int N, double* A, const int LDA, double* B, 
00334       const int LDB, double* W, double* WORK, const int LWORK, int* INFO) const;
00336   void SYGV(const int ITYPE, const char JOBZ, const char UPLO, const int N, float* A, const int LDA, float* B, 
00337       const int LDB, float* W, float* WORK, const int LWORK, int* INFO) const;
00338 
00340   void SYGVX(const int ITYPE, const char JOBZ, const char RANGE, const char UPLO, const int N, 
00341        double* A, const int LDA, double* B, const int LDB, const double* VL, const double* VU,
00342        const int* IL, const int* IU, const double ABSTOL, int* M, double* W, double* Z, 
00343        const int LDZ,  double* WORK,  const int LWORK,  int* IWORK,
00344        int* IFAIL, int* INFO) const;
00346   void SYGVX(const int ITYPE, const char JOBZ, const char RANGE, const char UPLO, const int N, 
00347        float* A, const int LDA, float* B, const int LDB, const float* VL, const float* VU,
00348        const int* IL, const int* IU, const float ABSTOL, int* M, float* W, float* Z, 
00349        const int LDZ,  float* WORK,  const int LWORK,  int* IWORK,
00350        int* IFAIL, int* INFO) const;
00351 
00353   void SYEVR(const char JOBZ, const char RANGE, const char UPLO,  const int N,  double* A,  const int LDA,  const double* VL,  const double* VU,  const int *IL,  const int *IU,
00354                           const double ABSTOL,  int* M,  double* W,  double* Z, const int LDZ, int* ISUPPZ, double* WORK, const int LWORK, int* IWORK,
00355                           const int LIWORK, int* INFO) const;
00357   void SYEVR(const char JOBZ, const char RANGE, const char UPLO,  const int N,  float* A,  const int LDA,  
00358        const float* VL,  const float* VU,  const int *IL,  const int *IU,
00359        const float ABSTOL,  int* M,  float* W,  float* Z, const int LDZ, int* ISUPPZ, 
00360        float* WORK, const int LWORK, int* IWORK,
00361        const int LIWORK, int* INFO) const;
00362 
00364   void GEEVX(const char BALANC, const char JOBVL, const char JOBVR, const char SENSE, const int N, double* A, const int LDA, double* WR, double* WI,  double* VL,
00365        const int LDVL,  double* VR,  const int LDVR,  int* ILO,  int* IHI,  double* SCALE, double* ABNRM, double* RCONDE,
00366        double* RCONDV, double* WORK, const int LWORK, int* IWORK, int* INFO) const;
00368   void GEEVX(const char BALANC, const char JOBVL, const char JOBVR, const char SENSE, const int N, float* A, const int LDA, float* WR, float* WI,  float* VL,
00369        const int LDVL,  float* VR,  const int LDVR,  int* ILO,  int* IHI,  float* SCALE, float* ABNRM, float* RCONDE,
00370        float* RCONDV, float* WORK, const int LWORK, int* IWORK, int* INFO) const;
00371 
00373   void GESDD(const char JOBZ, const int M, const int N, double* A, const int LDA,  double* S,  double* U,  const int LDU,  double* VT,  const int LDVT,  double* WORK,
00374        const int LWORK, int* IWORK, int* INFO) const;
00376   void GESDD(const char JOBZ, const int M, const int N, float* A, const int LDA,  float* S,  float* U,  const int LDU,  float* VT,  const int LDVT,  float* WORK,
00377        const int LWORK, int* IWORK, int* INFO) const;
00379 
00380   void GGEV(const char JOBVL,  const char JOBVR,  const int N,  double* A,  const int LDA,  double* B, const int LDB, double* ALPHAR, double* ALPHAI,
00381       double* BETA, double* VL, const int LDVL, double* VR, const int LDVR, double* WORK, const int LWORK, int* INFO) const;
00383   void GGEV(const char JOBVL,  const char JOBVR,  const int N,  float* A,  const int LDA,  float* B, const int LDB, float* ALPHAR, float* ALPHAI,
00384       float* BETA, float* VL, const int LDVL, float* VR, const int LDVR, float* WORK, const int LWORK, int* INFO) const;
00385 
00387 
00389 
00390 
00391   void GGLSE(const int M, const int N, const int P, double* A, const int LDA, double* B, const int LDB, 
00392        double* C, double* D, double* X, double* WORK, const int LWORK, int* INFO) const;
00394   void GGLSE(const int M, const int N, const int P, float* A, const int LDA, float* B, const int LDB, 
00395        float* C, float* D, float* X, float* WORK, const int LWORK, int* INFO) const;
00397 
00399 
00400 
00401   void LAMCH ( const char CMACH, float & T) const;
00403   void LAMCH ( const char CMACH, double & T) const;
00405 
00407 
00409 
00410 
00411   void TRTRS(const char UPLO, const char TRANS, const char DIAG, const int N, const int NRHS, const float *A,
00412                          const int LDA, float *B, const int LDB, int *INFO) const; 
00414   void TRTRS(const char UPLO, const char TRANS, const char DIAG, const int N, const int NRHS, const double *A,
00415                          const int LDA, double *B, const int LDB, int *INFO) const; 
00416 };
00417 
00418 // Epetra_LAPACK constructor
00419 inline Epetra_LAPACK::Epetra_LAPACK(void){}
00420 // Epetra_LAPACK constructor
00421 inline Epetra_LAPACK::Epetra_LAPACK(const Epetra_LAPACK& LAPACK){(void)LAPACK;}
00422 // Epetra_LAPACK destructor
00423 inline Epetra_LAPACK::~Epetra_LAPACK(){}
00424 
00425 #endif /* EPETRA_LAPACK_H */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines