LSSTApplications  10.0+286,10.0+36,10.0+46,10.0-2-g4f67435,10.1+152,10.1+37,11.0,11.0+1,11.0-1-g47edd16,11.0-1-g60db491,11.0-1-g7418c06,11.0-2-g04d2804,11.0-2-g68503cd,11.0-2-g818369d,11.0-2-gb8b8ce7
LSSTDataManagementBasePackage
Public Member Functions | Private Attributes | List of all members
lsst::afw::math::SquaredExpCovariogram< T > Class Template Reference

a Covariogram that falls off as the negative exponent of the square of the distance between the points More...

#include <GaussianProcess.h>

Inheritance diagram for lsst::afw::math::SquaredExpCovariogram< T >:
lsst::afw::math::Covariogram< T > lsst::daf::base::Citizen

Public Member Functions

virtual ~SquaredExpCovariogram ()
 
 SquaredExpCovariogram ()
 
void setEllSquared (double ellSquared)
 set the _ellSquared hyper parameter (the square of the characteristic length scale of the covariogram) More...
 
virtual T operator() (ndarray::Array< const T, 1, 1 > const &, ndarray::Array< const T, 1, 1 > const &) const
 Actually evaluate the covariogram function relating two points you want to interpolate from. More...
 
- Public Member Functions inherited from lsst::afw::math::Covariogram< T >
virtual ~Covariogram ()
 
 Covariogram ()
 construct a Covariogram assigning default values to the hyper parameters More...
 
- Public Member Functions inherited from lsst::daf::base::Citizen
 Citizen (const std::type_info &)
 
 Citizen (Citizen const &)
 
 ~Citizen ()
 
Citizenoperator= (Citizen const &)
 
std::string repr () const
 Return a string representation of a Citizen. More...
 
void markPersistent (void)
 Mark a Citizen as persistent and not destroyed until process end. More...
 
memId getId () const
 Return the Citizen's ID. More...
 

Private Attributes

double _ellSquared
 

Additional Inherited Members

- Public Types inherited from lsst::daf::base::Citizen
enum  { magicSentinel = 0xdeadbeef }
 
typedef unsigned long memId
 Type of the block's ID. More...
 
typedef memId(* memNewCallback )(const memId cid)
 A function used to register a callback. More...
 
typedef memId(* memCallback )(const Citizen *ptr)
 
- Static Public Member Functions inherited from lsst::daf::base::Citizen
static bool hasBeenCorrupted ()
 Check all allocated blocks for corruption. More...
 
static memId getNextMemId ()
 Return the memId of the next object to be allocated. More...
 
static int init ()
 Called once when the memory system is being initialised. More...
 
static int census (int, memId startingMemId=0)
 How many active Citizens are there? More...
 
static void census (std::ostream &stream, memId startingMemId=0)
 Print a list of all active Citizens to stream, sorted by ID. More...
 
static const std::vector
< const Citizen * > * 
census ()
 Return a (newly allocated) std::vector of active Citizens sorted by ID. More...
 
static memId setNewCallbackId (memId id)
 Call the NewCallback when block is allocated. More...
 
static memId setDeleteCallbackId (memId id)
 Call the current DeleteCallback when block is deleted. More...
 
static memNewCallback setNewCallback (memNewCallback func)
 Set the NewCallback function. More...
 
static memCallback setDeleteCallback (memCallback func)
 Set the DeleteCallback function. More...
 
static memCallback setCorruptionCallback (memCallback func)
 Set the CorruptionCallback function. More...
 

Detailed Description

template<typename T>
class lsst::afw::math::SquaredExpCovariogram< T >

a Covariogram that falls off as the negative exponent of the square of the distance between the points

Contains one hyper parameter (_ellSquared) encoding the square of the characteristic length scale of the covariogram

Definition at line 168 of file GaussianProcess.h.

Constructor & Destructor Documentation

template<typename T >
lsst::afw::math::SquaredExpCovariogram< T >::~SquaredExpCovariogram ( )
virtual

Definition at line 1833 of file GaussianProcess.cc.

1833 {}
template<typename T >
lsst::afw::math::SquaredExpCovariogram< T >::SquaredExpCovariogram ( )
explicit

Definition at line 1836 of file GaussianProcess.cc.

1837 {
1838  _ellSquared = 1.0;
1839 }

Member Function Documentation

template<typename T >
T lsst::afw::math::SquaredExpCovariogram< T >::operator() ( ndarray::Array< const T, 1, 1 > const &  p1,
ndarray::Array< const T, 1, 1 > const &  p2 
) const
virtual

Actually evaluate the covariogram function relating two points you want to interpolate from.

Parameters
[in]p1the first point
[in]p2the second point

Reimplemented from lsst::afw::math::Covariogram< T >.

Definition at line 1848 of file GaussianProcess.cc.

1850 {
1851  int i;
1852  T d;
1853  d = 0.0;
1854  for(i = 0; i < p1.template getSize < 0 > (); i++ ){
1855  d += (p1[i] - p2[i])*(p1[i] - p2[i]);
1856  }
1857 
1858  d = d/_ellSquared;
1859  return T(exp( - 0.5*d));
1860 }
template<typename T >
void lsst::afw::math::SquaredExpCovariogram< T >::setEllSquared ( double  ellSquared)

set the _ellSquared hyper parameter (the square of the characteristic length scale of the covariogram)

Definition at line 1842 of file GaussianProcess.cc.

1843 {
1844  _ellSquared = ellSquared;
1845 }

Member Data Documentation

template<typename T >
double lsst::afw::math::SquaredExpCovariogram< T >::_ellSquared
private

Definition at line 186 of file GaussianProcess.h.


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