Playa::EpetraVector Class Reference

#include <PlayaEpetraVector.hpp>

Inheritance diagram for Playa::EpetraVector:

Playa::SingleChunkVector< double > Playa::LoadableVector< double > Playa::Printable Playa::VectorBase< double >

List of all members.

Public Member Functions

 EpetraVector (const VectorSpace< double > &vs)
 EpetraVector (const VectorSpace< double > &vs, const RCP< Epetra_Vector > &vec)
const RCP< Epetra_Vector > & epetraVec () const
RCP< Epetra_Vector > & epetraVec ()
virtual void update (const double &alpha, const VectorBase< double > *other, const double &gamma)
virtual void update (const double &alpha, const VectorBase< double > *x, const double &beta, const VectorBase< double > *y, const double &gamma)
virtual double dot (const VectorBase< double > *other) const
virtual double norm2 () const
VectorBase interface


RCP< const VectorSpaceBase
< double > > 
space () const
IndexableVector interface


virtual const double & operator[] (int globalIndex) const
virtual double & operator[] (int globalIndex)
LoadableVector interface


void setElement (int globalIndex, const double &value)
void addToElement (int globalIndex, const double &value)
void setElements (int numElems, const int *globalIndices, const double *values)
void addToElements (int numElems, const int *globalIndices, const double *values)
void finalizeAssembly ()
AccessibleVector interface


const double & getElement (int globalIndex) const
void getElements (const int *globalIndices, int numElems, Teuchos::Array< double > &elems) const
Printable interface


void print (std::ostream &os) const

Static Public Member Functions

static const Epetra_Vector & getConcrete (const Playa::Vector< double > &tsfVec)
static Epetra_Vector & getConcrete (Playa::Vector< double > &tsfVec)
static Epetra_Vector * getConcretePtr (Playa::Vector< double > &tsfVec)

Protected Member Functions

Single chunk data access interface


virtual const double * dataPtr () const
virtual double * dataPtr ()
virtual int chunkSize () const


Detailed Description

Playa::VectorBase wrapper for Epetra_Vector

Definition at line 24 of file PlayaEpetraVector.hpp.


Constructor & Destructor Documentation

EpetraVector::EpetraVector ( const VectorSpace< double > &  vs  ) 

Construct with an Epetra vector space.

Definition at line 17 of file PlayaEpetraVector.cpp.

EpetraVector::EpetraVector ( const VectorSpace< double > &  vs,
const RCP< Epetra_Vector > &  vec 
)

Construct with an Epetra vector space and an existing Epetra vector.

Definition at line 35 of file PlayaEpetraVector.cpp.


Member Function Documentation

RCP< const VectorSpaceBase<double> > Playa::EpetraVector::space (  )  const [inline, virtual]

Return the space in which this vector lives

Implements Playa::VectorBase< double >.

Definition at line 43 of file PlayaEpetraVector.hpp.

virtual const double& Playa::EpetraVector::operator[] ( int  globalIndex  )  const [inline, virtual]

read the element at the given global index

Reimplemented from Playa::SingleChunkVector< double >.

Definition at line 49 of file PlayaEpetraVector.hpp.

double & EpetraVector::operator[] ( int  globalIndex  )  [virtual]

writable access to the element at the given global index

Reimplemented from Playa::SingleChunkVector< double >.

Definition at line 53 of file PlayaEpetraVector.cpp.

void EpetraVector::setElement ( int  globalIndex,
const double &  value 
) [virtual]

set a single element

Implements Playa::LoadableVector< double >.

Definition at line 59 of file PlayaEpetraVector.cpp.

void EpetraVector::addToElement ( int  globalIndex,
const double &  value 
) [virtual]

add to a single element

Implements Playa::LoadableVector< double >.

Definition at line 66 of file PlayaEpetraVector.cpp.

void EpetraVector::setElements ( int  numElems,
const int *  globalIndices,
const double *  values 
) [virtual]

set a group of elements

Reimplemented from Playa::LoadableVector< double >.

Definition at line 93 of file PlayaEpetraVector.cpp.

void EpetraVector::addToElements ( int  numElems,
const int *  globalIndices,
const double *  values 
) [virtual]

add to a group of elements

Reimplemented from Playa::LoadableVector< double >.

Definition at line 102 of file PlayaEpetraVector.cpp.

void EpetraVector::finalizeAssembly (  )  [virtual]

Reimplemented from Playa::LoadableVector< double >.

Definition at line 111 of file PlayaEpetraVector.cpp.

const double & EpetraVector::getElement ( int  globalIndex  )  const

Definition at line 74 of file PlayaEpetraVector.cpp.

void EpetraVector::getElements ( const int *  globalIndices,
int  numElems,
Teuchos::Array< double > &  elems 
) const

Definition at line 80 of file PlayaEpetraVector.cpp.

void EpetraVector::print ( std::ostream &  os  )  const [virtual]

Print to a stream

Implements Playa::Printable.

Definition at line 118 of file PlayaEpetraVector.cpp.

const RCP<Epetra_Vector>& Playa::EpetraVector::epetraVec (  )  const [inline]

Definition at line 95 of file PlayaEpetraVector.hpp.

RCP<Epetra_Vector>& Playa::EpetraVector::epetraVec (  )  [inline]

Definition at line 99 of file PlayaEpetraVector.hpp.

const Epetra_Vector & EpetraVector::getConcrete ( const Playa::Vector< double > &  tsfVec  )  [static]

Get a read-only Epetra_Vector

Definition at line 124 of file PlayaEpetraVector.cpp.

Epetra_Vector & EpetraVector::getConcrete ( Playa::Vector< double > &  tsfVec  )  [static]

Get a read-write Epetra_Vector

Definition at line 134 of file PlayaEpetraVector.cpp.

Epetra_Vector * EpetraVector::getConcretePtr ( Playa::Vector< double > &  tsfVec  )  [static]

Get a read-write Epetra_Vector pointer

Definition at line 145 of file PlayaEpetraVector.cpp.

void EpetraVector::update ( const double &  alpha,
const VectorBase< double > *  other,
const double &  gamma 
) [virtual]

Reimplemented from Playa::SingleChunkVector< double >.

Definition at line 156 of file PlayaEpetraVector.cpp.

void EpetraVector::update ( const double &  alpha,
const VectorBase< double > *  x,
const double &  beta,
const VectorBase< double > *  y,
const double &  gamma 
) [virtual]

Reimplemented from Playa::SingleChunkVector< double >.

Definition at line 166 of file PlayaEpetraVector.cpp.

double EpetraVector::dot ( const VectorBase< double > *  other  )  const [virtual]

Reimplemented from Playa::SingleChunkVector< double >.

Definition at line 181 of file PlayaEpetraVector.cpp.

double EpetraVector::norm2 (  )  const [virtual]

Reimplemented from Playa::SingleChunkVector< double >.

Definition at line 191 of file PlayaEpetraVector.cpp.

virtual const double* Playa::EpetraVector::dataPtr (  )  const [inline, protected, virtual]

Implements Playa::SingleChunkVector< double >.

Definition at line 130 of file PlayaEpetraVector.hpp.

virtual double* Playa::EpetraVector::dataPtr (  )  [inline, protected, virtual]

Implements Playa::SingleChunkVector< double >.

Definition at line 132 of file PlayaEpetraVector.hpp.

virtual int Playa::EpetraVector::chunkSize (  )  const [inline, protected, virtual]

Size of the (single) chunk of data values

Implements Playa::SingleChunkVector< double >.

Definition at line 135 of file PlayaEpetraVector.hpp.


The documentation for this class was generated from the following files:

doxygen