Belle II Software  release-08-01-10
ThetaAngle Class Reference

#include <Angle.h>

Inheritance diagram for ThetaAngle:
Collaboration diagram for ThetaAngle:

Public Member Functions

 ThetaAngle (double angle, double error)
 Constructor using radian units. More...
 
bool contains (const ThetaAngle &angle) const
 Check if two angles are compatible. More...
 
bool containsIn (const ThetaAngle &angle, double sigma) const
 Check if two angles are compatible. More...
 
double getAngle () const
 Getter for the angle.
 
double getError () const
 Getter for the error of the angle.
 
double getAngleInDeg () const
 Getter for angle in degrees.
 
double getErrorInDeg () const
 Getter for the error of the angle in degrees.
 
double getLowerIntervalBoundary (double sigma=1) const
 Getter for the lower interval bound: angle-sigma*error. More...
 
double getUpperIntervalBoundary (double sigma=1) const
 Getter for the upper interval bound: angle+sigma*error. More...
 

Protected Types

typedef std::pair< double, double > Interval
 Shortcut for std::pair used as interval.
 

Protected Member Functions

bool intervalsCompatible (const Interval &x_interval, const Interval &y_interval) const
 Checks if the intervals overlap at some point. More...
 

Protected Attributes

double m_angle
 Angle in rad.
 
double m_error
 Error in rad.
 

Detailed Description

See also
BaseAngle Theta specific.

Definition at line 105 of file Angle.h.

Constructor & Destructor Documentation

◆ ThetaAngle()

ThetaAngle ( double  angle,
double  error 
)
inline

Constructor using radian units.

Theta in [0, Pi)

Parameters
angletheta angle to use
errorerror on the angle

Definition at line 113 of file Angle.h.

Member Function Documentation

◆ contains()

bool contains ( const ThetaAngle angle) const
inline

Check if two angles are compatible.

Parameters
anglesecond angle to compare to
Returns
true if within one standard deviation

Definition at line 122 of file Angle.h.

◆ containsIn()

bool containsIn ( const ThetaAngle angle,
double  sigma 
) const
inline

Check if two angles are compatible.

Parameters
anglesecond angle to compare to
sigmawidth of the error band in standard deviations
Returns
true if within sigma standard deviations

Definition at line 132 of file Angle.h.

◆ getLowerIntervalBoundary()

double getLowerIntervalBoundary ( double  sigma = 1) const
inlineinherited

Getter for the lower interval bound: angle-sigma*error.

Parameters
sigmawidth of the error interval in standard deviations
Returns
angle - sigma * error

Definition at line 55 of file Angle.h.

◆ getUpperIntervalBoundary()

double getUpperIntervalBoundary ( double  sigma = 1) const
inlineinherited

Getter for the upper interval bound: angle+sigma*error.

Parameters
sigmawidth of the error interval in standard deviations
Returns
angle + sigma * error

Definition at line 61 of file Angle.h.

◆ intervalsCompatible()

bool intervalsCompatible ( const Interval x_interval,
const Interval y_interval 
) const
inlineprotectedinherited

Checks if the intervals overlap at some point.

If comparing phi angles, be sure to have the interval in a way this function can handle it, meaning always between [0, 2pi).

Parameters
x_intervalfirst interval to check
y_intervalsecond interval
Returns
true if x and y overlap

Definition at line 76 of file Angle.h.


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