Package-level declarations

Types

Link copied to clipboard
data class Complex(val re: Double, val im: Double)

Represents double-based complex number.

Link copied to clipboard
class Quaternion(val w: Double, val x: Double, val y: Double, val z: Double) : Buffer<Double>

Represents double-based quaternion.

Functions

Link copied to clipboard
inline fun Buffer.Companion.complex(size: Int, init: (Int) -> Complex): Buffer<Complex>

Creates a new buffer of complex numbers with the specified size, where each element is calculated by calling the specified init function.

Link copied to clipboard
Link copied to clipboard

Produce a normalized version of this quaternion

Link copied to clipboard
fun Quaternion(w: Number, x: Number = 0.0, y: Number = 0.0, z: Number = 0.0): Quaternion
Link copied to clipboard

Creates a new buffer of quaternions with the specified size, where each element is calculated by calling the specified init function.

Link copied to clipboard

Creates a complex number with real part equal to this real.

Link copied to clipboard
inline fun <R> ComplexField.withNdAlgebra(vararg shape: Int, action: ComplexFieldND.() -> R): R

Produce a context for n-dimensional operations inside this real field

Properties

Link copied to clipboard
Link copied to clipboard

This complex's conjugate.

This quaternion's conjugate.

Link copied to clipboard
Link copied to clipboard

Absolute value of complex number.

Link copied to clipboard

This complex's reciprocal.

This quaternion's reciprocal.

Link copied to clipboard

An angle between vector represented by complex number and X axis.