42 for (ArrayOfIndex::const_iterator it = dim_sizes.begin();
43 it != dim_sizes.end();
52 const Index min_num_elem,
55 if (type.
nelem() > min_num_elem) dim_sizes.push_back(type.
nelem());
60 const Index min_num_elem,
63 if (type.
nrows() > min_num_elem) dim_sizes.push_back(type.
nrows());
64 if (type.
ncols() > min_num_elem) dim_sizes.push_back(type.
ncols());
69 const Index min_num_elem,
72 if (type.
npages() > min_num_elem) dim_sizes.push_back(type.
npages());
73 if (type.
nrows() > min_num_elem) dim_sizes.push_back(type.
nrows());
74 if (type.
ncols() > min_num_elem) dim_sizes.push_back(type.
ncols());
79 const Index min_num_elem,
82 if (type.
nbooks() > min_num_elem) dim_sizes.push_back(type.
nbooks());
83 if (type.
npages() > min_num_elem) dim_sizes.push_back(type.
npages());
84 if (type.
nrows() > min_num_elem) dim_sizes.push_back(type.
nrows());
85 if (type.
ncols() > min_num_elem) dim_sizes.push_back(type.
ncols());
90 const Index min_num_elem,
94 if (type.
nbooks() > min_num_elem) dim_sizes.push_back(type.
nbooks());
95 if (type.
npages() > min_num_elem) dim_sizes.push_back(type.
npages());
96 if (type.
nrows() > min_num_elem) dim_sizes.push_back(type.
nrows());
97 if (type.
ncols() > min_num_elem) dim_sizes.push_back(type.
ncols());
102 const Index min_num_elem,
107 if (type.
nbooks() > min_num_elem) dim_sizes.push_back(type.
nbooks());
108 if (type.
npages() > min_num_elem) dim_sizes.push_back(type.
npages());
109 if (type.
nrows() > min_num_elem) dim_sizes.push_back(type.
nrows());
110 if (type.
ncols() > min_num_elem) dim_sizes.push_back(type.
ncols());
115 const Index min_num_elem,
121 if (type.
nbooks() > min_num_elem) dim_sizes.push_back(type.
nbooks());
122 if (type.
npages() > min_num_elem) dim_sizes.push_back(type.
npages());
123 if (type.
nrows() > min_num_elem) dim_sizes.push_back(type.
nrows());
124 if (type.
ncols() > min_num_elem) dim_sizes.push_back(type.
ncols());
143 os <<
"The Vector is not also a Numeric";
144 throw std::runtime_error(os.
str());
160 os <<
"The Matrix is not also a Numeric";
161 throw std::runtime_error(os.
str());
177 os <<
"The Tensor3 is not also a Numeric";
178 throw std::runtime_error(os.
str());
194 os <<
"The Tensor4 is not also a Numeric";
195 throw std::runtime_error(os.
str());
209 o =
i(0, 0, 0, 0, 0);
212 os <<
"The Tensor5 is not also a Numeric";
213 throw std::runtime_error(os.
str());
227 o =
i(0, 0, 0, 0, 0, 0);
230 os <<
"The Tensor6 is not also a Numeric";
231 throw std::runtime_error(os.
str());
245 o =
i(0, 0, 0, 0, 0, 0, 0);
248 os <<
"The Tensor7 is not also a Numeric";
249 throw std::runtime_error(os.
str());
275 os <<
"The Matrix of size (" << dim_sizes <<
") \n" 276 <<
"does not fit a Vector";
277 throw std::runtime_error(os.
str());
301 os <<
"The Tensor3 of size (" << dim_sizes <<
") \n" 302 <<
"does not fit a Vector";
303 throw std::runtime_error(os.
str());
327 os <<
"The Tensor4 of size (" << dim_sizes <<
") \n" 328 <<
"does not fit a Vector";
329 throw std::runtime_error(os.
str());
353 os <<
"The Tensor5 of size (" << dim_sizes <<
") \n" 354 <<
"does not fit a Vector";
355 throw std::runtime_error(os.
str());
379 os <<
"The Tensor6 of size (" << dim_sizes <<
") \n" 380 <<
"does not fit a Vector";
381 throw std::runtime_error(os.
str());
405 os <<
"The Tensor7 of size (" << dim_sizes <<
") \n" 406 <<
"does not fit a Vector";
407 throw std::runtime_error(os.
str());
427 o.
resize(dim_sizes[0], dim_sizes[1]);
433 os <<
"The Tensor3 of size (" << dim_sizes <<
") \n" 434 <<
"does not fit a Matrix";
435 throw std::runtime_error(os.
str());
453 o.
resize(dim_sizes[0], dim_sizes[1]);
459 os <<
"The Tensor4 of size (" << dim_sizes <<
") \n" 460 <<
"does not fit a Matrix";
461 throw std::runtime_error(os.
str());
479 o.
resize(dim_sizes[0], dim_sizes[1]);
485 os <<
"The Tensor5 of size (" << dim_sizes <<
") \n" 486 <<
"does not fit a Matrix";
487 throw std::runtime_error(os.
str());
505 o.
resize(dim_sizes[0], dim_sizes[1]);
511 os <<
"The Tensor6 of size (" << dim_sizes <<
") \n" 512 <<
"does not fit a Matrix";
513 throw std::runtime_error(os.
str());
531 o.
resize(dim_sizes[0], dim_sizes[1]);
537 os <<
"The Tensor7 of size (" << dim_sizes <<
") \n" 538 <<
"does not fit a Matrix";
539 throw std::runtime_error(os.
str());
559 o.
resize(dim_sizes[0], dim_sizes[1], dim_sizes[2]);
565 os <<
"The Tensor4 of size (" << dim_sizes <<
") \n" 566 <<
"does not fit a Tensor3";
567 throw std::runtime_error(os.
str());
585 o.
resize(dim_sizes[0], dim_sizes[1], dim_sizes[2]);
591 os <<
"The Tensor5 of size (" << dim_sizes <<
") \n" 592 <<
"does not fit a Tensor3";
593 throw std::runtime_error(os.
str());
611 o.
resize(dim_sizes[0], dim_sizes[1], dim_sizes[2]);
617 os <<
"The Tensor6 of size (" << dim_sizes <<
") \n" 618 <<
"does not fit a Tensor3";
619 throw std::runtime_error(os.
str());
637 o.
resize(dim_sizes[0], dim_sizes[1], dim_sizes[2]);
643 os <<
"The Tensor7 of size (" << dim_sizes <<
") \n" 644 <<
"does not fit a Tensor3";
645 throw std::runtime_error(os.
str());
665 o.
resize(dim_sizes[0], dim_sizes[1], dim_sizes[2], dim_sizes[3]);
671 os <<
"The Tensor5 of size (" << dim_sizes <<
") \n" 672 <<
"does not fit a Tensor4";
673 throw std::runtime_error(os.
str());
691 o.
resize(dim_sizes[0], dim_sizes[1], dim_sizes[2], dim_sizes[3]);
697 os <<
"The Tensor6 of size (" << dim_sizes <<
") \n" 698 <<
"does not fit a Tensor4";
699 throw std::runtime_error(os.
str());
717 o.
resize(dim_sizes[0], dim_sizes[1], dim_sizes[2], dim_sizes[3]);
723 os <<
"The Tensor7 of size (" << dim_sizes <<
") \n" 724 <<
"does not fit a Tensor4";
725 throw std::runtime_error(os.
str());
746 dim_sizes[0], dim_sizes[1], dim_sizes[2], dim_sizes[3], dim_sizes[4]);
752 os <<
"The Tensor6 of size (" << dim_sizes <<
") \n" 753 <<
"does not fit a Tensor5";
754 throw std::runtime_error(os.
str());
773 dim_sizes[0], dim_sizes[1], dim_sizes[2], dim_sizes[3], dim_sizes[4]);
779 os <<
"The Tensor7 of size (" << dim_sizes <<
") \n" 780 <<
"does not fit a Tensor5";
781 throw std::runtime_error(os.
str());
812 os <<
"The Tensor7 of size (" << dim_sizes <<
") \n" 813 <<
"does not fit a Tensor6";
814 throw std::runtime_error(os.
str());
Index npages() const
Returns the number of pages.
INDEX Index
The type to use for all integer numbers and indices.
Index nrows() const
Returns the number of rows.
Index nelem() const
Number of elements.
void resize(Index s, Index b, Index p, Index r, Index c)
Resize function.
const Numeric * get_c_array() const
Conversion to plain C-array.
Index nvitrines() const
Returns the number of vitrines.
Index nrows() const
Returns the number of rows.
Index npages() const
Returns the number of pages.
Index num_elem_from_dim_sizes(const ArrayOfIndex &dim_sizes)
Index nbooks() const
Returns the number of books.
Index nrows() const
Returns the number of rows.
Index nrows() const
Returns the number of rows.
Index nelem() const
Returns the number of elements.
This file contains the definition of Array.
Index ncols() const
Returns the number of columns.
const Numeric * get_c_array() const
Conversion to plain C-array, const-version.
Index nshelves() const
Returns the number of shelves.
_CS_string_type str() const
void Reduce(Numeric &o, const Vector &i, const Verbosity &)
WORKSPACE METHOD: Reduce.
Index ncols() const
Returns the number of columns.
The declarations of all the exception classes.
Index nrows() const
Returns the number of rows.
NUMERIC Numeric
The type to use for all floating point numbers.
Index nlibraries() const
Returns the number of libraries.
const Numeric * get_c_array() const
Conversion to plain C-array.
const Numeric * get_c_array() const
Conversion to plain C-array.
void resize(Index p, Index r, Index c)
Resize function.
Index npages() const
Returns the number of pages.
This can be used to make arrays out of anything.
Index nshelves() const
Returns the number of shelves.
Index ncols() const
Returns the number of columns.
const Numeric * get_c_array() const
Conversion to plain C-array.
void resize(Index n)
Resize function.
Index npages() const
Returns the number of pages.
Index nshelves() const
Returns the number of shelves.
Index npages() const
Returns the number of pages.
Index nbooks() const
Returns the number of books.
void resize(Index v, Index s, Index b, Index p, Index r, Index c)
Resize function.
void select_dims_by_size(ArrayOfIndex &dim_sizes, const Index min_num_elem, const Vector &type)
Index ncols() const
Returns the number of columns.
const Numeric * get_c_array() const
Conversion to plain C-array.
Index nvitrines() const
Returns the number of vitrines.
Index ncols() const
Returns the number of columns.
Index ncols() const
Returns the number of columns.
Index nrows() const
Returns the number of rows.
Index nbooks() const
Returns the number of books.
void resize(Index b, Index p, Index r, Index c)
Resize function.
void resize(Index r, Index c)
Resize function.
const Numeric * get_c_array() const
Conversion to plain C-array.
Index nbooks() const
Returns the number of books.