AFF --- A container for numbers (array) by Friederich and Forbriger.

◆ is_dense_1D_array()

bool aff::util::is_dense_1D_array ( const aff::Strided shape)

check whether array shape describes a 1D array with dense layout in the memory.

Parameters
shapearray shape
Returns
true if shape is dense and 1D

Definition at line 302 of file strided.cc.

References aff::Strided::size(), and aff::Strided::stride().

Referenced by aff::series_from_array().

303  {
304  bool retval
305  =((shape.size(1)==1)
306  && (shape.size(2)==1)
307  && (shape.size(3)==1)
308  && (shape.stride(0)==1));
309  return retval;
310  } // bool is_dense_1D_array(const aff::Strided& shape)
const Tsize & stride(const Tsubscript &i) const
stride of dimension
Definition: strided.h:203
Tsize size() const
total number of mapped elements
Definition: strided.cc:140
Here is the call graph for this function:
Here is the caller graph for this function: