1 #include "RBGen_ISVDUDV.h"
7 void ISVDUDV::expand(
const int lup)
19 int info = (*B_).Scale(0.0);
21 "RBGen::ISVDUDV::expand(): error calling Epetra_SerialDenseMatrix::scale()");
22 for (
int i=0; i<curRank_; ++i) {
23 (*B_)(i,i) = sigma_[i];
38 newRank = ortho_->projectAndNormalize(*U2,Teuchos::tuple(U1),Teuchos::tuple(Cteuchos),Zteuchos);
41 newRank = ortho_->normalize(*U2,Zteuchos);
44 "RBGen::ISVDUDV::incStep(): Couldn't recover full rank basis.");
45 Cteuchos = Teuchos::null;
46 Zteuchos = Teuchos::null;
59 for (
int j=curRank_; j<curRank_+lup; j++) {
60 for (
int i=0; i<numProc_+lup; i++) {
70 for (
int j=0; j<curRank_; j++) {
71 for (
int i=numProc_; i<numProc_+lup; i++) {
81 for (
int j=0; j<lup; j++) {
82 (*V_)[curRank_+j][numProc_+j] = 1.0;
105 int info = newwU->Multiply(
'N',
'N',1.0,*fullU,Uh1,0.0);
107 fullU = Teuchos::null;
110 newU = Teuchos::null;
111 newwU = Teuchos::null;
115 double *V_A, *workV_A;
116 int V_LDA, workV_LDA;
117 info = V_->ExtractView(&V_A,&V_LDA);
119 "RBGen::ISVDUDV::shrink(): Error calling Epetra_MultiVector::ExtractView() on V_.");
120 info = workV_->ExtractView(&workV_A,&workV_LDA);
122 "RBGen::ISVDUDV::shrink(): Error calling Epetra_MultiVector::ExtractView() on workV_.");
127 info = newwV->Multiply(
'N',
'N',1.0,*fullV,Vh1,0.0);
129 fullV = Teuchos::null;
133 newV = Teuchos::null;
134 newwV = Teuchos::null;
137 for (
int i=0; i<curRank_-down; i++) {
141 curRank_ = curRank_-down;
ISVDUDV()
Default constructor.
void Initialize(const Teuchos::RCP< Teuchos::ParameterList > ¶ms, const Teuchos::RCP< const Epetra_MultiVector > &init, const Teuchos::RCP< RBGen::FileIOHandler< Epetra_Operator > > &fileio=Teuchos::null)
Initialize the method with the given parameter list and snapshot set.
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)