Web Analytics Made Easy - Statcounter
Skip to content

Class SBDTypeDual#

ClassList > SBDTypeDual

This class describes a dual number. More...

  • #include <SBDTypeDual.hpp>

Public Attributes#

Type Name
SBQuantity::dimensionless * a
The first component of the dual number.
SBQuantity::dimensionless * b
The second component of the dual number.

Public Functions#

Type Name
SBDTypeDual ()
Constructs a dual number with both components set to zero.
SBDTypeDual (double a, double b)
Constructs a dual number with components a andb .
SBDTypeDual (const SBQuantity::dimensionless & a, const SBQuantity::dimensionless & b)
Constructs a dual number with components a andb .
SBDTypeDual inverse () const
Returns the inverse of the dual number.
virtual bool isSerializable () const
Returns true.
SBDTypeDual operator* (const SBDTypeDual & d) const
Returns the product of this dual number with dual number d .
SBDTypeDual operator* (double d) const
Returns the product of this dual number with double d .
SBDTypeDual operator* (const SBQuantity::dimensionless & d) const
Returns the product of this dual number with dimensionless quantity d .
SBDTypeDual & operator*= (const SBDTypeDual & d)
Multiplies this dual number with dual number d .
SBDTypeDual & operator*= (double d)
Multiplies this dual number with double d .
SBDTypeDual & operator*= (const SBQuantity::dimensionless & d)
Multiplies this dual number with dimensionless quantity d .
SBDTypeDual operator+ (const SBDTypeDual & d) const
Returns the sum of this dual number with dual number d .
SBDTypeDual & operator+= (const SBDTypeDual & d)
Adds dual number d to this dual number.
SBDTypeDual operator- (const SBDTypeDual & d) const
Returns the difference between this dual number and dual number d .
SBDTypeDual operator- () const
Returns the opposite of this dual number.
SBDTypeDual & operator-= (const SBDTypeDual & d)
Subtracts dual number d from this dual number.
SBDTypeDual operator/ (const SBDTypeDual & d) const
Returns the division of this dual number by dual number d .
SBDTypeDual & operator/= (const SBDTypeDual & d)
Divides this dual number by dual number d .
void print () const
Prints the dual number.
virtual void serialize (SBCSerializer * serializer, const SBVersionNumber & sdkVersionNumber=SB_SDK_VERSION_NUMBER) const
Serializes the dual number.
SBDTypeDual squareRoot () const
Returns the square root of the dual number.
virtual void unserialize (SBCSerializer * serializer, const SBVersionNumber & sdkVersionNumber=SB_SDK_VERSION_NUMBER)
Unserializes the dual number.
~SBDTypeDual ()
Destructs the dual number.

Detailed Description#

This class describes dual numbers. Dual numbers are pairs of dimensionless physical quantities, that are mainly used in conjunction with dual quaternions.

Short name: SBDual

See also: SBDTypeDualQuaternion

See also: SAMSON's unit system

Public Attributes Documentation#

variable a#

The first component of the dual number.

SBQuantity::dimensionless* a;


variable b#

The second component of the dual number.

SBQuantity::dimensionless* b;


Public Functions Documentation#

function SBDTypeDual [1/3]#

Constructs a dual number with both components set to zero.

SBDTypeDual::SBDTypeDual () 


function SBDTypeDual [2/3]#

Constructs a dual number with components a andb .

SBDTypeDual::SBDTypeDual (
    double a,
    double b
) 


function SBDTypeDual [3/3]#

Constructs a dual number with components a andb .

SBDTypeDual::SBDTypeDual (
    const SBQuantity::dimensionless & a,
    const SBQuantity::dimensionless & b
) 


function inverse#

Returns the inverse of the dual number.

SBDTypeDual SBDTypeDual::inverse () const


function isSerializable#

Returns true.

virtual bool SBDTypeDual::isSerializable () const


function operator*#

Returns the product of this dual number with dual number d .

SBDTypeDual SBDTypeDual::operator* (
    const SBDTypeDual & d
) const


function operator*#

Returns the product of this dual number with double d .

SBDTypeDual SBDTypeDual::operator* (
    double d
) const


function operator*#

Returns the product of this dual number with dimensionless quantity d .

SBDTypeDual SBDTypeDual::operator* (
    const SBQuantity::dimensionless & d
) const


function operator*=#

Multiplies this dual number with dual number d .

SBDTypeDual & SBDTypeDual::operator*= (
    const SBDTypeDual & d
) 


function operator*=#

Multiplies this dual number with double d .

SBDTypeDual & SBDTypeDual::operator*= (
    double d
) 


function operator*=#

Multiplies this dual number with dimensionless quantity d .

SBDTypeDual & SBDTypeDual::operator*= (
    const SBQuantity::dimensionless & d
) 


function operator+#

Returns the sum of this dual number with dual number d .

SBDTypeDual SBDTypeDual::operator+ (
    const SBDTypeDual & d
) const


function operator+=#

Adds dual number d to this dual number.

SBDTypeDual & SBDTypeDual::operator+= (
    const SBDTypeDual & d
) 


function operator-#

Returns the difference between this dual number and dual number d .

SBDTypeDual SBDTypeDual::operator- (
    const SBDTypeDual & d
) const


function operator-#

Returns the opposite of this dual number.

SBDTypeDual SBDTypeDual::operator- () const


function operator-=#

Subtracts dual number d from this dual number.

SBDTypeDual & SBDTypeDual::operator-= (
    const SBDTypeDual & d
) 


function operator/#

Returns the division of this dual number by dual number d .

SBDTypeDual SBDTypeDual::operator/ (
    const SBDTypeDual & d
) const


function operator/=#

Divides this dual number by dual number d .

SBDTypeDual & SBDTypeDual::operator/= (
    const SBDTypeDual & d
) 


function print#

Prints the dual number.

void SBDTypeDual::print () const


function serialize#

Serializes the dual number.

virtual void SBDTypeDual::serialize (
    SBCSerializer * serializer,
    const SBVersionNumber & sdkVersionNumber=SB_SDK_VERSION_NUMBER
) const


function squareRoot#

Returns the square root of the dual number.

SBDTypeDual SBDTypeDual::squareRoot () const


function unserialize#

Unserializes the dual number.

virtual void SBDTypeDual::unserialize (
    SBCSerializer * serializer,
    const SBVersionNumber & sdkVersionNumber=SB_SDK_VERSION_NUMBER
) 


function ~SBDTypeDual#

Destructs the dual number.

SBDTypeDual::~SBDTypeDual ()