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 Types | Public Member Functions | Protected Member Functions | Private Attributes | Static Private Attributes | List of all members
lsst::afw::geom::ellipses::Quadrupole Class Reference

An ellipse core with quadrupole moments as parameters. More...

#include <Quadrupole.h>

Inheritance diagram for lsst::afw::geom::ellipses::Quadrupole:
lsst::afw::geom::ellipses::BaseCore

Public Types

enum  ParameterEnum { IXX =0, IYY =1, IXY =2 }
 
typedef boost::shared_ptr
< Quadrupole
Ptr
 
typedef boost::shared_ptr
< Quadrupole const > 
ConstPtr
 
typedef Eigen::Matrix< double,
2, 2, Eigen::DontAlign > 
Matrix
 Matrix type for the matrix representation of Quadrupole parameters. More...
 
- Public Types inherited from lsst::afw::geom::ellipses::BaseCore
typedef boost::shared_ptr
< BaseCore
Ptr
 
typedef boost::shared_ptr
< BaseCore const > 
ConstPtr
 
typedef Eigen::Vector3d ParameterVector
 Parameter vector type. More...
 
typedef Eigen::Matrix3d Jacobian
 Parameter Jacobian matrix type. More...
 

Public Member Functions

double const getIxx () const
 
void setIxx (double ixx)
 
double const getIyy () const
 
void setIyy (double iyy)
 
double const getIxy () const
 
void setIxy (double ixy)
 
Ptr clone () const
 Deep copy the ellipse core. More...
 
virtual std::string getName () const
 Return a string that identifies this parametrization. More...
 
virtual void normalize ()
 Put the parameters into a "standard form", and throw InvalidEllipseParameters if they cannot be normalized. More...
 
virtual void readParameters (double const *iter)
 
virtual void writeParameters (double *iter) const
 
Matrix const & getMatrix () const
 Return a 2x2 symmetric matrix of the parameters. More...
 
double getDeterminant () const
 Return the determinant of the matrix representation. More...
 
Quadrupoleoperator= (Quadrupole const &other)
 Standard assignment. More...
 
Quadrupoleoperator= (BaseCore const &other)
 Converting assignment. More...
 
 Quadrupole (double ixx=1.0, double iyy=1.0, double ixy=0.0, bool normalize=false)
 Construct from parameter values. More...
 
 Quadrupole (BaseCore::ParameterVector const &vector, bool normalize=false)
 Construct from a parameter vector. More...
 
 Quadrupole (Matrix const &matrix, bool normalize=true)
 Construct from a 2x2 matrix. More...
 
 Quadrupole (Quadrupole const &other)
 Copy constructor. More...
 
 Quadrupole (BaseCore const &other)
 Converting copy constructor. More...
 
 Quadrupole (BaseCore::Transformer const &transformer)
 Converting copy constructor. More...
 
 Quadrupole (BaseCore::Convolution const &convolution)
 Converting copy constructor. More...
 
- Public Member Functions inherited from lsst::afw::geom::ellipses::BaseCore
Ptr clone () const
 Deep-copy the Core. More...
 
void grow (double buffer)
 Increase the major and minor radii of the ellipse core by the given buffer. More...
 
void scale (double factor)
 Scale the size of the ellipse core by the given factor. More...
 
double getArea () const
 Return the area of the ellipse core. More...
 
double getDeterminantRadius () const
 Return the radius defined as the 4th root of the determinant of the quadrupole matrix. More...
 
double getTraceRadius () const
 Return the radius defined as the square root of one half the trace of the quadrupole matrix. More...
 
GridTransform const getGridTransform () const
 Return the transform that maps the ellipse to the unit circle. More...
 
Extent2D computeDimensions () const
 Return the size of the bounding box for the ellipse core. More...
 
ParameterVector const getParameterVector () const
 Return the core parameters as a vector. More...
 
void setParameterVector (ParameterVector const &vector)
 Set the core parameters from a vector. More...
 
bool operator== (BaseCore const &other) const
 Compare two ellipse cores for equality. More...
 
bool operator!= (BaseCore const &other) const
 Compare two ellipse cores for inequality. More...
 
BaseCoreoperator= (BaseCore const &other)
 Set the parameters of this ellipse core from another. More...
 
Jacobian dAssign (BaseCore const &other)
 Assign other to this and return the derivative of the conversion, d(this)/d(other). More...
 
template<typename Output >
Converter< Output > as () const
 Convert this to the core type specified as a template parameter. More...
 
virtual ~BaseCore ()
 
Transformer transform (LinearTransform const &transform)
 
Transformer const transform (LinearTransform const &transform) const
 
Convolution convolve (BaseCore const &other)
 
Convolution const convolve (BaseCore const &other) const
 

Protected Member Functions

virtual BaseCore::Ptr _clone () const
 
virtual void _assignToQuadrupole (double &ixx, double &iyy, double &ixy) const
 
virtual void _assignFromQuadrupole (double ixx, double iyy, double ixy)
 
virtual void _assignToAxes (double &a, double &b, double &theta) const
 
virtual void _assignFromAxes (double a, double b, double theta)
 
virtual Jacobian _dAssignToQuadrupole (double &ixx, double &iyy, double &ixy) const
 
virtual Jacobian _dAssignFromQuadrupole (double ixx, double iyy, double ixy)
 
virtual Jacobian _dAssignToAxes (double &a, double &b, double &theta) const
 
virtual Jacobian _dAssignFromAxes (double a, double b, double theta)
 

Private Attributes

Matrix _matrix
 

Static Private Attributes

static Registrar< Quadrupoleregistrar
 

Additional Inherited Members

- Static Public Member Functions inherited from lsst::afw::geom::ellipses::BaseCore
static Ptr make (std::string const &name)
 
static Ptr make (std::string const &name, ParameterVector const &parameters)
 
static Ptr make (std::string const &name, double v1, double v2, double v3)
 
static Ptr make (std::string const &name, BaseCore const &other)
 
static Ptr make (std::string const &name, Transformer const &other)
 
static Ptr make (std::string const &name, Convolution const &other)
 
- Static Protected Member Functions inherited from lsst::afw::geom::ellipses::BaseCore
static void registerSubclass (Ptr const &example)
 
static void _assignQuadrupoleToAxes (double ixx, double iyy, double ixy, double &a, double &b, double &theta)
 
static Jacobian _dAssignQuadrupoleToAxes (double ixx, double iyy, double ixy, double &a, double &b, double &theta)
 
static void _assignAxesToQuadrupole (double a, double b, double theta, double &ixx, double &iyy, double &ixy)
 
static Jacobian _dAssignAxesToQuadrupole (double a, double b, double theta, double &ixx, double &iyy, double &ixy)
 

Detailed Description

An ellipse core with quadrupole moments as parameters.

Definition at line 45 of file Quadrupole.h.

Member Typedef Documentation

Definition at line 49 of file Quadrupole.h.

typedef Eigen::Matrix<double,2,2,Eigen::DontAlign> lsst::afw::geom::ellipses::Quadrupole::Matrix

Matrix type for the matrix representation of Quadrupole parameters.

Definition at line 54 of file Quadrupole.h.

Definition at line 48 of file Quadrupole.h.

Member Enumeration Documentation

Constructor & Destructor Documentation

lsst::afw::geom::ellipses::Quadrupole::Quadrupole ( double  ixx = 1.0,
double  iyy = 1.0,
double  ixy = 0.0,
bool  normalize = false 
)
explicit

Construct from parameter values.

lsst::afw::geom::ellipses::Quadrupole::Quadrupole ( BaseCore::ParameterVector const &  vector,
bool  normalize = false 
)
explicit

Construct from a parameter vector.

lsst::afw::geom::ellipses::Quadrupole::Quadrupole ( Matrix const &  matrix,
bool  normalize = true 
)
explicit

Construct from a 2x2 matrix.

lsst::afw::geom::ellipses::Quadrupole::Quadrupole ( Quadrupole const &  other)
inline

Copy constructor.

Definition at line 103 of file Quadrupole.h.

103 : _matrix(other._matrix) {}
lsst::afw::geom::ellipses::Quadrupole::Quadrupole ( BaseCore const &  other)
inline

Converting copy constructor.

Definition at line 106 of file Quadrupole.h.

106 { *this = other; }
lsst::afw::geom::ellipses::Quadrupole::Quadrupole ( BaseCore::Transformer const &  transformer)
inline

Converting copy constructor.

Definition at line 109 of file Quadrupole.h.

109  {
110  transformer.apply(*this);
111  }
lsst::afw::geom::ellipses::Quadrupole::Quadrupole ( BaseCore::Convolution const &  convolution)
inline

Converting copy constructor.

Definition at line 114 of file Quadrupole.h.

114  {
115  convolution.apply(*this);
116  }

Member Function Documentation

virtual void lsst::afw::geom::ellipses::Quadrupole::_assignFromAxes ( double  a,
double  b,
double  theta 
)
protectedvirtual
virtual void lsst::afw::geom::ellipses::Quadrupole::_assignFromQuadrupole ( double  ixx,
double  iyy,
double  ixy 
)
protectedvirtual
virtual void lsst::afw::geom::ellipses::Quadrupole::_assignToAxes ( double &  a,
double &  b,
double &  theta 
) const
protectedvirtual
virtual void lsst::afw::geom::ellipses::Quadrupole::_assignToQuadrupole ( double &  ixx,
double &  iyy,
double &  ixy 
) const
protectedvirtual
virtual BaseCore::Ptr lsst::afw::geom::ellipses::Quadrupole::_clone ( ) const
inlineprotectedvirtual

Implements lsst::afw::geom::ellipses::BaseCore.

Definition at line 120 of file Quadrupole.h.

120 { return boost::make_shared<Quadrupole>(*this); }
virtual Jacobian lsst::afw::geom::ellipses::Quadrupole::_dAssignFromAxes ( double  a,
double  b,
double  theta 
)
protectedvirtual
virtual Jacobian lsst::afw::geom::ellipses::Quadrupole::_dAssignFromQuadrupole ( double  ixx,
double  iyy,
double  ixy 
)
protectedvirtual
virtual Jacobian lsst::afw::geom::ellipses::Quadrupole::_dAssignToAxes ( double &  a,
double &  b,
double &  theta 
) const
protectedvirtual
virtual Jacobian lsst::afw::geom::ellipses::Quadrupole::_dAssignToQuadrupole ( double &  ixx,
double &  iyy,
double &  ixy 
) const
protectedvirtual
Ptr lsst::afw::geom::ellipses::Quadrupole::clone ( ) const
inline

Deep copy the ellipse core.

Definition at line 66 of file Quadrupole.h.

66 { return boost::static_pointer_cast<Quadrupole>(_clone()); }
Quadrupole(double ixx=1.0, double iyy=1.0, double ixy=0.0, bool normalize=false)
Construct from parameter values.
virtual BaseCore::Ptr _clone() const
Definition: Quadrupole.h:120
double lsst::afw::geom::ellipses::Quadrupole::getDeterminant ( ) const
inline

Return the determinant of the matrix representation.

Definition at line 85 of file Quadrupole.h.

85 { return getIxx() * getIyy() - getIxy() * getIxy(); }
double const getIxy() const
Definition: Quadrupole.h:62
double const getIyy() const
Definition: Quadrupole.h:59
double const getIxx() const
Definition: Quadrupole.h:56
double const lsst::afw::geom::ellipses::Quadrupole::getIxx ( ) const
inline

Definition at line 56 of file Quadrupole.h.

56 { return _matrix(0, 0); }
double const lsst::afw::geom::ellipses::Quadrupole::getIxy ( ) const
inline

Definition at line 62 of file Quadrupole.h.

62 { return _matrix(1, 0); }
double const lsst::afw::geom::ellipses::Quadrupole::getIyy ( ) const
inline

Definition at line 59 of file Quadrupole.h.

59 { return _matrix(1, 1); }
Matrix const& lsst::afw::geom::ellipses::Quadrupole::getMatrix ( ) const
inline

Return a 2x2 symmetric matrix of the parameters.

Definition at line 82 of file Quadrupole.h.

virtual std::string lsst::afw::geom::ellipses::Quadrupole::getName ( ) const
virtual

Return a string that identifies this parametrization.

Implements lsst::afw::geom::ellipses::BaseCore.

virtual void lsst::afw::geom::ellipses::Quadrupole::normalize ( )
virtual

Put the parameters into a "standard form", and throw InvalidEllipseParameters if they cannot be normalized.

Implements lsst::afw::geom::ellipses::BaseCore.

Quadrupole& lsst::afw::geom::ellipses::Quadrupole::operator= ( Quadrupole const &  other)
inline

Standard assignment.

Definition at line 88 of file Quadrupole.h.

88 { _matrix = other._matrix; return *this; }
Quadrupole& lsst::afw::geom::ellipses::Quadrupole::operator= ( BaseCore const &  other)
inline

Converting assignment.

Definition at line 91 of file Quadrupole.h.

91 { BaseCore::operator=(other); return *this; }
BaseCore & operator=(BaseCore const &other)
Set the parameters of this ellipse core from another.
virtual void lsst::afw::geom::ellipses::Quadrupole::readParameters ( double const *  iter)
virtual
void lsst::afw::geom::ellipses::Quadrupole::setIxx ( double  ixx)
inline

Definition at line 57 of file Quadrupole.h.

57 { _matrix(0, 0) = ixx; }
void lsst::afw::geom::ellipses::Quadrupole::setIxy ( double  ixy)
inline

Definition at line 63 of file Quadrupole.h.

63 { _matrix(0, 1) = _matrix(1, 0) = ixy; }
void lsst::afw::geom::ellipses::Quadrupole::setIyy ( double  iyy)
inline

Definition at line 60 of file Quadrupole.h.

60 { _matrix(1, 1) = iyy; }
virtual void lsst::afw::geom::ellipses::Quadrupole::writeParameters ( double *  iter) const
virtual

Member Data Documentation

Matrix lsst::afw::geom::ellipses::Quadrupole::_matrix
private

Definition at line 137 of file Quadrupole.h.

Registrar<Quadrupole> lsst::afw::geom::ellipses::Quadrupole::registrar
staticprivate

Definition at line 135 of file Quadrupole.h.


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