QuantityVector

case class QuantityVector[A <: Quantity[A]](coordinates: A*) extends SVector[A]

Quantity Vector

Type Params
A

QuantityType

Value Params
coordinates

Variable list of A

Since

0.3.0

trait Serializable
trait Product
trait Equals
trait SVector[A]
class Object
trait Matchable
class Any

Type members

Types

Value members

Concrete methods

def /(that: A): DoubleVector
def angle(coordinateX: Int, coordinateY: Int, unit: AngleUnit): Angle
def crossProduct[B <: Quantity[LazyRef(...)], C <: Quantity[LazyRef(...)]](that: SVector[B], quantTimes: (A, B) => C): QuantityVector[C]
def divide(that: Double): SVectorType
def divide(that: A): DoubleVector
def divide[B <: Quantity[LazyRef(...)], C <: Quantity[LazyRef(...)]](quantDiv: A => C): QuantityVector[C]
def dotProduct(that: DoubleVector): A
def dotProduct[B <: Quantity[LazyRef(...)], C <: Quantity[LazyRef(...)]](that: SVector[B], quantTimes: (A, B) => C)(implicit num: Numeric[C]): C
def in(uom: UnitOfMeasure[A]): QuantityVector[A]

Returns a QuantityVector with all coordinates set to the supplied unit

Returns a QuantityVector with all coordinates set to the supplied unit

Value Params
uom

UnitOfMeasure[A]

def magnitude: A
def map[B <: Double](f: A => Double): DoubleVector

Creates a DoubleVector by mapping over each coordinate with the supplied function

Creates a DoubleVector by mapping over each coordinate with the supplied function

Value Params
f

A => Double map function

def map[B <: Quantity[LazyRef(...)]](f: A => B): QuantityVector[B]

Creates a QuantityVector by mapping over each coordinate with the supplied function

Creates a QuantityVector by mapping over each coordinate with the supplied function

Type Params
B

<: Quantity

Value Params
f

A => B

Creates the Unit Vector which corresponds to this vector using the given unit

Creates the Unit Vector which corresponds to this vector using the given unit

def times(that: Double): SVectorType
def times[B <: Quantity[LazyRef(...)], C <: Quantity[LazyRef(...)]](quantTimes: A => C): QuantityVector[C]

Returns a DoubleVector representing the quantity values in terms of the supplied unit

Returns a DoubleVector representing the quantity values in terms of the supplied unit

Value Params
uom

UnitOfMeasure[A]

Inherited methods

def #*: DoubleVector => SVector[A]
Inherited from
SVector
def *(that: DoubleVector): A
Inherited from
SVector
def *(that: Double): SVectorType
Inherited from
SVector
Inherited from
SVector
Inherited from
SVector
def /(that: Double): SVectorType
Inherited from
SVector
def polar(coordinateX: Int, coordinateY: Int, unit: AngleUnit): (A, Angle)

The polar coordinates (r, theta) of the two Cartesian coordinates at the supplied indices

The polar coordinates (r, theta) of the two Cartesian coordinates at the supplied indices

Value Params
coordinateX

index of the abscissa coordinate (defaults to 0)

coordinateY

index of the ordinate coordinate (defaults to 1)

unit

unit for the angle (theta) component (defaults to Radians)

Returns

(A, Angle)

Inherited from
SVector
def productElementNames: Iterator[String]
Inherited from
Product
def productIterator: Iterator[Any]
Inherited from
Product