Class 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.
variable b#
The second component of the dual number.
Public Functions Documentation#
function SBDTypeDual [1/3]#
Constructs a dual number with both components set to zero.
function SBDTypeDual [2/3]#
Constructs a dual number with components a andb .
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.
function isSerializable#
Returns true __
function operator*#
Returns the product of this dual number with dual number d .
function operator*#
Returns the product of this dual number with double d .
function operator*#
Returns the product of this dual number with dimensionless quantity d .
function operator*=#
Multiplies this dual number with dual number d .
function operator*=#
Multiplies this dual number with double d .
function operator*=#
Multiplies this dual number with dimensionless quantity d .
function operator+#
Returns the sum of this dual number with dual number d .
function operator+=#
Adds dual number d to this dual number.
function operator-#
Returns the difference between this dual number and dual number d .
function operator-#
Returns the opposite of this dual number.
function operator-=#
Subtracts dual number d from this dual number.
function operator/#
Returns the division of this dual number by dual number d .
function operator/=#
Divides this dual number by dual number d .
function print#
Prints the dual number.
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.
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.