// check setting elements in a petsc matrix using
-// petsc_wrappers::SparseMatrix::set()
+// PETScWrappers::SparseMatrix::set()
#include "../tests.h"
#include <lac/petsc_sparse_matrix.h>
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries
for (unsigned int i=0; i<m.m(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
// check setting elements in a petsc matrix using
-// petsc_wrappers::SparseMatrix::add()
+// PETScWrappers::SparseMatrix::add()
#include "../tests.h"
#include <lac/petsc_sparse_matrix.h>
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries
for (unsigned int i=0; i<m.m(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries
for (unsigned int i=0; i<m.m(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries
for (unsigned int i=0; i<m.m(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries
for (unsigned int i=0; i<m.m(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
Assert (m.m() == 5, ExcInternalError());
Assert (m.n() == 5, ExcInternalError());
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
// check querying the number of nonzero elements in
-// petsc_wrappers::SparseMatrix
+// PETScWrappers::SparseMatrix
#include "../tests.h"
#include <lac/petsc_sparse_matrix.h>
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries. count how many
// entries we have
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
//---------------------------- petsc_06.cc ---------------------------
-// check petsc_wrappers::SparseMatrix::l1_norm
+// check PETScWrappers::SparseMatrix::l1_norm
#include "../tests.h"
#include <lac/petsc_sparse_matrix.h>
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries. count how many
// entries we have
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
//---------------------------- petsc_07.cc ---------------------------
-// check petsc_wrappers::SparseMatrix::linfty_norm
+// check PETScWrappers::SparseMatrix::linfty_norm
#include "../tests.h"
#include <lac/petsc_sparse_matrix.h>
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries. count how many
// entries we have
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
//---------------------------- petsc_08.cc ---------------------------
-// check petsc_wrappers::SparseMatrix::frobenius_norm
+// check PETScWrappers::SparseMatrix::frobenius_norm
#include "../tests.h"
#include <lac/petsc_sparse_matrix.h>
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries. count how many
// entries we have
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries
for (unsigned int i=0; i<m.m(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
#include <iostream>
-void test (petsc_wrappers::SparseMatrix &m)
+void test (PETScWrappers::SparseMatrix &m)
{
// first set a few entries
for (unsigned int i=0; i<m.m(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::SparseMatrix m (5,5,3);
+ PETScWrappers::SparseMatrix m (5,5,3);
test (m);
}
PetscFinalize();
#include <iostream>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set only certain elements of the vector
for (unsigned int i=0; i<v.size(); i+=1+i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set only certain elements of the
// vector. have a bit pattern of where we
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set only certain elements of the
// vector. have a bit pattern of where we
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set only certain elements of the
// vector. have a bit pattern of where we
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set only certain elements of the
// vector. have a bit pattern of where we
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set only certain elements of the
// vector. have a bit pattern of where we
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some elements of the vector
double norm = 0;
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some elements of the vector
double norm = 0;
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some elements of the vector
double norm = 0;
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set only certain elements of the
// vector. have a bit pattern of where we
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set only certain elements of the
// vector. have a bit pattern of where we
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
// set only certain elements of each
// vector, but disjoint sets of elements
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
// set only certain elements of each
// vector, and record the expected scalar
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some entries of the vector
for (unsigned int i=0; i<v.size(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some entries of the vector
for (unsigned int i=0; i<v.size(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some entries of the vector
for (unsigned int i=0; i<v.size(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some entries of the vector
for (unsigned int i=0; i<v.size(); ++i)
v.compress ();
// then copy it
- petsc_wrappers::Vector w (v.size());
+ PETScWrappers::Vector w (v.size());
w = v;
// make sure they're equal
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some entries of the vector
for (unsigned int i=0; i<v.size(); ++i)
// then copy it to a vector of different
// size
- petsc_wrappers::Vector w (1);
+ PETScWrappers::Vector w (1);
w = v;
// make sure they're equal
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
v.reinit (13, true);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some entries of the vector
for (unsigned int i=0; i<v.size(); ++i)
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some elements of the vector
double norm = 0;
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some elements of the vector
double sum = 0;
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some elements of the vector
double sum = 0;
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
// set some elements of the vector
double sum = 0;
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
// set only certain elements of each
// vector
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
// set only certain elements of each
// vector
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
for (unsigned int i=0; i<v.size(); ++i)
v(i) = i;
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w,
- petsc_wrappers::Vector &x)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w,
+ PETScWrappers::Vector &x)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
- petsc_wrappers::Vector x (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
+ PETScWrappers::Vector x (100);
test (v,w,x);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w,
- petsc_wrappers::Vector &x)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w,
+ PETScWrappers::Vector &x)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
- petsc_wrappers::Vector x (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
+ PETScWrappers::Vector x (100);
test (v,w,x);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w,
- petsc_wrappers::Vector &x,
- petsc_wrappers::Vector &y)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w,
+ PETScWrappers::Vector &x,
+ PETScWrappers::Vector &y)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
- petsc_wrappers::Vector x (100);
- petsc_wrappers::Vector y (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
+ PETScWrappers::Vector x (100);
+ PETScWrappers::Vector y (100);
test (v,w,x,y);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w,
- petsc_wrappers::Vector &x)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w,
+ PETScWrappers::Vector &x)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
- petsc_wrappers::Vector x (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
+ PETScWrappers::Vector x (100);
test (v,w,x);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w,
- petsc_wrappers::Vector &x)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w,
+ PETScWrappers::Vector &x)
{
for (unsigned int i=0; i<v.size(); ++i)
{
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
- petsc_wrappers::Vector x (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
+ PETScWrappers::Vector x (100);
test (v,w,x);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
Vector<PetscScalar> w (v.size());
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
Vector<double> w (v.size());
Vector<float> x (v.size());
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize();
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- GrowingVectorMemory<petsc_wrappers::Vector> mem;
- SolverCG<petsc_wrappers::Vector> solver(control,mem);
+ GrowingVectorMemory<PETScWrappers::Vector> mem;
+ SolverCG<PETScWrappers::Vector> solver(control,mem);
PreconditionIdentity preconditioner;
check_solve (solver, A,u,f, preconditioner);
}
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- GrowingVectorMemory<petsc_wrappers::Vector> mem;
- SolverBicgstab<petsc_wrappers::Vector> solver(control,mem);
+ GrowingVectorMemory<PETScWrappers::Vector> mem;
+ SolverBicgstab<PETScWrappers::Vector> solver(control,mem);
PreconditionIdentity preconditioner;
check_solve (solver, A,u,f, preconditioner);
}
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- GrowingVectorMemory<petsc_wrappers::Vector> mem;
- SolverGMRES<petsc_wrappers::Vector> solver(control,mem);
+ GrowingVectorMemory<PETScWrappers::Vector> mem;
+ SolverGMRES<PETScWrappers::Vector> solver(control,mem);
PreconditionIdentity preconditioner;
check_solve (solver, A,u,f, preconditioner);
}
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- GrowingVectorMemory<petsc_wrappers::Vector> mem;
- SolverMinRes<petsc_wrappers::Vector> solver(control,mem);
+ GrowingVectorMemory<PETScWrappers::Vector> mem;
+ SolverMinRes<PETScWrappers::Vector> solver(control,mem);
PreconditionIdentity preconditioner;
check_solve (solver, A,u,f, preconditioner);
}
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- GrowingVectorMemory<petsc_wrappers::Vector> mem;
- SolverQMRS<petsc_wrappers::Vector> solver(control,mem);
+ GrowingVectorMemory<PETScWrappers::Vector> mem;
+ SolverQMRS<PETScWrappers::Vector> solver(control,mem);
PreconditionIdentity preconditioner;
check_solve (solver, A,u,f, preconditioner);
}
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- GrowingVectorMemory<petsc_wrappers::Vector> mem;
- SolverRichardson<petsc_wrappers::Vector> solver(control,mem);
+ GrowingVectorMemory<PETScWrappers::Vector> mem;
+ SolverRichardson<PETScWrappers::Vector> solver(control,mem);
PreconditionIdentity preconditioner;
check_solve (solver, A,u,f, preconditioner);
}
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::FullMatrix m(v.size(),v.size());
+ PETScWrappers::FullMatrix m(v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::FullMatrix m(v.size(),v.size());
+ PETScWrappers::FullMatrix m(v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::FullMatrix m(v.size(),v.size());
+ PETScWrappers::FullMatrix m(v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::FullMatrix m(v.size(),v.size());
+ PETScWrappers::FullMatrix m(v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::FullMatrix m(v.size(),v.size());
+ PETScWrappers::FullMatrix m(v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
- petsc_wrappers::FullMatrix m(v.size(),v.size());
+ PETScWrappers::FullMatrix m(v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w,
- petsc_wrappers::Vector &x)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w,
+ PETScWrappers::Vector &x)
{
- petsc_wrappers::FullMatrix m(v.size(),v.size());
+ PETScWrappers::FullMatrix m(v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
- petsc_wrappers::Vector x (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
+ PETScWrappers::Vector x (100);
test (v,w,x);
}
PetscFinalize ();
catch (std::exception& e)
{
deallog << e.what() << std::endl;
- abort ();
+ // it needs to be expected for the
+ // richardson solver that we end up
+ // here, so don't abort
}
deallog << "Solver stopped after " << solver.control().last_step()
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverRichardson solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverRichardson solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
catch (std::exception& e)
{
deallog << e.what() << std::endl;
- abort ();
+ // just like for Richardson: we end up
+ // here normally for this solver
}
deallog << "Solver stopped after " << solver.control().last_step()
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverChebychev solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverChebychev solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverCG solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverCG solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverBiCG solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverBiCG solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverGMRES solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverGMRES solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverBicgstab solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverBicgstab solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverCGS solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverCGS solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverTFQMR solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverTFQMR solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverTCQMR solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverTCQMR solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverCR solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverCR solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
catch (std::exception& e)
{
deallog << e.what() << std::endl;
- abort ();
+ // just like for Richardson: expect to
+ // get here, don't abort the program
}
deallog << "Solver stopped after " << solver.control().last_step()
// Make matrix
FDMatrix testproblem(size, size);
- petsc_wrappers::SparseMatrix A(dim, dim, 5);
+ PETScWrappers::SparseMatrix A(dim, dim, 5);
testproblem.five_point(A);
- petsc_wrappers::Vector f(dim);
- petsc_wrappers::Vector u(dim);
+ PETScWrappers::Vector f(dim);
+ PETScWrappers::Vector u(dim);
f = 1.;
A.compress ();
f.compress ();
u.compress ();
- petsc_wrappers::SolverLSQR solver(control);
- petsc_wrappers::PreconditionJacobi preconditioner(A);
+ PETScWrappers::SolverLSQR solver(control);
+ PETScWrappers::PreconditionJacobi preconditioner(A);
check_solve (solver, A,u,f, preconditioner);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::SparseMatrix m(v.size(),v.size(),v.size());
+ PETScWrappers::SparseMatrix m(v.size(),v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::SparseMatrix m(v.size(),v.size(),v.size());
+ PETScWrappers::SparseMatrix m(v.size(),v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::SparseMatrix m(v.size(),v.size(),v.size());
+ PETScWrappers::SparseMatrix m(v.size(),v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::SparseMatrix m(v.size(),v.size(),v.size());
+ PETScWrappers::SparseMatrix m(v.size(),v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
- petsc_wrappers::SparseMatrix m(v.size(),v.size(),v.size());
+ PETScWrappers::SparseMatrix m(v.size(),v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v)
+void test (PETScWrappers::Vector &v)
{
- petsc_wrappers::SparseMatrix m(v.size(),v.size(),v.size());
+ PETScWrappers::SparseMatrix m(v.size(),v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
+ PETScWrappers::Vector v (100);
test (v);
}
PetscFinalize ();
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w,
- petsc_wrappers::Vector &x)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w,
+ PETScWrappers::Vector &x)
{
- petsc_wrappers::SparseMatrix m(v.size(),v.size(),v.size());
+ PETScWrappers::SparseMatrix m(v.size(),v.size(),v.size());
for (unsigned int i=0; i<m.m(); ++i)
for (unsigned int j=0; j<m.m(); ++j)
m.set (i,j, i+2*j);
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
- petsc_wrappers::Vector x (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
+ PETScWrappers::Vector x (100);
test (v,w,x);
}
PetscFinalize ();
//---------------------------- petsc_vector_equality_1.cc ---------------------------
-// check petsc_wrappers::Vector::operator==(petsc_wrappers::Vector) for vectors that are not
+// check PETScWrappers::Vector::operator==(PETScWrappers::Vector) for vectors that are not
// equal
#include "../tests.h"
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
// set only certain elements of each
// vector
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
//---------------------------- petsc_vector_equality_2.cc ---------------------------
-// check petsc_wrappers::Vector::operator==(petsc_wrappers::Vector) for vectors that are
+// check PETScWrappers::Vector::operator==(PETScWrappers::Vector) for vectors that are
// equal
#include "../tests.h"
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
// set only certain elements of each
// vector
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
//---------------------------- petsc_vector_equality_3.cc ---------------------------
-// check petsc_wrappers::Vector::operator!=(petsc_wrappers::Vector) for vectors that are not
+// check PETScWrappers::Vector::operator!=(PETScWrappers::Vector) for vectors that are not
// equal
#include "../tests.h"
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
// set only certain elements of each
// vector
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();
//---------------------------- petsc_vector_equality_4.cc ---------------------------
-// check petsc_wrappers::Vector::operator!=(petsc_wrappers::Vector) for vectors that are
+// check PETScWrappers::Vector::operator!=(PETScWrappers::Vector) for vectors that are
// equal
#include "../tests.h"
#include <vector>
-void test (petsc_wrappers::Vector &v,
- petsc_wrappers::Vector &w)
+void test (PETScWrappers::Vector &v,
+ PETScWrappers::Vector &w)
{
// set only certain elements of each
// vector
{
PetscInitialize(&argc,&argv,0,0);
{
- petsc_wrappers::Vector v (100);
- petsc_wrappers::Vector w (100);
+ PETScWrappers::Vector v (100);
+ PETScWrappers::Vector w (100);
test (v,w);
}
PetscFinalize();