DenseVector
Mutable dense vector, including borrowed slices with positive or negative strides. Entry x(i) is at offset + i * stride in values. Factories allocate or borrow storage; view shares it. Equality and hashing compare logical entries, including signed zeros and NaNs. Serialization writes logical entries in order and decodes independent contiguous storage. Do not use the vector as a hash-map key while mutating its entries.
Types
Functions
equals
get
hashCode
set
toDoubleArray
Materialise into a fresh dense DoubleArray, independent of the internal storage.
toString
view
Visit each stored entry as (index, value), in ascending index order for any storage. A SparseVector may present numerical zeros as stored, and any other Vector has every index visited.
Vector norm of type: Norm.One sums absolute values, Norm.Two is the Euclidean norm, and Norm.Infinity and Norm.MaxAbs select the maximum absolute value. An empty vector has norm zero.