lsst.gauss2d gbf99507273+afb4790f61
 
Loading...
Searching...
No Matches
lsst::gauss2d::EllipseMajor Class Reference

An Ellipse with r_major, axrat and angle values. More...

#include <ellipse.h>

Inheritance diagram for lsst::gauss2d::EllipseMajor:
lsst::gauss2d::Object

Public Member Functions

 EllipseMajor (double r_major, double axrat, double angle, bool degrees=false)
 Construct a new EllipseMajor object with default float values.
 
 EllipseMajor (const Covariance &covar, bool degrees=false)
 
 EllipseMajor (const Ellipse &ellipse, bool degrees=false)
 
double get_area () const
 Return the area of this ellipse, equal to pi*sigma_major*sigma_minor.
 
double get_r_major () const
 Get the major axis length.
 
double get_axrat () const
 Get the axis ratio.
 
double get_angle () const
 Get the position angle in the configured units.
 
double get_angle_degrees () const
 Get the position angle in degrees.
 
double get_angle_radians () const
 Get the position angle in radians.
 
std::array< double, 3 > get_rqa () const
 Get the array of r_major, axrat, angle.
 
bool is_degrees () const
 Return if the units are degrees (true) or radians (false)
 
void set (double r_major, double axrat, double angle)
 
void set_r_major (double r_major)
 
void set_axrat (double axrat)
 
void set_angle (double angle)
 
void set_degrees (bool degrees)
 
void set_rqa (const std::array< double, 3 > &rqa)
 
std::string repr (bool name_keywords=false, std::string_view namespace_separator=Object::CC_NAMESPACE_SEPARATOR) const override
 
std::string str () const override
 Return a brief, human-readable string representation of this.
 
bool operator== (const EllipseMajor &other) const
 
bool operator!= (const EllipseMajor &other) const
 

Static Public Member Functions

static void check (double r_major, double axrat, double angle)
 Check whether the supplied values are valid, throwing if not.
 
- Static Public Member Functions inherited from lsst::gauss2d::Object
static std::string_view null_str (const std::string_view &namespace_separator)
 

Additional Inherited Members

- Static Public Attributes inherited from lsst::gauss2d::Object
static constexpr std::string_view CC_NAMESPACE_SEPARATOR = "::"
 The C++ namespace separator.
 
static constexpr std::string_view NULL_STR_GENERAL = "None"
 
static constexpr std::string_view PY_NAMESPACE_SEPARATOR = "."
 

Detailed Description

An Ellipse with r_major, axrat and angle values.

This ellipse representation is intended for intermediate calculations and does not use an abstract Data class. r_major must be >= 0, and 0 <= axrat <= 1.

Constructor & Destructor Documentation

◆ EllipseMajor()

lsst::gauss2d::EllipseMajor::EllipseMajor ( double r_major,
double axrat,
double angle,
bool degrees = false )
explicit

Construct a new EllipseMajor object with default float values.

Parameters
r_majorThe initial r_major value
axratThe initial axrat value
angleThe intial angle value
degreesWhether the angle unit is degrees (true) or radians (false)

Member Function Documentation

◆ repr()

std::string lsst::gauss2d::EllipseMajor::repr ( bool name_keywords = false,
std::string_view namespace_separator = Object::CC_NAMESPACE_SEPARATOR ) const
overridevirtual

Return a full, callable string representation of this.

Parameters
name_keywordsWhether to prefix arguments with "{name}=", where name is the arg name in the header (as with keyword arguments in Python).
namespace_separatorThe string to use to delimit namespaces, i.e. :: in C++ and . in Python.
Returns
A callable string representation of this, which should return an an identical object to this.
Note
The representation with name_keywords=false must be callable in C++. The representation with name_keywords=true should be callable in Python, if there are any bindings.

Implements lsst::gauss2d::Object.

◆ str()

std::string lsst::gauss2d::EllipseMajor::str ( ) const
overridevirtual

Return a brief, human-readable string representation of this.

Implements lsst::gauss2d::Object.


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