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());