DenseMatrixView
A borrowed rectangle of a DoubleArray, with explicit offset and leadingDimension. No entries are copied or owned. The backing buffer can also be mutated by its owner or other views. Unlike DenseMatrix, values need not have exactly rows * cols entries. Views use reference equality.
Properties
cols
leadingDimension
Distance between consecutive column starts.
offset
rows
values
Shared column-major backing buffer, including entries outside this region.
Functions
get
set
toArray
Materialise into a fresh Array<DoubleArray> of rows, independent of the internal storage.
Link copied to clipboard
open fun view(rowOffset: Int = 0, columnOffset: Int = 0, rows: Int = this.rows - rowOffset, cols: Int = this.cols - columnOffset): DenseMatrixView
Borrows a rectangle without copying. Mutations through either reference are shared. Offsets and extents are relative to this region; a nested view retains the parent's leading dimension. Empty rectangles at either boundary are valid and access no entries.