ContiguousVector
A dense vector that owns its whole buffer, so its entries are exactly values, in order and complete.
Functions
equals
get
hashCode
set
toDoubleArray
Materialise into a fresh dense DoubleArray, independent of the internal storage.
toString
A borrowed view over this whole vector, keeping whatever origin and spacing it already has.
y = y + alpha * x. A sparse x touches only the positions it stores. A dense x with an identical mapping is read directly; other dense overlaps, or sparse values sharing the destination buffer, are snapshotted before writing. Custom Vector implementations are also snapshotted, since their backing storage is opaque.
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.
Zero-based logical index of the maximum absolute value (BLAS idamax), or -1 when empty. Dense vectors use DenseVectorKernels.iamax; sparse vectors visit only their stored entries. All-zero nonempty inputs return 0, as do sparse inputs whose maximum is an implicit zero. Strided views report their logical index rather than a backing-array offset.
a - b, allocating. axpy with alpha = -1.0 accumulates into an existing operand.
Whether these vectors address at least one common buffer entry.
a + b, allocating. axpy accumulates into an existing operand.
v = alpha * v.
alpha * x, allocating. scale multiplies in place.
-x, allocating.
A borrowed strided slice, addressed in this vector's logical indices rather than its buffer's positions.