36 ostream& operator<< (ostream& o,
const Index& so) {
39 for (
int i=0 ; i<so.
get_ndim()-1 ; i++)
40 o << so.
coord[i] <<
", " ;
42 o << so.
sizes <<
" points." ;
int & set(int i)
Read/write of the size of a given dimension.
Class that gives the position inside a multi-dimensional Array.
Dim_array sizes
Sizes of the associated Array.
Data_type coord
Value of each index.
int get_ndim() const
Returns the number of dimensions.
Index(const Dim_array &dim)
Standard constructor.
int get_ndim() const
Returns the number dimension.