SOFA API  c76874b7
Open source framework for multi-physics simuation
sofa::component::linearsolver::EigenVector< double > Class Template Reference

#include <EigenVector.h>

Inheritance diagram for sofa::component::linearsolver::EigenVector< double >:

Detailed Description

template<>
class sofa::component::linearsolver::EigenVector< double >

Container of an Eigen vector.

Protected Attributes

VectorEigen eigenVector
 the data More...
 

Public Member Functions

VectorEigengetVectorEigen ()
 
const VectorEigengetVectorEigen () const
 
Index size () const override
 Number of elements. More...
 
 EigenVector (Index nbRow=0)
 
void resize (Index nbRow) override
 Resize the matrix without preserving the data. More...
 
SReal element (Index i) const override
 Read the value of element i. More...
 
void set (Index i, double v) override
 
void add (Index i, double v) override
 
void clear (Index i) override
 Reset the value of element i to 0. More...
 
void clear () override
 Set all values to 0. More...
 
- Public Member Functions inherited from sofa::defaulttype::BaseVector
virtual ~BaseVector ()
 
virtual void set (Index i, SReal v)=0
 Write the value of element i. More...
 
virtual void add (Index i, SReal v)=0
 Add v to the existing value of element i. More...
 
virtual const floatelements (Index i0, Index n, float *src) const
 Get the values of n elements, starting at element i0, into given float buffer, or return the pointer to the data if the in-memory format is compatible. More...
 
virtual const doubleelements (Index i0, Index n, double *src) const
 Get the values of n elements, starting at element i0, into given double buffer, or return the pointer to the data if the in-memory format is compatible. More...
 
virtual const intelements (Index i0, Index n, int *src) const
 Get the values of n elements, starting at element i0, into given int buffer, or return the pointer to the data if the in-memory format is compatible. More...
 
virtual void set (Index i0, Index n, const float *src)
 Write the values of n float elements, starting at element i0. More...
 
virtual void set (Index i0, Index n, const double *src)
 Write the values of n double elements, starting at element i0. More...
 
virtual void set (Index i0, Index n, const int *src)
 Write the values of n int elements, starting at element i0. More...
 
virtual void add (Index i0, Index n, const float *src)
 Add to the values of n float elements, starting at element i0. More...
 
virtual void add (Index i0, Index n, const double *src)
 Add to the values of n double elements, starting at element i0. More...
 
virtual void add (Index i0, Index n, const int *src)
 Add to the values of n int elements, starting at element i0. More...
 
virtual ElementType getElementType () const
 
virtual std::size_t getElementSize () const
 
virtual bool isFull () const
 Return true if this vector is full, i.a. all elements are stored in memory. More...
 
bool isSparse () const
 

Static Public Member Functions

static const char * Name ()
 

Additional Inherited Members

- Protected Member Functions inherited from sofa::defaulttype::BaseVector
template<class T >
const T * elementsDefaultImpl (Index i0, Index n, T *buffer) const
 
template<class T >
void setDefaultImpl (Index i0, Index n, const T *src)
 
template<class T >
void addDefaultImpl (Index i0, Index n, const T *src)
 

Attribute details

Constructor details

Function details

void sofa::component::linearsolver::EigenVector< double >::add ( Index  i,
double  v 
)
inlineoverride
void sofa::component::linearsolver::EigenVector< double >::clear ( Index  i)
inlineoverridevirtual

Reset the value of element i to 0.

Reimplemented from sofa::defaulttype::BaseVector.

void sofa::component::linearsolver::EigenVector< double >::clear ( )
inlineoverridevirtual

Set all values to 0.

Implements sofa::defaulttype::BaseVector.

SReal sofa::component::linearsolver::EigenVector< double >::element ( Index  i) const
inlineoverridevirtual

Read the value of element i.

Implements sofa::defaulttype::BaseVector.

const VectorEigen& sofa::component::linearsolver::EigenVector< double >::getVectorEigen ( ) const
inline
const char * sofa::component::linearsolver::EigenVector< double >::Name ( )
static
void sofa::component::linearsolver::EigenVector< double >::resize ( Index  nbRow)
inlineoverridevirtual

Resize the matrix without preserving the data.

Implements sofa::defaulttype::BaseVector.

void sofa::component::linearsolver::EigenVector< double >::set ( Index  i,
double  v 
)
inlineoverride
Index sofa::component::linearsolver::EigenVector< double >::size ( ) const
inlineoverridevirtual

Number of elements.

Implements sofa::defaulttype::BaseVector.