OpenStructure
Public Member Functions | Protected Member Functions | Protected Attributes
Phase Class Reference

#include <phase.hh>

Inherits equality_comparable< Phase >, additive< Phase >, and multiplicative< Phase, Real >.

Public Member Functions

 Phase ()
 
 Phase (Real angle)
 
 Phase (Complex comp)
 
 operator Real () const
 
const Phase operator+= (const Phase &rhs)
 
const Phase operator-= (const Phase &rhs)
 
Phase operator- () const
 
const Phase operator*= (Real d)
 
const Phase operator/= (Real d)
 

Protected Member Functions

Real reduce (Real in)
 

Protected Attributes

Real angle_
 

Detailed Description

Manages phases og Complex numbers.

Manages phases of Complex numbers, and allows sums and subtractions of phases. Takes correctly into account phase periodicity

See also
View Phase Difference Example

Definition at line 41 of file phase.hh.

Constructor & Destructor Documentation

◆ Phase() [1/3]

Phase ( )
inline

Definition at line 47 of file phase.hh.

◆ Phase() [2/3]

Phase ( Real  angle)

◆ Phase() [3/3]

Phase ( Complex  comp)

Member Function Documentation

◆ operator Real()

operator Real ( ) const

◆ operator*=()

const Phase operator*= ( Real  d)

multipliable

◆ operator+=()

const Phase operator+= ( const Phase rhs)

addable op

◆ operator-()

Phase operator- ( ) const

negateable

◆ operator-=()

const Phase operator-= ( const Phase rhs)

subtractable op

◆ operator/=()

const Phase operator/= ( Real  d)

dividable

◆ reduce()

Real reduce ( Real  in)
protected

Field Documentation

◆ angle_

Real angle_
protected

Definition at line 63 of file phase.hh.


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