MipBaselib::Gaussian Class Reference
[Probability Density Functions (PDF) and Hypotesis Densities (PHD)]

Provides a class to represent the generic 2D Gaussian pdf. More...

#include <Gaussian.h>

Inheritance diagram for MipBaselib::Gaussian:

MipBaselib::PDF MipBaselib::GaussianComponent MipBaselib::GaussianComponentID MipBaselib::GaussianComponentJointDiscrete

List of all members.

Public Member Functions

 Gaussian ()
 Default Constructor.
 Gaussian (DCol m, DMat &c)
 Complete Constructor.
 Gaussian (const Gaussian &g)
 Copy Constructor.
int dim ()
 Gets the dimension.
void operator= (const Gaussian &g)
 Operator =.
DCol expectedValue ()
 Returns the expected value.
DCol expectedValue (const int n)
 Returns the first n elements of the expected value.
Decimal covariance (int row, int col)
 Returns the (row-th, col-th) element of the covariance matrix.
DMatcovariance ()
 Returns the covariance matrix as a vector of vector with the appropriate size.
DMat covariance (const int n) const
 Returns the covariance matrix of the first n elements of the random vector.
Decimal evaluate (DCol p)
 Returns the the value of the pdf in the given position.
Gaussian marginalize (int n)
 Returns a Gaussian marginalized to the first n random variables.
void printCovInv ()
 Print the invese of the covariance.
virtual string print ()
 Returns the the value of the pdf in the given position.

Protected Member Functions

void _computeCovInv ()

Protected Attributes

DCol _mean
DMat _cov
DMat _covInv
bool _covInvComputed


Detailed Description

Provides a class to represent the generic 2D Gaussian pdf.

Author:
Paolo Stegagno

Constructor & Destructor Documentation

MipBaselib::Gaussian::Gaussian (  ) 

Default Constructor.

MipBaselib::Gaussian::Gaussian ( DCol  m,
DMat c 
)

Complete Constructor.

Parameters:
[in] m Mean, default (0 0)'.
[in] &c Pointer to a covariance matrix, default (1 0; 0 1) when c==NULL.

MipBaselib::Gaussian::Gaussian ( const Gaussian g  ) 

Copy Constructor.

Parameters:
[in] &g Copied Gaussian.


Member Function Documentation

void MipBaselib::Gaussian::_computeCovInv (  )  [protected]

int MipBaselib::Gaussian::dim (  ) 

Gets the dimension.

void MipBaselib::Gaussian::operator= ( const Gaussian g  ) 

Operator =.

Parameters:
[in] &g Copied Gaussian.

DCol MipBaselib::Gaussian::expectedValue (  )  [virtual]

Returns the expected value.

Implements MipBaselib::PDF.

DCol MipBaselib::Gaussian::expectedValue ( const int  n  ) 

Returns the first n elements of the expected value.

Parameters:
[in] n Number of requested elements.

Decimal MipBaselib::Gaussian::covariance ( int  row,
int  col 
) [virtual]

Returns the (row-th, col-th) element of the covariance matrix.

Parameters:
[in] row Requested row.
[in] col Requested column.

Implements MipBaselib::PDF.

DMat & MipBaselib::Gaussian::covariance (  ) 

Returns the covariance matrix as a vector of vector with the appropriate size.

DMat MipBaselib::Gaussian::covariance ( const int  n  )  const

Returns the covariance matrix of the first n elements of the random vector.

Decimal MipBaselib::Gaussian::evaluate ( DCol  p  )  [virtual]

Returns the the value of the pdf in the given position.

Parameters:
[in] col Requested position.

Implements MipBaselib::PDF.

Gaussian MipBaselib::Gaussian::marginalize ( int  n  ) 

Returns a Gaussian marginalized to the first n random variables.

Parameters:
[in] n Requested number of components.

void MipBaselib::Gaussian::printCovInv (  ) 

Print the invese of the covariance.

Parameters:
[in] col Requested position.

string MipBaselib::Gaussian::print (  )  [virtual]

Returns the the value of the pdf in the given position.

Parameters:
[in] col Requested position.

Reimplemented in MipBaselib::GaussianComponent.


Member Data Documentation


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

Generated on Mon Feb 20 07:01:11 2017 for MIP by  doxygen 1.5.6