Documentation


nr::STL_Traits< RealT, VectorT, MatrixT > Struct Template Reference

#include <utils.h>

List of all members.


Detailed Description

template<class RealT = double, class VectorT = std::vector< RealT >, class MatrixT = std::vector< VectorT >>
struct nr::STL_Traits< RealT, VectorT, MatrixT >

Numerical Recipes methods: Traits for programming using STL vectors.

Definition at line 121 of file numrecipes/optimization/utils.h.

Public Types

typedef RealT Real
 floating point value

typedef VectorT Vector
 vector

typedef MatrixT Matrix
 matrix


Static Public Member Functions

void alloc_vector (Vector &v, unsigned int size)
 allocate a vector

void free_vector (Vector &)
 free vector (does nothing, just for compatibility)

void alloc_matrix (Matrix &mat, unsigned int rows, unsigned int columns)
 allocate a matrix

void free_matrix (Matrix &, unsigned int, unsigned int)
 free matrix (does nothing, just for compatibility)


Member Typedef Documentation

template<class RealT = double, class VectorT = std::vector< RealT >, class MatrixT = std::vector< VectorT >>
typedef MatrixT nr::STL_Traits< RealT, VectorT, MatrixT >::Matrix
 

matrix

Definition at line 129 of file numrecipes/optimization/utils.h.

Referenced by nr::STL_Traits< RealT, VectorT, MatrixT >::alloc_matrix().

template<class RealT = double, class VectorT = std::vector< RealT >, class MatrixT = std::vector< VectorT >>
typedef RealT nr::STL_Traits< RealT, VectorT, MatrixT >::Real
 

floating point value

Definition at line 125 of file numrecipes/optimization/utils.h.

template<class RealT = double, class VectorT = std::vector< RealT >, class MatrixT = std::vector< VectorT >>
typedef VectorT nr::STL_Traits< RealT, VectorT, MatrixT >::Vector
 

vector

Definition at line 127 of file numrecipes/optimization/utils.h.

Referenced by nr::STL_Traits< RealT, VectorT, MatrixT >::alloc_matrix(), and nr::STL_Traits< RealT, VectorT, MatrixT >::alloc_vector().


Member Function Documentation

template<class RealT = double, class VectorT = std::vector< RealT >, class MatrixT = std::vector< VectorT >>
void nr::STL_Traits< RealT, VectorT, MatrixT >::alloc_matrix Matrix mat,
unsigned int  rows,
unsigned int  columns
[inline, static]
 

allocate a matrix

Parameters:
mat the matrix to allocate
rows number of rows
columns number of columns

Definition at line 150 of file numrecipes/optimization/utils.h.

References nr::STL_Traits< RealT, VectorT, MatrixT >::Matrix, and nr::STL_Traits< RealT, VectorT, MatrixT >::Vector.

template<class RealT = double, class VectorT = std::vector< RealT >, class MatrixT = std::vector< VectorT >>
void nr::STL_Traits< RealT, VectorT, MatrixT >::alloc_vector Vector v,
unsigned int  size
[inline, static]
 

allocate a vector

Parameters:
v the vector to allocate
size the size of the vector to allocate

Definition at line 135 of file numrecipes/optimization/utils.h.

References nr::STL_Traits< RealT, VectorT, MatrixT >::Vector.

template<class RealT = double, class VectorT = std::vector< RealT >, class MatrixT = std::vector< VectorT >>
void nr::STL_Traits< RealT, VectorT, MatrixT >::free_matrix Matrix ,
unsigned  int,
unsigned  int
[inline, static]
 

free matrix (does nothing, just for compatibility)

Definition at line 159 of file numrecipes/optimization/utils.h.

template<class RealT = double, class VectorT = std::vector< RealT >, class MatrixT = std::vector< VectorT >>
void nr::STL_Traits< RealT, VectorT, MatrixT >::free_vector Vector  )  [inline, static]
 

free vector (does nothing, just for compatibility)

Definition at line 141 of file numrecipes/optimization/utils.h.


The documentation for this struct was generated from the following file:
Generated on Thu Dec 23 13:52:34 2004 by doxygen 1.3.6