Epetra to Thyra Operator/Vector Adapter Code

Collaboration diagram for Epetra to Thyra Operator/Vector Adapter Code:


 Collection of functions for wrapping and unwrapping Epetra objects
 Epetra to Thyra Operator/Vector Adapter Support Code
 Epetra_Operator extraction utility functions


class  Thyra::EpetraLinearOp
 Concrete LinearOpBase adapter subclass for Epetra_Operator object. More...
class  Thyra::EpetraLinearOpBase
 Abstract base class for all LinearOpBase objects that can return an Epetra_Operator view of themselves and details about how to apply the view. More...

Detailed Description

The following functions and classes are used to create Thyra objects which wrap (or adapt) Epetra objects:

The above adapter code is based directly from the general Thyra_Op_Vec_adapters_MPI_support_grp. Therefore these Epetra adapted objects are automatically compatible with any other such MPI-based SPMD adapter subclasses.

There is, however, one issue that requires a little care and that is using arbitrary Thyra::VectorBase and Thyra::MultiVectorBase objects with the vector and multi-vector versions of Thyra::EpetraLinearOp::apply(). The issue is that the underlying Epetra_Operator::Apply() function can only accept Epetra_MultiVector objects. The utility functions Thyra::get_Epetra_MultiVector() return an Epetra_MultiVector view of any Thyra::MultiVectorBase object with a compatible range space. Studying the implementations of these utility functions will show you how simple it is to provide for this type of interoperabiity. This type of interoperabiity machinary should also be used for other types of concrete adapter subclasses.

Other types of code will need to extract an Epetra_Vector view of a Thyra::VectorBase object. For this purpose the Thyra::get_Epetra_Vector() functions are provided.

The utility functions Thyra::get_Epetra_Operator() are also provided that encapsulate the extraction of an "adapted" Epetra_Operator object out of a Thyra::EpetraLinearOp object through its Thyra::LinearOpBase base interface. This is a common type of activity in object-oriented programming.


Generated on Wed May 12 21:27:23 2010 for Epetra to Thyra Adapter Software by  doxygen 1.4.7