Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

NRVec< T > Class Template Reference

#include <nrutil_mtl.h>

List of all members.

Public Member Functions

 NRVec ()
 NRVec (const int n)
 NRVec (const T &a, int n)
 NRVec (const T *a, int n)
 NRVec (Vector &rhs)
 NRVec (const NRVec< T > &rhs)
NRVecoperator= (const NRVec &rhs)
int size () const
T & operator[] (const int i) const
 operator Vector () const
 ~NRVec ()
 NRVec ()
 NRVec (int n)
 NRVec (const T &a, int n)
 NRVec (const T *a, int n)
 NRVec (const NRVec &rhs)
NRVecoperator= (const NRVec &rhs)
NRVecoperator= (const T &a)
T & operator[] (const int i)
const T & operator[] (const int i) const
int size () const
 ~NRVec ()
 NRVec ()
 NRVec (const int n)
 NRVec (const T &a, int n)
 NRVec (const T *a, int n)
 NRVec (TNT::Vector< T > &rhs)
 NRVec (const NRVec< T > &rhs)
NRVecoperator= (const NRVec &rhs)
NRVecoperator= (const T &rhs)
int size () const
T & operator[] (const int i) const
 operator TNT::Vector () const
 ~NRVec ()

Protected Attributes

Vector myvec
Vectormyref

Private Types

typedef dense1D< T > Vector

Private Attributes

int nn
T * v
TNT::Vector< T > myvec
TNT::Vector< T > & myref

template<class T>
class NRVec< T >


Member Typedef Documentation

template<class T>
typedef dense1D<T> NRVec< T >::Vector [private]
 

Definition at line 76 of file nrutil_mtl.h.


Constructor & Destructor Documentation

template<class T>
NRVec< T >::NRVec  )  [inline]
 

Reimplemented in NRVec< bool >.

Definition at line 80 of file nrutil_nr.h.

00080 : nn(0), v(0) {}

template<class T>
NRVec< T >::NRVec const int  n  )  [inline, explicit]
 

Reimplemented in NRVec< bool >.

Definition at line 83 of file nrutil_nr.h.

00083 : nn(n), v(new T[n]) {}

template<class T>
NRVec< T >::NRVec const T &  a,
int  n
[inline]
 

Definition at line 86 of file nrutil_nr.h.

References NRVec< T >::v.

00086                                  : nn(n), v(new T[n])
00087 {
00088   for(int i=0; i<n; i++)
00089     v[i] = a;
00090 }

template<class T>
NRVec< T >::NRVec const T *  a,
int  n
[inline]
 

Definition at line 93 of file nrutil_nr.h.

References NRVec< T >::v.

00093                                  : nn(n), v(new T[n])
00094 {
00095   for(int i=0; i<n; i++)
00096     v[i] = *a++;
00097 }

template<class T>
NRVec< T >::NRVec Vector rhs  )  [inline]
 

template<class T>
NRVec< T >::NRVec const NRVec< T > &  rhs  )  [inline]
 

Definition at line 90 of file nrutil_mtl.h.

00090                                    : myvec(rhs.myref.size()), myref(myvec)
00091                 {copy(rhs.myref,myref);}

template<class T>
NRVec< T >::~NRVec  )  [inline]
 

Definition at line 103 of file nrutil_mtl.h.

00103 {}

template<class T>
NRVec< T >::NRVec  ) 
 

Reimplemented in NRVec< bool >.

template<class T>
NRVec< T >::NRVec int  n  )  [explicit]
 

Reimplemented in NRVec< bool >.

template<class T>
NRVec< T >::NRVec const T &  a,
int  n
 

template<class T>
NRVec< T >::NRVec const T *  a,
int  n
 

template<class T>
NRVec< T >::NRVec const NRVec< T > &  rhs  ) 
 

template<class T>
NRVec< T >::~NRVec  ) 
 

template<class T>
NRVec< T >::NRVec  )  [inline]
 

Reimplemented in NRVec< bool >.

template<class T>
NRVec< T >::NRVec const int  n  )  [inline, explicit]
 

Reimplemented in NRVec< bool >.

template<class T>
NRVec< T >::NRVec const T &  a,
int  n
[inline]
 

template<class T>
NRVec< T >::NRVec const T *  a,
int  n
[inline]
 

template<class T>
NRVec< T >::NRVec TNT::Vector< T > &  rhs  )  [inline]
 

template<class T>
NRVec< T >::NRVec const NRVec< T > &  rhs  )  [inline]
 

Definition at line 87 of file nrutil_tnt.h.

00087 : myvec(rhs.myref), myref(myvec) {}

template<class T>
NRVec< T >::~NRVec  )  [inline]
 

Definition at line 99 of file nrutil_tnt.h.

00099 {}


Member Function Documentation

template<class T>
NRVec< T >::operator TNT::Vector  )  const [inline]
 

Definition at line 96 of file nrutil_tnt.h.

00096 {return myref;}

template<class T>
NRVec< T >::operator Vector  )  const [inline]
 

Definition at line 100 of file nrutil_mtl.h.

00100 {return myref;}

template<class T>
NRVec& NRVec< T >::operator= const T &  rhs  )  [inline]
 

Definition at line 91 of file nrutil_tnt.h.

00091 { myvec=rhs; return *this;}

template<class T>
NRVec& NRVec< T >::operator= const NRVec< T > &  rhs  )  [inline]
 

Definition at line 89 of file nrutil_tnt.h.

00089 { myref=rhs.myref; return *this;}

template<class T>
NRVec< T > & NRVec< T >::operator= const T &  a  ) 
 

Definition at line 126 of file nrutil_nr.h.

References NRVec< T >::v.

00127 {
00128   for (int i=0; i<nn; i++)
00129     v[i]=a;
00130   return *this;
00131 }

template<class T>
NRVec& NRVec< T >::operator= const NRVec< T > &  rhs  ) 
 

template<class T>
NRVec< T > & NRVec< T >::operator= const NRVec< T > &  rhs  )  [inline]
 

Definition at line 94 of file nrutil_mtl.h.

00094                                                   {
00095                 if (myref.size() != rhs.myref.size())
00096                         myref.resize(rhs.myref.size());
00097                 copy(rhs.myref,myref); return *this;}

template<class T>
T& NRVec< T >::operator[] const int  i  )  const [inline]
 

Definition at line 94 of file nrutil_tnt.h.

00094 {return myref[i];}

template<class T>
const T& NRVec< T >::operator[] const int  i  )  const [inline]
 

template<class T>
T & NRVec< T >::operator[] const int  i  )  [inline]
 

Definition at line 134 of file nrutil_nr.h.

References NRVec< T >::v.

00135 {
00136   return v[i];
00137 }

template<class T>
const T & NRVec< T >::operator[] const int  i  )  const [inline]
 

Definition at line 99 of file nrutil_mtl.h.

00099 {return myref[i];}

template<class T>
int NRVec< T >::size  )  const [inline]
 

Definition at line 93 of file nrutil_tnt.h.

00093 {return myref.size();}

template<class T>
int NRVec< T >::size  )  const [inline]
 

template<class T>
int NRVec< T >::size  )  const [inline]
 

Definition at line 98 of file nrutil_mtl.h.

Referenced by NR::covsrt(), NR::fgauss(), NR::linmin(), NR::mrqcof(), MinosMinimization::MrqCof(), NR::mrqmin(), MinosMinimization::MrqMin(), NRVec< DP >::operator=(), NR::powell(), MinosMinimization::SetMarquardtBinInfo(), MinosMinimization::SetSystematicParameters(), and NRVec< DP >::size().

00098 {return myref.size();}


Member Data Documentation

template<class T>
TNT::Vector<T>& NRVec< T >::myref [private]
 

Definition at line 78 of file nrutil_tnt.h.

template<class T>
Vector& NRVec< T >::myref [protected]
 

Definition at line 79 of file nrutil_mtl.h.

Referenced by NRVec< DP >::NRVec(), and NRVec< DP >::operator=().

template<class T>
TNT::Vector<T> NRVec< T >::myvec [private]
 

Definition at line 77 of file nrutil_tnt.h.

template<class T>
Vector NRVec< T >::myvec [protected]
 

Definition at line 78 of file nrutil_mtl.h.

template<class T>
int NRVec< T >::nn [private]
 

Definition at line 63 of file nrutil_nr.h.

template<class T>
T* NRVec< T >::v [private]
 

Definition at line 64 of file nrutil_nr.h.

Referenced by NRVec< T >::NRVec(), NRVec< T >::operator=(), and NRVec< T >::operator[]().


The documentation for this class was generated from the following files:
Generated on Thu Nov 1 11:59:43 2007 for loon by  doxygen 1.3.9.1