Anasazi Version of the Day
Loading...
Searching...
No Matches
ARPACKm1.h
1// @HEADER
2// *****************************************************************************
3// Anasazi: Block Eigensolvers Package
4//
5// Copyright 2004 NTESS and the Anasazi contributors.
6// SPDX-License-Identifier: BSD-3-Clause
7// *****************************************************************************
8// @HEADER
9
10// This software is a result of the research described in the report
11//
12// "A comparison of algorithms for modal analysis in the absence
13// of a sparse direct method", P. Arbenz, R. Lehoucq, and U. Hetmaniuk,
14// Sandia National Laboratories, Technical report SAND2003-1028J.
15//
16// It is based on the Epetra, AztecOO, and ML packages defined in the Trilinos
17// framework ( http://trilinos.org/ ).
18
19#ifndef ARPACK_MODE1_H
20#define ARPACK_MODE1_H
21
22#include "Epetra_ConfigDefs.h"
23
24#include "Epetra_Comm.h"
25#include "Epetra_Operator.h"
26#include "Epetra_Time.h"
27
28#ifdef EPETRA_MPI
29#include "Epetra_MpiComm.h"
30#endif
31
32#include "FortranRoutines.h"
33#include "ModalAnalysisSolver.h"
34#include "MyMemory.h"
35#include "CheckingTools.h"
36
37class ARPACKm1 : public ModalAnalysisSolver {
38
39 private:
40
41 const CheckingTools myVerify;
42 const FortranRoutines callFortran;
43
44 const Epetra_Comm &MyComm;
45 const Epetra_Operator *K;
46 const Epetra_Time MyWatch;
47
48 double tolEigenSolve;
49 int maxIterEigenSolve;
50
51 char *which;
52
53 int verbose;
54
55 double memRequested;
56 double highMem;
57
58 int orthoOp;
59 int outerIter;
60 int stifOp;
61
62 double timeOuterLoop;
63 double timePostProce;
64 double timeStifOp;
65
66 // Don't define these functions
67 ARPACKm1(const ARPACKm1 &ref);
68 ARPACKm1& operator=(const ARPACKm1 &ref);
69
70 public:
71
72 ARPACKm1(const Epetra_Comm &_Comm, const Epetra_Operator *KK,
73 double _tol = 1.0e-08, int _maxIter = 100, int _verb = 0);
74
75 ARPACKm1(const Epetra_Comm &_Comm, const Epetra_Operator *KK, char *_which,
76 double _tol = 1.0e-08, int _maxIter = 100, int _verb = 0);
77
78 ~ARPACKm1() { }
79
80 int solve(int numEigen, Epetra_MultiVector &Q, double *lambda);
81
82 int reSolve(int numEigen, Epetra_MultiVector &Q, double *lambda, int startingEV = 0);
83
84 int minimumSpaceDimension(int nev) const { return nev+1; }
85
86 void initializeCounters();
87
88 void algorithmInfo() const;
89 void memoryInfo() const;
90 void operationInfo() const;
91 void timeInfo() const;
92
93};
94
95#endif