Base::DualNumber Class Reference

Dual Numbers aer 2-part numbers like complex numbers, but different algebra. More...

#include <DualNumber.h>

Public Member Functions

 DualNumber ()
 
 DualNumber (double re, double du=0.0)
 
DualNumber operator- () const
 

Public Attributes

double du = 0.0
 
double re = 0.0
 

Detailed Description

Dual Numbers aer 2-part numbers like complex numbers, but different algebra.

They are denoted as a + b*eps, where eps^2 = 0. eps, the nilpotent, is like imaginary unit of complex numbers. The neat utility of dual numbers is that if you use them instead of normal numbers in a function like sin(), derivative is implicitly calculated as a multiplier to the dual part.

Constructor & Destructor Documentation

◆ DualNumber() [1/2]

Base::DualNumber::DualNumber ( )

Referenced by operator-().

◆ DualNumber() [2/2]

Base::DualNumber::DualNumber ( double  re,
double  du = 0.0 
)

Member Function Documentation

◆ operator-()

DualNumber Base::DualNumber::operator- ( ) const

References du, DualNumber(), and re.

Member Data Documentation

◆ du

double Base::DualNumber::du = 0.0

Referenced by operator-(), and Base::DualQuat::pow().

◆ re

double Base::DualNumber::re = 0.0

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