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
object ComplexField : ExtendedField<Complex> , Norm<Complex, Complex> , NumbersAddOps<Complex> , ScaleOperations<Complex>

A field of Complex.

Link copied to clipboard
class ComplexFieldND(val shape: ShapeND) : ComplexFieldOpsND, FieldND<Complex, ComplexField> , NumbersAddOps<StructureND<Complex>>
Link copied to clipboard
sealed class ComplexFieldOpsND : BufferedFieldOpsND<Complex, ComplexField> , ScaleOperations<StructureND<Complex>> , ExtendedFieldOps<StructureND<Complex>> , PowerOperations<StructureND<Complex>>

An optimized nd-field for complex numbers

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

Represents double-based quaternion.

Link copied to clipboard
object QuaternionField : Field<Quaternion> , Norm<Quaternion, Double> , PowerOperations<Quaternion> , ExponentialOperations<Quaternion> , NumbersAddOps<Quaternion> , ScaleOperations<Quaternion>

A field of Quaternion.

Functions

Link copied to clipboard
inline fun Buffer.Companion.complex(size: Int, init: (Int) -> Complex): Buffer<Complex>
inline fun MutableBuffer.Companion.complex(size: Int, init: (Int) -> Complex): MutableBuffer<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
inline fun Buffer.Companion.quaternion(size: Int, init: (Int) -> Quaternion): Buffer<Quaternion>
inline fun MutableBuffer.Companion.quaternion(size: Int, init: (Int) -> Quaternion): MutableBuffer<Quaternion>

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.