## Types

Type Quaternion

Namespace MathNet.Numerics

Parent ValueType

Interfaces IComparable, ICloneable

### Public instance methods

Add a quaternion to this quaternion.
 return `Quaternion` `Quaternion` q

Add a floating point number to this quaternion.
 return `Quaternion` `double` r

#### object Clone()

Creates a copy of this quaternion.
 return `object`

#### int CompareTo(object obj)

Compares this quaternion with another quaternion.
 return `int` `object` obj

#### Quaternion Conjugate()

Conjugate this quaternion.
 return `Quaternion`

#### Quaternion Divide(double d)

Multiplies a Quaterion with the inverse of a real number.
Its also Possible to cast a double to a Quaternion and make the division afterwards. But this is less performant.
 return `Quaternion` `double` d

#### Quaternion Divide(Quaternion q)

Multiplies a Quaternion with the inverse of another Quaternion (q*q). Note that for Quaternions q*q is not the same then q*q, because this will lead to a rotation in the other direction.
 return `Quaternion` `Quaternion` q

#### bool Equals(object obj)

 return `bool` `object` obj

#### Quaternion Exp()

Exponential Function.
 return `Quaternion`

#### int GetHashCode()

 return `int`

#### Type GetType()

 return `Type`

#### Quaternion Inverse()

Inverts this quaternion.
 return `Quaternion`

#### Quaternion Lg()

Common Logarithm to base 10.
 return `Quaternion`

#### Quaternion Ln()

Natural Logrithm to base E.
 return `Quaternion`

#### Quaternion Log(double lbase)

Logarithm to a given base.
 return `Quaternion` `double` lbase

#### Quaternion Multiply(double d)

Multiply a floating point number to this quaternion.
 return `Quaternion` `double` d

#### Quaternion Multiply(Quaternion q)

Multiply a quaternion with this quaternion.
 return `Quaternion` `Quaternion` q

#### Quaternion Negate()

Negate this quaternion.
 return `Quaternion`

#### Quaternion Pow(Quaternion power)

Raise the quaternion to a given power.
 return `Quaternion` `Quaternion` power

#### Quaternion Pow(double power)

Raise the quaternion to a given power.
 return `Quaternion` `double` power

#### Quaternion Scalar()

Returns a new Quaternion q with the Scalar part only. If you need a Double, use the Real-Field instead.
 return `Quaternion`

#### Quaternion Sign()

Returns a new normalized Quaternion q with the direction of this quaternion.
 return `Quaternion`

#### Quaternion Sqr()

Square of the Quaternion q: q^2.
 return `Quaternion`

#### Quaternion Sqrt()

Square root of the Quaternion: q^(1/2).
 return `Quaternion`

#### Quaternion Subtract(double r)

Subtract a floating point number from this quaternion.
 return `Quaternion` `double` r

#### Quaternion Subtract(Quaternion q)

SUbtract a quaternion from this quaternion.
 return `Quaternion` `Quaternion` q

#### string ToString()

 return `string`

#### Quaternion UnitVector()

Returns a new normalized Quaternion u with the Vectorpart only, such that ||u|| = 1. Q may then be represented as q = r*(cos(phi) + u * sin(phi)) = r*exp(phi*u) where r is the absolute and phi the argument of q.
 return `Quaternion`

#### Quaternion Vector()

Returns a new Quaternion q with the Vectorpart only.
 return `Quaternion`

### Public static methods

#### double Distance(Quaternion a, Quaternion b)

Returns the distance |a-b| of two quaternions, forming a metric space.
 return `double` `Quaternion` a `Quaternion` b

### Public properties

#### double Abs get;

G ets the standard euclidean length |q| = sqrt(||q||) of the quaternion q: the square root of the sum of the squares of the four components. Q may then be represented as q = r*(cos(phi) + u * sin(phi)) = r*exp(phi*u) where u is the unit vector and phi the argument of q.
 `return double`

#### double Arg get;

Gets the argument phi = arg(q) of the quaternion q, such that q = r*(cos(phi) + u * sin(phi)) = r*exp(phi*u) where r is the absolute and u the unit vector of q.
 `return double`

#### double ImagX get;

Gets the imaginary X part (coefficient of complex I) of the quaternion.
 `return double`

#### double ImagY get;

Gets the imaginary Y part (coefficient of complex J) of the quaternion.
 `return double`

#### double ImagZ get;

Gets the imaginary Z part (coefficient of complex K) of the quaternion.
 `return double`

#### bool IsUnitQuaternion get;

True if the quaternion q is of lenght |q| = 1.
To normalize a quaternion to a length of 1, use the Sign method. All unit quaternions form a 3-sphere.
 `return bool`

#### double Norm get;

Gets the norm ||q|| = |q|^2 of the quaternion q: the sum of the squares of the four components.
 `return double`

#### double Real get;

Gets the real part of the quaternion.
 `return double`