Equivalent to tma's calculate_1d_index(). Throws if lengths of `indices` and `dims` differ.

lq_calculate_1d_index(indices, dims)

Arguments

indices

0-based integer vector of per-dimension indices

dims

Integer vector of array dimensions

Value

Scalar integer linear index