LSSTApplications  10.0-2-g4f67435,11.0.rc2+1,11.0.rc2+12,11.0.rc2+3,11.0.rc2+4,11.0.rc2+5,11.0.rc2+6,11.0.rc2+7,11.0.rc2+8
LSSTDataManagementBasePackage
Public Types | Public Member Functions | Private Attributes | List of all members
lsst.afw.math::ApproximateControl Class Reference

Control how to make an approximation. More...

#include <Approximate.h>

Public Types

enum  Style { UNKNOWN = -1, CHEBYSHEV, NUM_STYLES }
 Choose the type of approximation to use. More...
 

Public Member Functions

 ApproximateControl (Style style, int orderX, int orderY=-1, bool weighting=true)
 ctor More...
 
Style getStyle () const
 Return the Style. More...
 
void setStyle (Style const style)
 Set the Style. More...
 
int getOrderX () const
 Return the order of approximation to use in the x-direction. More...
 
void setOrderX (int const orderX)
 Set the order of approximation to use in the x-direction. More...
 
int getOrderY () const
 Return the order of approximation to use in the y-direction. More...
 
void setOrderY (int const orderY)
 Set the order of approximation to use in the y-direction. More...
 
bool getWeighting () const
 Return whether inverse variance weighting will be used in calculation. More...
 
void setWeighting (bool const weighting)
 Set whether inverse variance weighting will be used in calculation. More...
 

Private Attributes

Style _style
 
int _orderX
 
int _orderY
 
bool _weighting
 

Detailed Description

Control how to make an approximation.

Note
the x- and y-order must be the same, due to a limitation of Chebyshev1Function2

Definition at line 47 of file Approximate.h.

Member Enumeration Documentation

Choose the type of approximation to use.

Enumerator
UNKNOWN 
CHEBYSHEV 

Use a 2-D Chebyshev polynomial.

NUM_STYLES 

Definition at line 50 of file Approximate.h.

Constructor & Destructor Documentation

lsst.afw.math::ApproximateControl::ApproximateControl ( Style  style,
int  orderX,
int  orderY = -1,
bool  weighting = true 
)

ctor

Parameters
styleType of approximation
orderXOrder of approximation to use in x-direction
orderYOrder of approximation to use in y-direction
weightingUse inverse variance weighting?

Definition at line 48 of file Approximate.cc.

52  :
53  _style(style), _orderX(orderX), _orderY(orderY < 0 ? orderX : orderY), _weighting(weighting) {
54  if (_orderX != _orderY) {
55  throw LSST_EXCEPT(lsst::pex::exceptions::InvalidParameterError,
56  str(boost::format("X- and Y-orders must be equal (%d != %d) "
57  "due to a limitation in math::Chebyshev1Function2")
58  % _orderX % _orderY));
59  }
60 }
#define LSST_EXCEPT(type,...)
Definition: Exception.h:46
table::Key< int > orderX

Member Function Documentation

int lsst.afw.math::ApproximateControl::getOrderX ( ) const
inline

Return the order of approximation to use in the x-direction.

Definition at line 62 of file Approximate.h.

int lsst.afw.math::ApproximateControl::getOrderY ( ) const
inline

Return the order of approximation to use in the y-direction.

Definition at line 66 of file Approximate.h.

Style lsst.afw.math::ApproximateControl::getStyle ( ) const
inline

Return the Style.

Definition at line 58 of file Approximate.h.

58 { return _style; }
bool lsst.afw.math::ApproximateControl::getWeighting ( ) const
inline

Return whether inverse variance weighting will be used in calculation.

Definition at line 70 of file Approximate.h.

void lsst.afw.math::ApproximateControl::setOrderX ( int const  orderX)
inline

Set the order of approximation to use in the x-direction.

Definition at line 64 of file Approximate.h.

64 { _orderX = orderX; }
table::Key< int > orderX
void lsst.afw.math::ApproximateControl::setOrderY ( int const  orderY)
inline

Set the order of approximation to use in the y-direction.

Definition at line 68 of file Approximate.h.

68 { _orderY = orderY; }
void lsst.afw.math::ApproximateControl::setStyle ( Style const  style)
inline

Set the Style.

Definition at line 60 of file Approximate.h.

60 { _style = style; }
void lsst.afw.math::ApproximateControl::setWeighting ( bool const  weighting)
inline

Set whether inverse variance weighting will be used in calculation.

Definition at line 72 of file Approximate.h.

72 { _weighting = weighting; }

Member Data Documentation

int lsst.afw.math::ApproximateControl::_orderX
private

Definition at line 75 of file Approximate.h.

int lsst.afw.math::ApproximateControl::_orderY
private

Definition at line 76 of file Approximate.h.

Style lsst.afw.math::ApproximateControl::_style
private

Definition at line 74 of file Approximate.h.

bool lsst.afw.math::ApproximateControl::_weighting
private

Definition at line 77 of file Approximate.h.


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