LaColVectorDouble Class Reference

Column vector. More...

#include <lacvd.h>

Inheritance diagram for LaColVectorDouble:

LaGenMatDouble List of all members.

Public Member Functions

 LaColVectorDouble ()
 LaColVectorDouble (int)
 LaColVectorDouble (double *, int)
 LaColVectorDouble (const LaGenMatDouble &)
int size () const
int inc () const
LaIndex index () const
int start () const
int end () const
double & operator() (int i)
const double & operator() (int i) const
LaColVectorDouble operator() (const LaIndex &)
LaColVectorDoubleoperator= (const LaGenMatDouble &A)
LaColVectorDoubleoperator= (double d)

Detailed Description

Column vector.

A column vector is simply an nx1 matrix, only that it can be constructed and accessed by a single dimension. (FIXME: It is unclear whether this class is actually well supported inside Lapack++; probably you should only use LaVectorDouble instead.)


Constructor & Destructor Documentation

LaColVectorDouble::LaColVectorDouble (  )  [inline]

LaColVectorDouble::LaColVectorDouble ( int   )  [inline]

LaColVectorDouble::LaColVectorDouble ( double *  ,
int   
) [inline]

LaColVectorDouble::LaColVectorDouble ( const LaGenMatDouble  )  [inline]


Member Function Documentation

int LaColVectorDouble::size (  )  const [inline]

int LaColVectorDouble::inc (  )  const [inline]

LaIndex LaColVectorDouble::index (  )  const [inline]

int LaColVectorDouble::start (  )  const [inline]

int LaColVectorDouble::end (  )  const [inline]

double & LaColVectorDouble::operator() ( int  i  )  [inline]

const double & LaColVectorDouble::operator() ( int  i  )  const [inline]

LaColVectorDouble LaColVectorDouble::operator() ( const LaIndex  )  [inline]

LaColVectorDouble & LaColVectorDouble::operator= ( const LaGenMatDouble A  )  [inline]

Release left-hand side (reclaiming memory space if possible) and copy elements of elements of s. Unline inject(), it does not require conformity, and previous references of left-hand side are unaffected.

This is an alias for copy().

Watch out! Due to the C++ "named return value optimization" you cannot use this as an alias for copy() when declaring a variable if the right-side is a return value of operator(). More precisely, you cannot write the following:

       LaGenMatDouble x = y(LaIndex(),LaIndex()); // erroneous reference copy!
       

Instead, if the initialization should create a new copy of the right-side matrix, you have to write it this way:

       LaGenMatDouble x = y(LaIndex(),LaIndex()).copy(); // correct deep-copy
       

Or this way:

       LaGenMatDouble x;
       x = y(LaIndex(),LaIndex()); // correct deep-copy
       

Note: The manual for lapack++-1.1 claimed that this operator would be an alias for ref(), not for copy(), i.e. this operator creates a reference instead of a deep copy. However, since that confused many people, the behaviour was changed so that B=A will now create B as a deep copy instead of a reference. If you want a reference, please write B.ref(A) explicitly.

Reimplemented from LaGenMatDouble.

LaColVectorDouble & LaColVectorDouble::operator= ( double  d  )  [inline]

Set elements of left-hand side to the scalar value s. No new matrix is created, so that if there are other matrices that reference this memory space, they will also be affected.

Reimplemented from LaGenMatDouble.


Generated on Sat Jul 14 11:40:37 2007 for Lapack++ by  doxygen 1.5.0