OperatorTest Class Reference

#include <operatortest.h>

List of all members.

Public Member Functions

 OperatorTest (const Epetra_Operator *op)
void set_operator (const Epetra_Operator *op, bool use_inverse=false)
bool is_symmetric ()
bool is_linear ()
bool is_non_destructive ()
void dump_stats (std::ostream &ostr, std::string operator_name)

Protected Member Functions

int apply (Epetra_MultiVector &X, Epetra_MultiVector &Y)

Protected Attributes

const Epetra_Operator * op_
int nrows_
int ncols_
int verbose_
bool use_inverse_

Static Protected Attributes

static const double symmetric_tol_ = 1e-13
static const double linear_tol_ = 1e-11


Detailed Description

Class for testing various properties and the correct implementation of Epetra_Operators

Definition at line 24 of file operatortest.h.


Constructor & Destructor Documentation

OperatorTest::OperatorTest ( const Epetra_Operator *  op  ) 

Definition at line 34 of file operatortest.cpp.

References ncols_, nrows_, and verbose_.


Member Function Documentation

int OperatorTest::apply ( Epetra_MultiVector &  X,
Epetra_MultiVector &  Y 
) [protected]

Call Apply or ApplyInverse method of operator according to _use_inverse member.

Definition at line 154 of file operatortest.cpp.

References op_, and use_inverse_.

Referenced by is_linear(), is_non_destructive(), and is_symmetric().

void OperatorTest::dump_stats ( std::ostream &  ostr,
std::string  operator_name 
)

Run all available tests and dump results to ostream.

Definition at line 50 of file operatortest.cpp.

References is_linear(), is_non_destructive(), is_symmetric(), and op_.

Referenced by FemaxxDriver::calculate_eigenfields().

Here is the call graph for this function:

bool OperatorTest::is_linear (  ) 

Test whether the operator is linear.

Definition at line 106 of file operatortest.cpp.

References apply(), EPETRA_CHK, linear_tol_, op_, verbose_, x, and y.

Referenced by dump_stats().

Here is the call graph for this function:

bool OperatorTest::is_non_destructive (  ) 

Test whether operator leaves input vector intact

Definition at line 137 of file operatortest.cpp.

References apply(), EPETRA_CHK, op_, verbose_, x, and y.

Referenced by dump_stats().

Here is the call graph for this function:

bool OperatorTest::is_symmetric (  ) 

Test whether the operator is symmetric.

Definition at line 77 of file operatortest.cpp.

References apply(), EPETRA_CHK, ncols_, nrows_, op_, symmetric_tol_, verbose_, x, and y.

Referenced by dump_stats().

Here is the call graph for this function:

void OperatorTest::set_operator ( const Epetra_Operator *  op,
bool  use_inverse = false 
)

Set new operator for following tests. Specify whether Apply or ApplyInverse will be used for the tests.

Definition at line 43 of file operatortest.cpp.

References ncols_, nrows_, op_, and use_inverse_.

Referenced by FemaxxDriver::calculate_eigenfields().


Member Data Documentation

const double OperatorTest::linear_tol_ = 1e-11 [static, protected]

Definition at line 54 of file operatortest.h.

Referenced by is_linear().

int OperatorTest::ncols_ [protected]

Definition at line 50 of file operatortest.h.

Referenced by is_symmetric(), OperatorTest(), and set_operator().

int OperatorTest::nrows_ [protected]

Definition at line 49 of file operatortest.h.

Referenced by is_symmetric(), OperatorTest(), and set_operator().

const Epetra_Operator* OperatorTest::op_ [protected]

Definition at line 48 of file operatortest.h.

Referenced by apply(), dump_stats(), is_linear(), is_non_destructive(), is_symmetric(), and set_operator().

const double OperatorTest::symmetric_tol_ = 1e-13 [static, protected]

Definition at line 53 of file operatortest.h.

Referenced by is_symmetric().

bool OperatorTest::use_inverse_ [protected]

Definition at line 52 of file operatortest.h.

Referenced by apply(), and set_operator().

int OperatorTest::verbose_ [protected]

Definition at line 51 of file operatortest.h.

Referenced by is_linear(), is_non_destructive(), is_symmetric(), and OperatorTest().


The documentation for this class was generated from the following files:
Generated on Fri Oct 26 13:35:17 2007 for FEMAXX (Finite Element Maxwell Eigensolver) by  doxygen 1.4.7