#include <source/solvers/vectors/Sundials_SAMRAIVector.h>
Inheritance diagram for SAMRAI::solv::Sundials_SAMRAIVector< DIM >:
Public Member Functions | |
void | printVector () const |
Static Public Member Functions | |
static SundialsAbstractVector * | createSundialsVector (tbox::Pointer< SAMRAIVectorReal< DIM, double > > samrai_vec) |
static void | destroySundialsVector (SundialsAbstractVector *sundials_vec) |
static tbox::Pointer< SAMRAIVectorReal< DIM, double > > | getSAMRAIVector (SundialsAbstractVector *sundials_vec) |
static tbox::Pointer< SAMRAIVectorReal< DIM, double > > | getSAMRAIVector (N_Vector sundials_vec) |
Protected Member Functions | |
Sundials_SAMRAIVector (tbox::Pointer< SAMRAIVectorReal< DIM, double > > samrai_vector) | |
virtual | ~Sundials_SAMRAIVector () |
C++
interface for Sundials vectors. It also maintains a pointer to a SAMRAI vector object. A SAMRAI vector is defined as a collection of patch data components living on some subset of levels in a structured AMR mesh hierarchy.Observe that there are only three public member functions in this class They are used to create and destroy Sundials vector objects (i.e., "N_Vector"s), and to obtain the SAMRAI vector associated with the Sundials vector. In particular, note that the constructor and destructor of this class are protected members. The construction and destruction of instances of this class may occur only through the static member functions that create and destroy Sundials vector objects.
Finally, we remark that this class provides vectors of type double
, which is the default for Sundials.
SAMRAI::solv::Sundials_SAMRAIVector< DIM >::Sundials_SAMRAIVector | ( | tbox::Pointer< SAMRAIVectorReal< DIM, double > > | samrai_vector | ) | [protected] |
SAMRAI::solv::Sundials_SAMRAIVector< DIM >::~Sundials_SAMRAIVector | ( | ) | [protected, virtual] |
SundialsAbstractVector * SAMRAI::solv::Sundials_SAMRAIVector< DIM >::createSundialsVector | ( | tbox::Pointer< SAMRAIVectorReal< DIM, double > > | samrai_vec | ) | [static] |
Create and return a new SundialsAbstractVector vector object. The SAMRAI vector object is wrapped so that it may be manipulated within Sundials as an N_Vector (which is typedef'd to SundialsAbstractVector* in the abstract Sundials vector interface). It is important to note that this function does not allocate storage for the vector data. Data must be allocated through the SAMRAI vector object directly. For output of the data through "N_VPrint" calls, the output stream to which the SAMRAI vector object writes will be used.
void SAMRAI::solv::Sundials_SAMRAIVector< DIM >::destroySundialsVector | ( | SundialsAbstractVector * | sundials_vec | ) | [static] |
Destroy a given Sundials vector object. It is important to note that this function does not deallocate storage for the vector data. Vector data must be deallocated hrough the SAMRAI vector object.
tbox::Pointer< SAMRAIVectorReal< DIM, double > > SAMRAI::solv::Sundials_SAMRAIVector< DIM >::getSAMRAIVector | ( | SundialsAbstractVector * | sundials_vec | ) | [static] |
Return pointer to the SAMRAI vector object associated with the given Sundials wrapper vector.
tbox::Pointer< SAMRAIVectorReal< DIM, double > > SAMRAI::solv::Sundials_SAMRAIVector< DIM >::getSAMRAIVector | ( | N_Vector | sundials_vec | ) | [static] |
Return pointer to the SAMRAI vector object associated with the given Sundials vector.
void SAMRAI::solv::Sundials_SAMRAIVector< DIM >::printVector | ( | ) | const [virtual] |
Print the vector data to the output stream used by the subclass print routine.
Implements SAMRAI::solv::SundialsAbstractVector.