ADMB Documentation  -a65f1c97
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Private Attributes | Friends | List of all members
dvar_matrix Class Reference

Class definition of matrix with derivitive information . More...

#include <fvar.hpp>

Public Member Functions

 dvar_matrix ()
 Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California. More...
 
 dvar_matrix (const banded_symmetric_dvar_matrix &v)
 Description not yet available. More...
 
 dvar_matrix (const banded_lower_triangular_dvar_matrix &v)
 Description not yet available. More...
 
 dvar_matrix (const param_init_vector_vector &)
 
 dvar_matrix (const param_init_bounded_vector_vector &)
 
 dvar_matrix (const param_init_bounded_number_matrix &)
 Description not yet available. More...
 
 dvar_matrix (const ad_integer &nrl, const ad_integer &nrh, const index_type &ncl, const index_type &nch)
 Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California. More...
 
 dvar_matrix (int, int, int, int)
 Constructs AD variable matrix with dimensions nrl to nrh by ncl to nch. More...
 
 dvar_matrix (int, int)
 Description not yet available. More...
 
 dvar_matrix (int, int, kkludge_object kk)
 Description not yet available. More...
 
 dvar_matrix (int, int, const ivector &, const ivector &)
 Description not yet available. More...
 
 dvar_matrix (int, int, int, const ivector &)
 Description not yet available. More...
 
 dvar_matrix (const dvar_matrix &)
 Copy constructor. More...
 
 dvar_matrix (const dmatrix &)
 Copy constructor. More...
 
 ~dvar_matrix ()
 Destructor. More...
 
void allocate (int nrl, int nrh, int ncl, int nch)
 Allocates AD variable matrix with dimensions nrl to nrh by ncl to nch. More...
 
void allocate (int nrl, int nrh)
 Allocate variable matrix with dimension [nrl to nrh] where columns are empty. More...
 
void allocate (ad_integer nrl, ad_integer nrh)
 Allocate variable matrix with dimension [nrl to nrh] where columns are empty. More...
 
void allocate (const dmatrix &m1)
 Allocate variable matrix using the same dimensions as m1. More...
 
void allocate (const dvar_matrix &m1)
 Allocate variable matrix using the same dimensions as m1. More...
 
void allocate (int nrl, int nrh, const ivector &ncl, const ivector &nch)
 Allocate variable matrix with dimensions [nrl to nrh] x [ncl to nch] where ncl and nch. More...
 
void allocate (int nrl, int nrh, int ncl, const ivector &nch)
 Allocate variable matrix with dimensions [nrl to nrh] x [ncl to nch] where nch is a vector of indexes. More...
 
void allocate (int nrl, int nrh, const ivector &ncl, int nch)
 Allocate variable matrix with dimensions [nrl to nrh] x [ncl to nch] where ncl is a vector of indexes. More...
 
void allocate (void)
 Does not allocate, but initializes members. More...
 
void allocate (const ad_integer &nrl, const ad_integer &nrh, const index_type &ncl, const index_type &nch)
 Allocates AD variable matrix with dimensions nrl to nrh by ncl to nch. More...
 
void colfill (int j, const dvar_vector &v)
 Fills column of a matrix with a vector (supplied) More...
 
void colfill_randn (const int &j, long int &n)
 Description not yet available. More...
 
void colfill_randn_ni (const int &j, long int &n)
 Description not yet available. More...
 
void colfill_randu (const int &j, long int &n)
 Description not yet available. More...
 
void colfill_randu_ni (const int &j, long int &n)
 Description not yet available. More...
 
void colfill_seqadd (const int &, double, double)
 Fills column of a matrix with a sequence of the form base, base+offset, base+2*offset,... More...
 
void colfill_seqadd_ni (const int &, double, double)
 
int colmax (void) const
 
int colmin (void) const
 
void colshift (int min)
 Description not yet available. More...
 
unsigned int colsize () const
 
void deallocate ()
 Deallocate dvar_matrix memory. More...
 
dvar_vectorelem (int i)
 
prevariable elem (int i, int j)
 
dvar_vectorelem (int i) const
 
prevariable elem (int i, int j) const
 
double & elem_value (int i, int j)
 
const double & elem_value (int i, int j) const
 
void fill (const char *)
 Fill values of dvar_matrix with text input from s with format rowmin...rowmax where ith row is {colmin,...,colmax}. More...
 
void fill_randn (long int &n)
 Description not yet available. More...
 
void fill_randn_ni (long int &n)
 Description not yet available. More...
 
void fill_randu (long int &n)
 Description not yet available. More...
 
void fill_randu_ni (long int &n)
 Description not yet available. More...
 
double fill_seqadd (double, double)
 Description not yet available. More...
 
unsigned int get_ncopies () const
 
int indexmax (void) const
 
int indexmin (void) const
 
void initialize (void)
 Zero initialize allocated dvar_matrix, then saves adjoint function and position data. More...
 
int operator! (void) const
 
dvar_vectoroperator() (int i)
 
const dvar_vectoroperator() (int i) const
 
prevariable operator() (int i, int j)
 
prevariable operator() (int i, int j) const
 
dvar_matrixoperator*= (const prevariable &t)
 Description not yet available. More...
 
dvar_matrixoperator*= (double t)
 Description not yet available. More...
 
dvar_matrixoperator++ (void)
 
dvar_matrixoperator+= (const dvar_matrix &x)
 Description not yet available. More...
 
dvar_matrixoperator+= (const dmatrix &x)
 Description not yet available. More...
 
dvar_matrixoperator-- (void)
 
dvar_matrixoperator-= (const dvar_matrix &x)
 Description not yet available. More...
 
dvar_matrixoperator-= (const dmatrix &x)
 Description not yet available. More...
 
dvar_matrixoperator/= (const prevariable &t)
 Description not yet available. More...
 
dvar_matrixoperator/= (double t)
 Description not yet available. More...
 
dvar_matrixoperator= (const dvar_matrix &)
 Assigns other values to dvar_matrix. More...
 
dvar_matrixoperator= (const dmatrix &)
 Assigns scalar matrix values to dvar_matrix. More...
 
dvar_matrixoperator= (double t)
 Description not yet available. More...
 
dvar_matrixoperator= (const prevariable &t)
 Description not yet available. More...
 
dvar_vectoroperator[] (int)
 
const dvar_vectoroperator[] (int) const
 
void read_from (const istream &)
 Read values to dvar_matrix from input istream s. More...
 
void read_from (const uistream &)
 Read values to dvar_matrix from input stream s. More...
 
void rowfill (int j, const dvar_vector &v)
 Fills row of a matrix with a vector (supplied) More...
 
void rowfill_randn (const int &i, long int &n)
 Description not yet available. More...
 
void rowfill_randn_ni (const int &i, long int &n)
 Description not yet available. More...
 
void rowfill_randu (const int &i, long int &n)
 Description not yet available. More...
 
void rowfill_randu_ni (const int &i, long int &n)
 Description not yet available. More...
 
void rowfill_seqadd (const int &, double, double)
 Fills vector with a sequence of the form base, base+offset, base+2*offset,... More...
 
int rowmax (void) const
 
int rowmin (void) const
 
void rowshift (int min)
 Description not yet available. More...
 
unsigned int rowsize () const
 
void save_dvar_matrix_position () const
 Description not yet available. More...
 
void save_dvar_matrix_value () const
 Saves the size, address, and value information for a dvar_matrix. More...
 
void shallow_copy (const dvar_matrix &)
 Shallow copy other data structure pointers. More...
 
dvar_matrix sub (int, int)
 Description not yet available. More...
 
void write_on (const ostream &) const
 Description not yet available. More...
 
void write_on (const uostream &) const
 Write values from dvar_matrix to output stream s. More...
 

Private Attributes

int index_max
 
int index_min
 
dvar_vectorm
 
mat_shapexshape
 

Friends

class banded_lower_triangular_dmatrix
 
class banded_lower_triangular_dvar_matrix
 
class banded_symmetric_dmatrix
 
class banded_symmetric_dvar_matrix
 
void copy_status (const ostream &s, const dvar_matrix &m1)
 Description not yet available. More...
 
dvariable det (const dvar_matrix &)
 Determinaant of matrix. More...
 
class dvar3_array
 
class dvar_vector
 
char * fform (const char *, const dvar_matrix &)
 
dvar_matrix inv (const dvar_matrix &)
 Inverse of a varaiable matrix. More...
 
dvariable ln_det (const dvar_matrix &, int &sgn)
 

The implementation of this algorithm was inspired by "Numerical Recipes in C", 2nd edition, Press, Teukolsky, Vetterling, Flannery, chapter 2 More...
 
dvariable norm (const dvar_matrix &)
 Description not yet available. More...
 
dvariable norm2 (const dvar_matrix &)
 
dvar_vector operator* (const dvar_vector &, const dvar_matrix &)
 Description not yet available. More...
 
dvar_vector operator* (const dvar_matrix &, const dvar_vector &)
 Description not yet available. More...
 
dvar_vector operator* (const dvector &, const dvar_matrix &)
 Description not yet available. More...
 
dvar_vector operator* (const dvar_matrix &, const dvector &)
 Description not yet available. More...
 
dvar_matrix operator* (const dvar_matrix &, const dvar_matrix &)
 Description not yet available. More...
 
dvar_matrix operator* (const dvar_matrix &, const dmatrix &)
 Description not yet available. More...
 
dvar_matrix operator* (const dmatrix &, const dvar_matrix &)
 Description not yet available. More...
 
dvar_matrix operator+ (const dvar_matrix &, const dvar_matrix &)
 Description not yet available. More...
 
dvar_matrix operator+ (const dvar_matrix &, const dmatrix &)
 Description not yet available. More...
 
dvar_matrix operator+ (const dmatrix &, const dvar_matrix &)
 Description not yet available. More...
 
dvar_matrix operator+ (double, const dvar_matrix &)
 Description not yet available. More...
 
dvar_matrix operator+ (const dvar_matrix &, double)
 Description not yet available. More...
 
dvar_matrix operator+ (const dvariable &, const dvar_matrix &)
 Description not yet available. More...
 
dvar_matrix operator+ (const dvar_matrix &, const dvariable &)
 Description not yet available. More...
 
dvar_matrix operator- (double, const dvar_matrix &)
 Description not yet available. More...
 
dvar_matrix operator- (const dvar_matrix &, double)
 Description not yet available. More...
 
dvar_matrix operator- (const dvariable &, const dvar_matrix &)
 Description not yet available. More...
 
dvar_matrix operator- (const dvar_matrix &, const dvariable &)
 Description not yet available. More...
 
dvar_matrix operator- (const dvar_matrix &, const dvar_matrix &)
 Description not yet available. More...
 
dvar_matrix operator- (const dvar_matrix &, const dmatrix &)
 Description not yet available. More...
 
dvar_matrix operator- (const dmatrix &, const dvar_matrix &)
 Description not yet available. More...
 
dvariable sumsq (const dvar_matrix &)
 
dvar_matrix trans (const dvar_matrix &)
 Description not yet available. More...
 

Detailed Description

Class definition of matrix with derivitive information .

Definition at line 2480 of file fvar.hpp.

Constructor & Destructor Documentation

dvar_matrix::dvar_matrix ( )

Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.

Default constructor

Definition at line 15 of file fvar_mat.cpp.

Referenced by param_init_matrix::allocate(), param_init_bounded_matrix::allocate(), param_init_matrix::restore_value(), param_init_matrix::save_value(), and param_stddev_matrix::set_dependent_variables().

dvar_matrix::dvar_matrix ( const banded_symmetric_dvar_matrix S1)

Description not yet available.

Parameters

Definition at line 535 of file fvar_m40.cpp.

dvar_matrix::dvar_matrix ( const banded_lower_triangular_dvar_matrix S1)

Description not yet available.

Parameters

Definition at line 569 of file fvar_m40.cpp.

dvar_matrix::dvar_matrix ( const param_init_vector_vector )
dvar_matrix::dvar_matrix ( const param_init_bounded_vector_vector )
dvar_matrix::dvar_matrix ( const param_init_bounded_number_matrix pibnm)

Description not yet available.

Parameters

Definition at line 132 of file fvar_mat.cpp.

dvar_matrix::dvar_matrix ( const ad_integer nrl,
const ad_integer nrh,
const index_type ncl,
const index_type nch 
)

Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.

Construct AD variable matrix with dimensions nrl to nrh by ncl to nch.

Parameters
nrllower row index
nrhhigher row index
ncllower column index
nchhigher column index

Definition at line 19 of file fvar_m37.cpp.

dvar_matrix::dvar_matrix ( int  nrl,
int  nrh,
int  ncl,
int  nch 
)

Constructs AD variable matrix with dimensions nrl to nrh by ncl to nch.

Parameters
nrlrow lower index
nrhrow higher index
nclcolumn lower index
nchcolumn higher index

Definition at line 96 of file fvar_mat.cpp.

dvar_matrix::dvar_matrix ( int  nrl,
int  nrh 
)

Description not yet available.

Parameters

Definition at line 120 of file fvar_mat.cpp.

dvar_matrix::dvar_matrix ( int  nrl,
int  nrh,
kkludge_object  kk 
)

Description not yet available.

Parameters

Definition at line 108 of file fvar_mat.cpp.

dvar_matrix::dvar_matrix ( int  nrl,
int  nrh,
const ivector ncl,
const ivector nch 
)

Description not yet available.

Parameters

Definition at line 318 of file fvar_mat.cpp.

dvar_matrix::dvar_matrix ( int  nrl,
int  nrh,
int  ncl,
const ivector nch 
)

Description not yet available.

Parameters

Definition at line 383 of file fvar_mat.cpp.

dvar_matrix::dvar_matrix ( const dvar_matrix other)

Copy constructor.

Parameters
other

Definition at line 24 of file fvar_mat.cpp.

dvar_matrix::dvar_matrix ( const dmatrix other)

Copy constructor.

Definition at line 46 of file fvar_mat.cpp.

dvar_matrix::~dvar_matrix ( )

Destructor.

Definition at line 73 of file fvar_mat.cpp.

Member Function Documentation

void dvar_matrix::allocate ( int  nrl,
int  nrh,
int  ncl,
int  nch 
)

Allocates AD variable matrix with dimensions nrl to nrh by ncl to nch.

Parameters
nrlrow lower index
nrhrow higher index
nclcolumn lower index
nchcolumn higher index

Definition at line 216 of file fvar_mat.cpp.

Referenced by dvar3_array::allocate(), calculate_laplace_approximation(), cube(), mfexp(), operator-(), operator/(), and square().

void dvar_matrix::allocate ( int  nrl,
int  nrh 
)

Allocate variable matrix with dimension [nrl to nrh] where columns are empty.

If nrl greater than nrh, then dvar_matrix is initialized as empty.

Parameters
nrllower index
nrhupper index

Definition at line 178 of file fvar_mat.cpp.

void dvar_matrix::allocate ( ad_integer  nrl,
ad_integer  nrh 
)

Allocate variable matrix with dimension [nrl to nrh] where columns are empty.

If nrl greater than nrh, then dvar_matrix is initialized as empty.

Parameters
nrllower index
nrhupper index

Definition at line 234 of file fvar_mat.cpp.

void dvar_matrix::allocate ( const dmatrix m1)

Allocate variable matrix using the same dimensions as m1.

Definition at line 242 of file fvar_mat.cpp.

void dvar_matrix::allocate ( const dvar_matrix m1)

Allocate variable matrix using the same dimensions as m1.

Definition at line 279 of file fvar_mat.cpp.

void dvar_matrix::allocate ( int  nrl,
int  nrh,
const ivector ncl,
const ivector nch 
)

Allocate variable matrix with dimensions [nrl to nrh] x [ncl to nch] where ncl and nch.

Parameters
nrllower row index
nrlupper row index
nclvector of lower column indexes
nchvector of upper column indexes

Definition at line 336 of file fvar_mat.cpp.

void dvar_matrix::allocate ( int  nrl,
int  nrh,
int  ncl,
const ivector nch 
)

Allocate variable matrix with dimensions [nrl to nrh] x [ncl to nch] where nch is a vector of indexes.

Parameters
nrllower row index
nrhupper row index
ncllower column index
nchvector upper column indexes

Definition at line 399 of file fvar_mat.cpp.

void dvar_matrix::allocate ( int  nrl,
int  nrh,
const ivector ncl,
int  nch 
)

Allocate variable matrix with dimensions [nrl to nrh] x [ncl to nch] where ncl is a vector of indexes.

Parameters
nrllower row index
nrhupper row index
nclvector lower column indexes
nchupper column index

Definition at line 444 of file fvar_mat.cpp.

void dvar_matrix::allocate ( void  )
void dvar_matrix::allocate ( const ad_integer nrl,
const ad_integer nrh,
const index_type ncl,
const index_type nch 
)

Allocates AD variable matrix with dimensions nrl to nrh by ncl to nch.

Parameters
nrllower row index
nrhhigher row index
ncllower column index
nchhigher column index

Definition at line 36 of file fvar_m37.cpp.

void dvar_matrix::colfill ( int  j,
const dvar_vector v 
)

Fills column of a matrix with a vector (supplied)

Author
Dave Fournier
Date
2008-03-25
Parameters
jthe column
vis a vector to be inserted in the jth column
Returns
dvar_matrix with those values

Definition at line 118 of file ranfill1.cpp.

void dvar_matrix::colfill_randn ( const int &  j,
long int &  n 
)

Description not yet available.

Parameters

Definition at line 136 of file ranfill2.cpp.

void dvar_matrix::colfill_randn_ni ( const int &  j,
long int &  n 
)

Description not yet available.

Parameters

Definition at line 175 of file ranf_ni2.cpp.

void dvar_matrix::colfill_randu ( const int &  j,
long int &  n 
)

Description not yet available.

Parameters

Definition at line 82 of file ranfill2.cpp.

void dvar_matrix::colfill_randu_ni ( const int &  j,
long int &  n 
)

Description not yet available.

Parameters

Definition at line 74 of file ranf_ni2.cpp.

void dvar_matrix::colfill_seqadd ( const int &  j,
double  base,
double  offset 
)

Fills column of a matrix with a sequence of the form base, base+offset, base+2*offset,...

Author
Dave Fournier
Date
2008-03-25
Parameters
jthe column
baseis the starting value
offsetbase+offset,base+offset*2,...,
Returns
dvar_matrix with those values

Definition at line 74 of file ranfill1.cpp.

void dvar_matrix::colfill_seqadd_ni ( const int &  ,
double  ,
double   
)
int dvar_matrix::colmax ( void  ) const
inline
int dvar_matrix::colmin ( void  ) const
inline
void dvar_matrix::colshift ( int  min)

Description not yet available.

Parameters

Definition at line 28 of file fvar_ma9.cpp.

Referenced by eigenvalues(), and eigenvectors().

unsigned int dvar_matrix::colsize ( ) const
inline

Definition at line 2584 of file fvar.hpp.

Referenced by choleski_decomp(), det(), eigenvalues(), eigenvectors(), inv(), ln_det(), solve(), tri_dag(), and tri_dagv().

void dvar_matrix::deallocate ( void  )

Deallocate dvar_matrix memory.

Definition at line 487 of file fvar_mat.cpp.

Referenced by ~dvar_matrix().

dvar_vector& dvar_matrix::elem ( int  i)
inline
prevariable dvar_matrix::elem ( int  i,
int  j 
)
inline

Definition at line 2511 of file fvar.hpp.

dvar_vector& dvar_matrix::elem ( int  i) const
inline

Definition at line 2515 of file fvar.hpp.

prevariable dvar_matrix::elem ( int  i,
int  j 
) const
inline

Definition at line 2519 of file fvar.hpp.

double& dvar_matrix::elem_value ( int  i,
int  j 
)
inline

Definition at line 2676 of file fvar.hpp.

Referenced by column_value(), empirical_covariance(), and trans().

const double& dvar_matrix::elem_value ( int  i,
int  j 
) const
inline

Definition at line 2681 of file fvar.hpp.

void dvar_matrix::fill ( const char *  s)

Fill values of dvar_matrix with text input from s with format rowmin...rowmax where ith row is {colmin,...,colmax}.

Example dvar_matrix::fill("{1,2}{3,4}") produces dvar_matrix = 1 2 3 4

Parameters
sstring

Definition at line 50 of file fvar_m10.cpp.

void dvar_matrix::fill_randn ( long int &  n)

Description not yet available.

Parameters

Definition at line 172 of file ranfill2.cpp.

void dvar_matrix::fill_randn_ni ( long int &  n)

Description not yet available.

Parameters

Definition at line 116 of file ranf_ni2.cpp.

Referenced by dvar3_array::fill_randn(), and dvar3_array::fill_randn_ni().

void dvar_matrix::fill_randu ( long int &  n)

Description not yet available.

Parameters

Definition at line 190 of file ranfill2.cpp.

void dvar_matrix::fill_randu_ni ( long int &  n)

Description not yet available.

Parameters

Definition at line 160 of file ranf_ni2.cpp.

Referenced by dvar3_array::fill_randu(), and dvar3_array::fill_randu_ni().

double dvar_matrix::fill_seqadd ( double  x,
double  d 
)

Description not yet available.

Parameters

Definition at line 35 of file fvar_m36.cpp.

unsigned int dvar_matrix::get_ncopies ( void  ) const
inline

Definition at line 2765 of file fvar.hpp.

int dvar_matrix::indexmax ( void  ) const
inline
int dvar_matrix::indexmin ( void  ) const
inline
void dvar_matrix::initialize ( void  )

Zero initialize allocated dvar_matrix, then saves adjoint function and position data.

If dvar_matrix is empty, there are no changes.

Definition at line 48 of file fvar_ma7.cpp.

Referenced by ageLengthKey(), ALK(), dmultinom(), dmvlogistic(), dvar_matrix(), empirical_covariance(), expm(), laplace_approximation_calculator::get_hessian_from_components_lme(), dvar3_array::initialize(), make_dvar_matrix(), make_sdvar_matrix(), and MAT().

int dvar_matrix::operator! ( void  ) const
inline

Definition at line 2503 of file fvar.hpp.

dvar_vector & dvar_matrix::operator() ( int  i)
inline

Definition at line 2776 of file fvar.hpp.

Referenced by dvar_matrix().

const dvar_vector & dvar_matrix::operator() ( int  i) const
inline

Definition at line 2787 of file fvar.hpp.

prevariable dvar_matrix::operator() ( int  i,
int  j 
)
inline

Definition at line 2667 of file fvar.hpp.

prevariable dvar_matrix::operator() ( int  i,
int  j 
) const
inline

Definition at line 2692 of file fvar.hpp.

dvar_matrix & dvar_matrix::operator*= ( const prevariable x)

Description not yet available.

Parameters

Definition at line 135 of file fvar_m28.cpp.

dvar_matrix & dvar_matrix::operator*= ( double  t)

Description not yet available.

Parameters

Definition at line 115 of file fvar_m28.cpp.

dvar_matrix& dvar_matrix::operator++ ( void  )
inline

Definition at line 2495 of file fvar.hpp.

dvar_matrix & dvar_matrix::operator+= ( const dvar_matrix m1)

Description not yet available.

Parameters

Definition at line 17 of file fvar_m11.cpp.

dvar_matrix & dvar_matrix::operator+= ( const dmatrix m1)

Description not yet available.

Parameters

Definition at line 47 of file fvar_m11.cpp.

dvar_matrix& dvar_matrix::operator-- ( void  )
inline

Definition at line 2488 of file fvar.hpp.

dvar_matrix & dvar_matrix::operator-= ( const dvar_matrix m1)

Description not yet available.

Parameters

Definition at line 77 of file fvar_m11.cpp.

dvar_matrix & dvar_matrix::operator-= ( const dmatrix m1)

Description not yet available.

Parameters

Definition at line 107 of file fvar_m11.cpp.

dvar_matrix & dvar_matrix::operator/= ( const prevariable x)

Description not yet available.

Parameters

Definition at line 55 of file fvar_m28.cpp.

dvar_matrix & dvar_matrix::operator/= ( double  t)

Description not yet available.

Parameters

Definition at line 35 of file fvar_m28.cpp.

dvar_matrix & dvar_matrix::operator= ( const dvar_matrix other)
dvar_matrix & dvar_matrix::operator= ( const dmatrix other)

Assigns scalar matrix values to dvar_matrix.

Parameters
matrixdmatrix

Definition at line 553 of file fvar_mat.cpp.

dvar_matrix & dvar_matrix::operator= ( double  t)

Description not yet available.

Parameters

Definition at line 75 of file fvar_m28.cpp.

dvar_matrix & dvar_matrix::operator= ( const prevariable x)

Description not yet available.

Parameters

Definition at line 95 of file fvar_m28.cpp.

dvar_vector & dvar_matrix::operator[] ( int  i)
inline

Definition at line 2769 of file fvar.hpp.

const dvar_vector & dvar_matrix::operator[] ( int  i) const
inline

Definition at line 2783 of file fvar.hpp.

void dvar_matrix::read_from ( const istream &  s)

Read values to dvar_matrix from input istream s.

Parameters
sinput stream

Definition at line 97 of file fvarm_io.cpp.

Referenced by operator>>().

void dvar_matrix::read_from ( const uistream s)

Read values to dvar_matrix from input stream s.

Parameters
sinput stream

Definition at line 46 of file fvarm1_i.cpp.

void dvar_matrix::rowfill ( int  i,
const dvar_vector v 
)

Fills row of a matrix with a vector (supplied)

Author
Dave Fournier
Date
2008-03-25
Parameters
jthe column
vis a vector to be inserted in the jth column
Returns
dvar_matrix with those values

Definition at line 137 of file ranfill1.cpp.

void dvar_matrix::rowfill_randn ( const int &  i,
long int &  n 
)

Description not yet available.

Parameters

Definition at line 154 of file ranfill2.cpp.

void dvar_matrix::rowfill_randn_ni ( const int &  i,
long int &  n 
)

Description not yet available.

Parameters

Definition at line 189 of file ranf_ni2.cpp.

void dvar_matrix::rowfill_randu ( const int &  i,
long int &  n 
)

Description not yet available.

Parameters

Definition at line 100 of file ranfill2.cpp.

void dvar_matrix::rowfill_randu_ni ( const int &  i,
long int &  n 
)

Description not yet available.

Parameters

Definition at line 88 of file ranf_ni2.cpp.

void dvar_matrix::rowfill_seqadd ( const int &  i,
double  base,
double  offset 
)

Fills vector with a sequence of the form base, base+offset, base+2*offset,...

Author
Dave Fournier
Date
2008-03-25
Parameters
baseis the starting value
offsetbase+offset,base+offset*2,...,
Returns
dvar_vector with those value

Definition at line 96 of file ranfill1.cpp.

int dvar_matrix::rowmax ( void  ) const
inline

Definition at line 2564 of file fvar.hpp.

Referenced by param_init_matrix::add_value(), param_init_bounded_matrix::add_value(), allocate(), dmatrix::allocate(), bicubic_spline(), colfill(), colfill_randn(), colfill_randn_ni(), colfill_randu(), colfill_randu_ni(), colfill_seqadd(), colshift(), colsum(), column_value(), copy_status(), copy_value_to_vector(), cos(), cube(), param_init_matrix::curv_scale(), param_init_bounded_matrix::curv_scale(), dvar_matrix_position::dvar_matrix_position(), elem_div(), elem_prod(), exp(), expm(), extract_column(), extract_diagonal(), extract_row(), fill(), fill_randn(), fill_randn_ni(), fill_randu(), fill_randu_ni(), fill_seqadd(), param_init_matrix::get_jacobian(), param_init_bounded_matrix::get_jacobian(), log(), matrix2vector(), param_init_matrix::mc_scale(), param_init_bounded_matrix::mc_scale(), nograd_assign_column(), nograd_assign_row(), norm(), norm2(), operator*(), operator+(), operator+=(), operator-(), operator-=(), operator<<(), operator=(), operator>>(), posfun(), pow(), read_from(), restore_value_from_vector(), banded_symmetric_dvar_matrix::rowmax(), banded_lower_triangular_dvar_matrix::rowmax(), rowsize(), rowsum(), DF_FILE::save_dvar_matrix_position(), DF_FILE::save_dvar_matrix_value(), param_init_matrix::sd_scale(), param_init_bounded_matrix::sd_scale(), param_init_matrix::sd_vscale(), param_init_bounded_matrix::sd_vscale(), param_init_matrix::set_simulation_bounds(), param_init_bounded_matrix::set_simulation_bounds(), set_value(), set_value_inv(), sin(), size_count(), size_count_partial(), splie2(), splin2(), sqr(), sqrt(), square(), sum(), symmetrize(), tan(), trace(), use_shape(), value(), write_on(), dll_param_init_matrix::~dll_param_init_matrix(), and dll_param_matrix::~dll_param_matrix().

int dvar_matrix::rowmin ( void  ) const
inline

Definition at line 2560 of file fvar.hpp.

Referenced by param_init_matrix::add_value(), param_init_bounded_matrix::add_value(), allocate(), dmatrix::allocate(), bicubic_spline(), colfill(), colfill_randn(), colfill_randn_ni(), colfill_randu(), colfill_randu_ni(), colfill_seqadd(), colshift(), colsum(), column_value(), copy_status(), copy_value_to_vector(), cos(), cube(), param_init_matrix::curv_scale(), param_init_bounded_matrix::curv_scale(), det(), dvar_matrix_position::dvar_matrix_position(), elem_div(), elem_prod(), exp(), expm(), extract_column(), extract_diagonal(), extract_row(), fill(), fill_randn(), fill_randn_ni(), fill_randu(), fill_randu_ni(), fill_seqadd(), param_init_matrix::get_jacobian(), param_init_bounded_matrix::get_jacobian(), ln_det(), log(), matrix2vector(), param_init_matrix::mc_scale(), param_init_bounded_matrix::mc_scale(), nograd_assign_column(), nograd_assign_row(), norm(), norm2(), operator*(), operator+(), operator+=(), operator-(), operator-=(), operator<<(), operator=(), operator>>(), posfun(), pow(), read_from(), restore_value_from_vector(), banded_symmetric_dvar_matrix::rowmin(), banded_lower_triangular_dvar_matrix::rowmin(), rowshift(), rowsize(), rowsum(), DF_FILE::save_dvar_matrix_position(), DF_FILE::save_dvar_matrix_value(), param_init_matrix::sd_scale(), param_init_bounded_matrix::sd_scale(), param_init_matrix::sd_vscale(), param_init_bounded_matrix::sd_vscale(), param_init_matrix::set_simulation_bounds(), param_init_bounded_matrix::set_simulation_bounds(), set_value(), set_value_inv(), sin(), size_count(), size_count_partial(), solve(), sqr(), sqrt(), square(), sum(), symmetrize(), tan(), trace(), use_shape(), value(), write_on(), dll_param_init_matrix::~dll_param_init_matrix(), and dll_param_matrix::~dll_param_matrix().

void dvar_matrix::rowshift ( int  min)

Description not yet available.

Parameters

Definition at line 17 of file fvar_ma9.cpp.

Referenced by eigenvalues(), and eigenvectors().

unsigned int dvar_matrix::rowsize ( ) const
inline
void dvar_matrix::save_dvar_matrix_position ( ) const

Description not yet available.

Parameters

Definition at line 341 of file cmpdif5.cpp.

void dvar_matrix::save_dvar_matrix_value ( ) const

Saves the size, address, and value information for a dvar_matrix.

Definition at line 248 of file cmpdif4.cpp.

void dvar_matrix::shallow_copy ( const dvar_matrix other)

Shallow copy other data structure pointers.

Parameters
otherdvar3_array

Definition at line 459 of file fvar_mat.cpp.

Referenced by matrix_kludge::matrix_kludge(), operator=(), and sub().

dvar_matrix dvar_matrix::sub ( int  nrl,
int  nrh 
)

Description not yet available.

Parameters

Definition at line 153 of file fvar_mat.cpp.

void dvar_matrix::write_on ( const ostream &  _s) const

Description not yet available.

Parameters

Definition at line 49 of file fvarm_io.cpp.

Referenced by operator<<().

void dvar_matrix::write_on ( const uostream s) const

Write values from dvar_matrix to output stream s.

Parameters
soutput stream

Definition at line 80 of file fvarm1_i.cpp.

Friends And Related Function Documentation

friend class banded_lower_triangular_dmatrix
friend

Definition at line 2527 of file fvar.hpp.

Definition at line 2525 of file fvar.hpp.

friend class banded_symmetric_dmatrix
friend

Definition at line 2526 of file fvar.hpp.

friend class banded_symmetric_dvar_matrix
friend

Definition at line 2524 of file fvar.hpp.

void copy_status ( const ostream &  s,
const dvar_matrix m1 
)
friend

Description not yet available.

Parameters

Definition at line 584 of file fvar_mat.cpp.

dvariable det ( const dvar_matrix aa)
friend

Determinaant of matrix.

Parameters
aadvar_matrix containing a square matrix, $A$.
Returns
$\det(A)$.

The implementation of this algorithm was inspired by "Numerical Recipes in C", 2nd edition, Press, Teukolsky, Vetterling, Flannery, chapter 2

Edited by Steve Martell on Dec 30, 2013 to address a bug where the lower bound of the square dvar_matrix was greater than 1.

Definition at line 37 of file fvar_m20.cpp.

friend class dvar3_array
friend

Definition at line 2528 of file fvar.hpp.

friend class dvar_vector
friend

Definition at line 2594 of file fvar.hpp.

char* fform ( const char *  ,
const dvar_matrix  
)
friend
dvar_matrix inv ( const dvar_matrix aa)
friend

Inverse of a varaiable matrix.

Parameters
aadvar_matrix conaining matrix to be inverted, $A$.
Returns
dvar_matrix containing $A^{-1}$.

The implementation of this algorithm was inspired by "Numerical Recipes in C", 2nd edition, Press, Teukolsky, Vetterling, Flannery, chapter 2

Definition at line 43 of file fvar_m15.cpp.

dvariable ln_det ( const dvar_matrix aa,
int &  sgn 
)
friend



The implementation of this algorithm was inspired by "Numerical Recipes in C", 2nd edition, Press, Teukolsky, Vetterling, Flannery, chapter 2

dvariable norm ( const dvar_matrix m1)
friend

Description not yet available.

Parameters

Definition at line 67 of file fvar_ma3.cpp.

dvariable norm2 ( const dvar_matrix m1)
friend

Definition at line 98 of file fvar_ma3.cpp.

dvar_vector operator* ( const dvar_vector x,
const dvar_matrix m 
)
friend

Description not yet available.

Parameters

Definition at line 20 of file fvar_m23.cpp.

dvar_vector operator* ( const dvar_matrix m,
const dvar_vector x 
)
friend

Description not yet available.

Parameters

Definition at line 20 of file fvar_m22.cpp.

dvar_vector operator* ( const dvector x,
const dvar_matrix m 
)
friend

Description not yet available.

Parameters

Definition at line 17 of file fvar_ma1.cpp.

dvar_vector operator* ( const dvar_matrix m,
const dvector x 
)
friend

Description not yet available.

Parameters

Definition at line 19 of file fvar_m34.cpp.

dvar_matrix operator* ( const dvar_matrix m1,
const dvar_matrix m2 
)
friend

Description not yet available.

Parameters

Definition at line 83 of file fvar_m14.cpp.

dvar_matrix operator* ( const dvar_matrix m1,
const dmatrix cm2 
)
friend

Description not yet available.

Parameters

Definition at line 35 of file fvar_m19.cpp.

dvar_matrix operator* ( const dmatrix cm1,
const dvar_matrix m2 
)
friend

Description not yet available.

Parameters

Definition at line 32 of file fvar_m18.cpp.

dvar_matrix operator+ ( const dvar_matrix m1,
const dvar_matrix m2 
)
friend

Description not yet available.

Parameters

Definition at line 44 of file fvar_ma2.cpp.

dvar_matrix operator+ ( const dvar_matrix m1,
const dmatrix m2 
)
friend

Description not yet available.

Parameters

Definition at line 17 of file fvar_ma2.cpp.

dvar_matrix operator+ ( const dmatrix m1,
const dvar_matrix m2 
)
friend

Description not yet available.

Parameters

Definition at line 72 of file fvar_ma2.cpp.

dvar_matrix operator+ ( double  x,
const dvar_matrix m 
)
friend

Description not yet available.

Parameters

Definition at line 513 of file fvar_m27.cpp.

dvar_matrix operator+ ( const dvar_matrix m,
double  x 
)
friend

Description not yet available.

Parameters

Definition at line 557 of file fvar_m27.cpp.

dvar_matrix operator+ ( const dvariable x,
const dvar_matrix m 
)
friend

Description not yet available.

Parameters

Definition at line 579 of file fvar_m27.cpp.

dvar_matrix operator+ ( const dvar_matrix m,
const dvariable x 
)
friend

Description not yet available.

Parameters

Definition at line 601 of file fvar_m27.cpp.

dvar_matrix operator- ( double  x,
const dvar_matrix m 
)
friend

Description not yet available.

Parameters

Definition at line 667 of file fvar_m27.cpp.

dvar_matrix operator- ( const dvar_matrix m,
double  x 
)
friend

Description not yet available.

Parameters

Definition at line 645 of file fvar_m27.cpp.

dvar_matrix operator- ( const dvariable x,
const dvar_matrix m 
)
friend

Description not yet available.

Parameters

Definition at line 711 of file fvar_m27.cpp.

dvar_matrix operator- ( const dvar_matrix m,
const dvariable x 
)
friend

Description not yet available.

Parameters

Definition at line 689 of file fvar_m27.cpp.

dvar_matrix operator- ( const dvar_matrix m1,
const dvar_matrix m2 
)
friend

Description not yet available.

Parameters

Definition at line 57 of file fvar_m21.cpp.

dvar_matrix operator- ( const dvar_matrix m1,
const dmatrix m2 
)
friend

Description not yet available.

Parameters

Definition at line 17 of file fvar_m21.cpp.

dvar_matrix operator- ( const dmatrix m1,
const dvar_matrix m2 
)
friend

Description not yet available.

Parameters

Definition at line 97 of file fvar_m21.cpp.

dvariable sumsq ( const dvar_matrix m1)
friend

Definition at line 120 of file fvar_ma3.cpp.

dvar_matrix trans ( const dvar_matrix m1)
friend

Description not yet available.

Parameters

Definition at line 19 of file fvar_m44.cpp.

Member Data Documentation

int dvar_matrix::index_max
private
int dvar_matrix::index_min
private
dvar_vector* dvar_matrix::m
private
mat_shapex* dvar_matrix::shape
private

The documentation for this class was generated from the following files: