# AngTwoPi Class Reference

Circular arithmetic on angles between 0 and two pi (360 degrees). More...

`#include <Measures.h>`

## Detailed Description

Circular arithmetic on angles between 0 and two pi (360 degrees).

Definition at line 74 of file Measures.h.

List of all members.

## Public Member Functions

AngTwoPi (void)
AngTwoPi (direction_t const &v)
constructor, value defaults to 0
AngTwoPi operator+ (AngTwoPi const &arg) const
AngTwoPi operator- (AngTwoPi const &arg) const
AngTwoPi operator* (direction_t const &arg) const
AngTwoPi operator/ (direction_t const &arg) const
AngTwoPioperator= (AngTwoPi const &arg)
AngTwoPioperator= (direction_t const &arg)
AngTwoPioperator+= (direction_t const &arg)
AngTwoPioperator-= (direction_t const &arg)
AngTwoPioperator*= (direction_t const &arg)
AngTwoPioperator/= (direction_t const &arg)
operator direction_t () const

## Protected Member Functions

void normalize ()
conversion operator for going back to the primitive type

## Protected Attributes

direction_t value
holds the angle, should be kept normalized at all times

## Friends

AngPi angdist (AngTwoPi const &arg1, AngTwoPi const &arg2)
Angular distance: value is between 0 and pi.

## Constructor & Destructor Documentation

 AngTwoPi::AngTwoPi ( void )

Definition at line 77 of file Measures.h.

Referenced by operator*(), operator+(), operator-(), and operator/().

 AngTwoPi::AngTwoPi ( direction_t const & v )

constructor, value defaults to 0

conversion operator allows implicit construction from primitive

Definition at line 78 of file Measures.h.

## Member Function Documentation

 void AngTwoPi::normalize ( ) ` [protected]`

conversion operator for going back to the primitive type

modifies value to put it back in range

Definition at line 48 of file Measures.cc.

Referenced by AngTwoPi(), operator*=(), operator+=(), operator-=(), operator/=(), and operator=().

 AngTwoPi::operator direction_t ( ) const

Definition at line 92 of file Measures.h.

 AngTwoPi AngTwoPi::operator* ( direction_t const & arg ) const

Definition at line 82 of file Measures.h.

 AngTwoPi& AngTwoPi::operator*= ( direction_t const & arg )

Definition at line 89 of file Measures.h.

 AngTwoPi AngTwoPi::operator+ ( AngTwoPi const & arg ) const

Definition at line 80 of file Measures.h.

 AngTwoPi& AngTwoPi::operator+= ( direction_t const & arg )

Definition at line 87 of file Measures.h.

 AngTwoPi AngTwoPi::operator- ( AngTwoPi const & arg ) const

Definition at line 81 of file Measures.h.

 AngTwoPi& AngTwoPi::operator-= ( direction_t const & arg )

Definition at line 88 of file Measures.h.

 AngTwoPi AngTwoPi::operator/ ( direction_t const & arg ) const

Definition at line 83 of file Measures.h.

 AngTwoPi& AngTwoPi::operator/= ( direction_t const & arg )

Definition at line 90 of file Measures.h.

 AngTwoPi& AngTwoPi::operator= ( direction_t const & arg )

Definition at line 86 of file Measures.h.

 AngTwoPi& AngTwoPi::operator= ( AngTwoPi const & arg )

Definition at line 85 of file Measures.h.

## Friends And Related Function Documentation

 AngPi angdist ( AngTwoPi const & arg1, AngTwoPi const & arg2 ) ` [friend]`

Angular distance: value is between 0 and pi.

Definition at line 66 of file Measures.cc.

## Member Data Documentation

 direction_t AngTwoPi::value` [protected]`

holds the angle, should be kept normalized at all times

Definition at line 96 of file Measures.h.

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

 Tekkotsu v5.1CVS Generated Mon May 9 04:59:04 2016 by Doxygen 1.6.3 