#include <STK_ITContainer2D.h>
Inherits IContainerBase< TContainer2D >.
Public Member Functions | |
| virtual | ~ITContainer2D () |
| Integer | sizeHo () const |
| Integer | firstCol () const |
| Integer | lastCol () const |
| Integer | getSizeHo () const |
| Inx const & | getRangeHo () const |
| Integer | sizeVe () const |
| Integer | firstRow () const |
| Integer | lastRow () const |
| Integer | getSizeVe () const |
| Inx const & | getRangeVe () const |
| bool | empty () const |
| TYPE & | operator() (const Integer &i, const Integer j) |
| const TYPE & | operator() (Integer i, Integer j) const |
| TContainerVe | operator[] (Integer j) const |
| TContainerVe | operator() (const Inx &I, Integer j) const |
| TContainerHo | operator() (Integer i) const |
| TContainerHo | operator() (Integer i, const Inx &J) const |
| TContainer2D | operator() (const Inx &I, const Inx &J) const |
| TContainer2D | operator() (const Inx &I) const |
| TContainer2D | operator[] (const Inx &J) const |
| TYPE & | at (Integer i, Integer j) |
| const TYPE & | at (Integer i, Integer j) const |
| TContainer2D | at (const Inx &I, const Inx &J) |
| TContainerVe | at (const Inx &I, Integer j) |
| TContainerHo | at (Integer i, const Inx &J) const |
| TContainerVe | atCol (Integer j) |
| TContainer2D | atCol (const Inx &J) |
| TContainerHo | atRow (Integer i) const |
| TContainer2D | atRow (const Inx &I) const |
| void | resize (const Inx &I=Inx(), const Inx &J=Inx()) |
| void | pop_back_col () |
| void | pop_back_row () |
Protected Member Functions | |
| ITContainer2D (const Inx &I=Inx(), const Inx &J=Inx()) | |
| ITContainer2D (const ITContainer2D &T) | |
| void | setRange (const Inx &I=Inx(), const Inx &J=Inx()) |
| void | setRangeVe (const Inx &I=Inx()) |
| void | incRangeVe (const Integer &inc=1) |
| void | decRangeVe (const Integer &dec=1) |
| void | setFirstVe (const Integer &beg=1) |
| void | incFirstVe (const Integer &inc=1) |
| void | decFirstVe (const Integer &dec=1) |
| void | incLastVe (const Integer &inc=1) |
| void | decLastVe (const Integer &dec=1) |
| void | infVe (const Inx &I=Inx()) |
| void | supve (const Inx &I=Inx()) |
| void | setRangeHo (const Inx &J=Inx()) |
| void | incRangeHo (const Integer &inc=1) |
| void | decRangeHo (const Integer &dec=1) |
| void | setFirstHo (const Integer &beg=1) |
| void | incFirstHo (const Integer &inc=1) |
| void | decFirstHo (const Integer &dec=1) |
| void | incLastHo (const Integer &inc=1) |
| void | decLastHo (const Integer &dec=1) |
| void | infHo (const Inx &J=Inx()) |
| void | supHo (const Inx &J=Inx()) |
Private Attributes | |
| Inx | rangeHo_ |
| Range of the cols. | |
| Inx | rangeVe_ |
| Range of the rows. | |
TContainer2D is the name of the class that implements the interface ITcontainer2D. For example template<class TYPE> class TContainer2D : public ITContainer2D< TYPE , TContainerHo , TContainerVe , TContainer2D<TYPE> > {...}
the pseudo virtual function defined in this interface have the following definition:
void shift( const Integer& rbeg =1, const Integer& cbeg =1); void pushBackCols( const Integer& n =1); void popBackCols( const Integer& n =1); void pushBackRows( const Integer& n =1); void popBackRows( const Integer& n =1); TYPE& getElt( const Integer& i, const Integer& j); const TYPE& getElt( const Integer& i, const Integer& j) const; TContainerVe getCol( const Inx &I, Integer j) const; TContainerHo getRow( const Integer& i, const Inx &J) const; TContainer2D get2D( const Inx &I, const Inx &J) const;
The clasess TContainerHo and TContainerVe are the class of the lines and columns of the two-dimensional container TContainer2D.
Definition at line 106 of file STK_ITContainer2D.h.
| STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::ITContainer2D | ( | const Inx & | I = Inx(), |
|
| const Inx & | J = Inx() | |||
| ) | [inline, protected] |
Default Ctor : rangeHo=(1:0) and rangeVe=(1:0).
| I | the vertical range | |
| J | the horizontal range |
Definition at line 121 of file STK_ITContainer2D.h.
| STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::ITContainer2D | ( | const ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D > & | T | ) | [inline, protected] |
| virtual STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::~ITContainer2D | ( | ) | [inline, virtual] |
| Integer STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::sizeHo | ( | ) | const [inline] |
Number of cols.
Definition at line 143 of file STK_ITContainer2D.h.
Referenced by STK::Svd::bidiag(), STK::Qr::compQr(), STK::Svd::init(), STK::Svd::ncolU(), STK::Svd::ncolV(), STK::EigenValues::newEigenValues(), STK::MatrixUpperTriangular::operator=(), STK::MatrixLowerTriangular::operator=(), STK::Array2D< Real >::operator=(), and STK::Array2D< TYPE >::operator=().
00143 { return rangeHo_.size();}
| Integer STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::firstCol | ( | ) | const [inline] |
Index of the first col.
Definition at line 146 of file STK_ITContainer2D.h.
Referenced by STK::Array2D< Real >::Array2D(), STK::Array2D< TYPE >::Array2D(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::at(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::atCol(), STK::Svd::bidiag(), STK::Qr::eraseCol(), STK::IArray2DBase< Real, Real *, ArrayHo< Real >, Array1D< Real >, MatrixUpperTriangular >::IArray2DBase(), STK::Qr::insertCol(), STK::leftHouseholder(), STK::MatrixLowerTriangular::MatrixLowerTriangular(), STK::MatrixUpperTriangular::MatrixUpperTriangular(), STK::EigenValues::newEigenValues(), STK::MatrixUpperTriangular::operator=(), STK::MatrixLowerTriangular::operator=(), STK::Array2D< Real >::operator=(), STK::Array2D< TYPE >::operator=(), STK::Qr::pushBackCol(), and STK::rightHouseholder().
00146 { return rangeHo_.first();}
| Integer STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::lastCol | ( | ) | const [inline] |
Index of the last col.
Definition at line 149 of file STK_ITContainer2D.h.
Referenced by STK::Array2D< Real >::Array2D(), STK::Array2D< TYPE >::Array2D(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::at(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::atCol(), STK::Svd::bidiag(), STK::Qr::eraseCol(), STK::IArray2DBase< Real, Real *, ArrayHo< Real >, Array1D< Real >, MatrixUpperTriangular >::IArray2DBase(), STK::Qr::insertCol(), STK::leftHouseholder(), STK::MatrixLowerTriangular::MatrixLowerTriangular(), STK::MatrixUpperTriangular::MatrixUpperTriangular(), STK::EigenValues::newEigenValues(), STK::MatrixUpperTriangular::operator=(), STK::MatrixLowerTriangular::operator=(), STK::Array2D< Real >::operator=(), STK::Array2D< TYPE >::operator=(), STK::Qr::pushBackCol(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::resize(), and STK::rightHouseholder().
00149 { return rangeHo_.last();}
| Integer STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::getSizeHo | ( | ) | const [inline] |
Number of cols.
Definition at line 152 of file STK_ITContainer2D.h.
Referenced by STK::Qr::eraseCol().
00152 { return rangeHo_.size();}
| Inx const& STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::getRangeHo | ( | ) | const [inline] |
Range of the col of the container.
Definition at line 155 of file STK_ITContainer2D.h.
Referenced by STK::Array2D< Real >::Array2D(), STK::Array2D< TYPE >::Array2D(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::atRow(), STK::Svd::compV(), STK::IArray2DBase< Real, Real *, ArrayHo< Real >, Array1D< Real >, MatrixUpperTriangular >::IArray2DBase(), STK::MatrixLowerTriangular::MatrixLowerTriangular(), STK::MatrixUpperTriangular::MatrixUpperTriangular(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::operator()(), STK::MatrixUpperTriangular::operator=(), STK::MatrixLowerTriangular::operator=(), STK::Array2D< Real >::operator=(), STK::Array2D< TYPE >::operator=(), and STK::IArray2DBase< Real, Real *, ArrayHo< Real >, Array1D< Real >, MatrixUpperTriangular >::swap().
00155 { return rangeHo_;};
| Integer STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::sizeVe | ( | ) | const [inline] |
Number of rows.
Definition at line 158 of file STK_ITContainer2D.h.
Referenced by STK::Svd::bidiag(), STK::Qr::compQr(), STK::Svd::init(), STK::Svd::nrowU(), STK::Svd::nrowV(), STK::MatrixUpperTriangular::operator=(), STK::MatrixLowerTriangular::operator=(), STK::Array2D< Real >::operator=(), and STK::Array2D< TYPE >::operator=().
00158 { return rangeVe_.size();}
| Integer STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::firstRow | ( | ) | const [inline] |
Index of the first row.
Definition at line 161 of file STK_ITContainer2D.h.
Referenced by STK::Array2D< Real >::Array2D(), STK::Array2D< TYPE >::Array2D(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::at(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::atRow(), STK::Svd::bidiag(), STK::EigenValues::compHouse(), STK::IArray2DBase< Real, Real *, ArrayHo< Real >, Array1D< Real >, MatrixUpperTriangular >::IArray2DBase(), STK::MatrixLowerTriangular::MatrixLowerTriangular(), STK::MatrixUpperTriangular::MatrixUpperTriangular(), STK::Array2D< Real >::operator=(), STK::Array2D< TYPE >::operator=(), and STK::EigenValues::tridiag().
00161 { return rangeVe_.first();}
| Integer STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::lastRow | ( | ) | const [inline] |
Index of the last row.
Definition at line 164 of file STK_ITContainer2D.h.
Referenced by STK::Array2D< Real >::Array2D(), STK::Array2D< TYPE >::Array2D(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::at(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::atRow(), STK::Svd::bidiag(), STK::EigenValues::compHouse(), STK::Qr::eraseCol(), STK::IArray2DBase< Real, Real *, ArrayHo< Real >, Array1D< Real >, MatrixUpperTriangular >::IArray2DBase(), STK::Qr::insertCol(), STK::leftHouseholder(), STK::MatrixLowerTriangular::MatrixLowerTriangular(), STK::MatrixUpperTriangular::MatrixUpperTriangular(), STK::Array2D< Real >::operator=(), STK::Array2D< TYPE >::operator=(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::resize(), STK::rightHouseholder(), and STK::EigenValues::tridiag().
00164 { return rangeVe_.last();}
| Integer STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::getSizeVe | ( | ) | const [inline] |
Number of rows.
Definition at line 167 of file STK_ITContainer2D.h.
Referenced by STK::Qr::eraseCol().
00167 { return rangeVe_.size();}
| Inx const& STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::getRangeVe | ( | ) | const [inline] |
Range of the rows of the container.
Definition at line 170 of file STK_ITContainer2D.h.
Referenced by STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::atCol(), STK::Svd::bidiag(), STK::Qr::insertCol(), STK::MatrixUpperTriangular::operator=(), STK::MatrixLowerTriangular::operator=(), STK::Array2D< Real >::operator=(), STK::Array2D< TYPE >::operator=(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::operator[](), STK::Qr::pushBackCol(), STK::IArray2DBase< Real, Real *, ArrayHo< Real >, Array1D< Real >, MatrixUpperTriangular >::swap(), and STK::EigenValues::tridiag().
00170 { return rangeVe_;}
| bool STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::empty | ( | ) | const [inline] |
Is there some data ? (nrow and ncol can be negative)
Definition at line 173 of file STK_ITContainer2D.h.
Referenced by STK::Qr::compQr(), STK::Svd::compSvd(), STK::EigenValues::diagsym(), STK::EigenValues::EigenValues(), and STK::Svd::init().
| TYPE& STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::operator() | ( | const Integer & | i, | |
| const Integer | j | |||
| ) | [inline] |
Operator () : access to one element.
| i | index of the row | |
| j | index of the col |
Definition at line 182 of file STK_ITContainer2D.h.
00183 { return this->asLeaf().getElt(i,j);}
| const TYPE& STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::operator() | ( | Integer | i, | |
| Integer | j | |||
| ) | const [inline] |
Operator () : access to one element for const.
| i | index of the row | |
| j | index of the col |
Definition at line 189 of file STK_ITContainer2D.h.
00190 { return this->asLeaf().getElt(i,j);}
| TContainerVe STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::operator[] | ( | Integer | j | ) | const [inline] |
Operator [] : access to one col.
| j | index of the col |
Definition at line 195 of file STK_ITContainer2D.h.
00196 { return this->asLeaf().getCol(this->getRangeVe(), j);}
| TContainerVe STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::operator() | ( | const Inx & | I, | |
| Integer | j | |||
| ) | const [inline] |
Operator () : access to many elements of a col.
| I | range of the index of the rows | |
| j | index of the col |
Definition at line 202 of file STK_ITContainer2D.h.
00203 { return this->asLeaf().getCol(I, j);}
| TContainerHo STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::operator() | ( | Integer | i | ) | const [inline] |
Operator () : access to one row.
| i | index of the row |
Definition at line 208 of file STK_ITContainer2D.h.
00209 { return this->asLeaf().getRow(i, this->getRangeHo());}
| TContainerHo STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::operator() | ( | Integer | i, | |
| const Inx & | J | |||
| ) | const [inline] |
Operator () : access to many elements of a row.
| i | index of the row | |
| J | index of the col |
Definition at line 215 of file STK_ITContainer2D.h.
00216 { return this->asLeaf().getRow(i, J);}
| TContainer2D STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::operator() | ( | const Inx & | I, | |
| const Inx & | J | |||
| ) | const [inline] |
Operator () : access to a sub-array.
| I | range of the index of the rows | |
| J | range of the index of the cols |
Definition at line 222 of file STK_ITContainer2D.h.
00223 { return this->asLeaf().get2D(I, J);}
| TContainer2D STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::operator() | ( | const Inx & | I | ) | const [inline] |
Operator () : access to many rows.
| I | range of the index of the rows |
Definition at line 228 of file STK_ITContainer2D.h.
00229 { return this->asLeaf().get2D(I, this->getRangeHo());}
| TContainer2D STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::operator[] | ( | const Inx & | J | ) | const [inline] |
Operator [] : access to many cols.
| J | range of the index of the cols |
Definition at line 234 of file STK_ITContainer2D.h.
00235 { return this->asLeaf().get2D(this->getRangeVe(), J);}
| TYPE& STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::at | ( | Integer | i, | |
| Integer | j | |||
| ) | [inline] |
STL compatibility : return the element (i, j).
| i | index of the row | |
| j | index of the col |
Definition at line 243 of file STK_ITContainer2D.h.
00244 { 00245 if (this->firstRow() > i) 00246 { throw std::out_of_range("TContainer2D::at(i, j) " 00247 "this->firstRow() > i"); 00248 } 00249 if (this->lastRow() < i) 00250 { throw std::out_of_range("TContainer2D::at(i, j) " 00251 "this->lastRow() < i"); 00252 } 00253 if (this->firstCol() > j) 00254 { throw std::out_of_range("TContainer2D::at(i, j) " 00255 "this->firstCol() > j"); 00256 } 00257 if (this->lastCol() < j) 00258 { throw std::out_of_range("TContainer2D::at(i, j) " 00259 "this->lastCol() < j"); 00260 } 00261 return this->asLeaf().getElt(i, j); 00262 }
| const TYPE& STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::at | ( | Integer | i, | |
| Integer | j | |||
| ) | const [inline] |
STL compatibility : return the const element (i, j).
| i | index of the row | |
| j | index of the col |
Definition at line 268 of file STK_ITContainer2D.h.
00269 { 00270 if (this->firstRow() > i) 00271 { throw std::out_of_range("TContainer2D::at(i, j) " 00272 "this->firstRow() > i"); 00273 } 00274 if (this->lastRow() < i) 00275 { throw std::out_of_range("TContainer2D::at(i, j) " 00276 "this->lastRow() < i"); 00277 } 00278 if (this->firstCol() > j) 00279 { throw std::out_of_range("TContainer2D::at(i, j) " 00280 "this->firstCol() > j"); 00281 } 00282 if (this->lastCol() < j) 00283 { throw std::out_of_range("TContainer2D::at(i, j) " 00284 "this->lastCol() < j"); 00285 } 00286 return this->asLeaf().getElt(i, j); 00287 }
| TContainer2D STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::at | ( | const Inx & | I, | |
| const Inx & | J | |||
| ) | [inline] |
STL compatibility : return a sub-Array.
| I | range of the index of the rows | |
| J | range of the index of the cols |
Definition at line 293 of file STK_ITContainer2D.h.
00294 { 00295 if (this->firstRow() > I.first()) 00296 { throw std::out_of_range("TContainer2D::at(I, J) " 00297 "this->firstRow() > I.first()"); 00298 } 00299 if (this->lastRow() < I.last()) 00300 { throw std::out_of_range("TContainer2D::at(I, J) " 00301 "this->lastRow() < I.last()"); 00302 } 00303 if (this->firstCol() > J.first()) 00304 { throw std::out_of_range("TContainer2D::at(I, J) " 00305 "this->firstCol() > J.first()"); 00306 } 00307 if (this->lastCol() < J.last()) 00308 { throw std::out_of_range("TContainer2D::at(I, J) " 00309 "this->lastCol() < J.last()"); 00310 } 00311 return this->asLeaf().get2D(I, J); 00312 }
| TContainerVe STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::at | ( | const Inx & | I, | |
| Integer | j | |||
| ) | [inline] |
STL compatibility : return a part of the col j in the range I.
| I | range of the index of the rows | |
| j | index of the col |
Definition at line 318 of file STK_ITContainer2D.h.
00319 { 00320 if (this->firstRow() > I.first()) 00321 { throw std::out_of_range("TContainer2D::at(I, j) " 00322 "this->firstRow() > I.first()"); 00323 } 00324 if (this->lastRow() < I.last()) 00325 { throw std::out_of_range("TContainer2D::at(I, j) " 00326 "this->lastRow() < I.last()"); 00327 } 00328 if (this->firstCol() > j) 00329 { throw std::out_of_range("TContainer2D::at(I, j) " 00330 "this->firstCol() > j"); 00331 } 00332 if (this->lastCol() < j) 00333 { throw std::out_of_range("TContainer2D::at(I, j) " 00334 "this->lastCol() < j"); 00335 } 00336 return this->asLeaf().getCol(I, j); 00337 }
| TContainerHo STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::at | ( | Integer | i, | |
| const Inx & | J | |||
| ) | const [inline] |
STL compatibility : return a part of the row i in the range J.
| i | index of the row | |
| J | range of the index of the cols |
Definition at line 343 of file STK_ITContainer2D.h.
00344 { 00345 if (this->firstRow() > i) 00346 { throw std::out_of_range("TContainer2D::at(i, J) " 00347 "this->firstRow() > i"); 00348 } 00349 if (this->lastRow() < i) 00350 { throw std::out_of_range("TContainer2D::at(i, J) " 00351 "this->lastRow() < i"); 00352 } 00353 if (this->firstCol() > J.first()) 00354 { throw std::out_of_range("TContainer2D::at(i, J) " 00355 "this->firstCol() > J.first()"); 00356 } 00357 if (this->lastCol() < J.last()) 00358 { throw std::out_of_range("TContainer2D::at(i, J) " 00359 "this->lastCol() < J.last()"); 00360 } 00361 return this->asLeaf().getRow(J, i); 00362 }
| TContainerVe STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::atCol | ( | Integer | j | ) | [inline] |
STL compatibility : return the column j.
| j | index of the col |
Definition at line 367 of file STK_ITContainer2D.h.
00368 { 00369 if (this->firstCol() > j) 00370 { throw std::out_of_range("TContainer2D::atCol(j) " 00371 "this->firstCol() > j"); 00372 } 00373 if (this->lastCol() < j) 00374 { throw std::out_of_range("TContainer2D::atCol(j) " 00375 "this->lastCol() < j"); 00376 } 00377 return this->asLeaf().getCol(this->getRangeVe(), j); 00378 }
| TContainer2D STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::atCol | ( | const Inx & | J | ) | [inline] |
STL compatibility : return the Container2D in col range J.
| J | range of the index of the cols |
Definition at line 383 of file STK_ITContainer2D.h.
00384 { 00385 if (this->firstCol() > J.first()) 00386 { throw std::out_of_range("TContainer2D::atCol(J) " 00387 "this->firstCol() > J.first()"); 00388 } 00389 if (this->lastCol() < J.last()) 00390 { throw std::out_of_range("TContainer2D::atCol(J) " 00391 "this->lastCol() < J.last()"); 00392 } 00393 return this->asLeaf().get2D(this->getRangeVe(), J); 00394 }
| TContainerHo STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::atRow | ( | Integer | i | ) | const [inline] |
STL compatibility : return the row i.
| i | the index of the row |
Definition at line 399 of file STK_ITContainer2D.h.
00400 { 00401 if (this->firstRow() > i) 00402 { throw std::out_of_range("TContainer2D::atRow(i) " 00403 "this->firstRow() > i"); 00404 } 00405 if (this->lastRow() < i) 00406 { throw std::out_of_range("TContainer2D::atRow(i) " 00407 "this->lastRow() < i"); 00408 } 00409 return this->asLeaf().getRow(i, this->getRangeHo()); 00410 }
| TContainer2D STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::atRow | ( | const Inx & | I | ) | const [inline] |
STL compatibility : return the Container2D in the row range I.
| I | range of the index of the rows |
Definition at line 415 of file STK_ITContainer2D.h.
00416 { 00417 if (this->firstRow() > I.first()) 00418 { throw std::out_of_range("TContainer2D::atRow(I) " 00419 "this->firstRow() > I.first()"); 00420 } 00421 if (this->lastRow() < I.last()) 00422 { throw std::out_of_range("TContainer2D::atRow(I) " 00423 "this->lastRow() < I.last()"); 00424 } 00425 return this->asLeaf().get2D(I, this->getRangeHo()); 00426 }
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::resize | ( | const Inx & | I = Inx(), |
|
| const Inx & | J = Inx() | |||
| ) | [inline] |
resize the container:
NewFirst(I.first(), J.first()insertCols() (insertRows()) and/or popBackCols() (popBackRows()). | I | the new range of the number of rows | |
| J | the new range of the number of cols |
Reimplemented in STK::MatrixSquare.
Definition at line 436 of file STK_ITContainer2D.h.
Referenced by STK::Qr::qr().
00437 { 00438 // check if there is something to do 00439 if ((rangeVe_ == I) && (rangeHo_ == J)) return; 00440 // translate beg 00441 this->asLeaf().shift(I.first(), J.first()); 00442 // number of rows to del or add 00443 Integer rinc = I.last() - lastRow(); 00444 // number of cols to del or add 00445 Integer cinc = J.last() - lastCol(); 00446 // check if we add cols 00447 if (cinc >=0) // work first on rows 00448 { 00449 if (rinc < 0) this->asLeaf().popBackRows(-rinc); 00450 else this->asLeaf().pushBackRows(rinc); 00451 this->asLeaf().pushBackCols(cinc); 00452 } 00453 else // work first on cols 00454 { 00455 this->asLeaf ().popBackCols(-cinc); // less cols 00456 if (rinc < 0) this->asLeaf().popBackRows(-rinc); // less rows 00457 else this->asLeaf().pushBackRows(rinc); // more rows 00458 } 00459 }
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::pop_back_col | ( | ) | [inline] |
STL compatibility. pop back last col to the container.
Definition at line 465 of file STK_ITContainer2D.h.
00466 { this->asLeaf().popBackCols();}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::pop_back_row | ( | ) | [inline] |
STL compatibility. pop back last col to the container.
Definition at line 470 of file STK_ITContainer2D.h.
00471 { this->asLeaf().popBackRows();}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::setRange | ( | const Inx & | I = Inx(), |
|
| const Inx & | J = Inx() | |||
| ) | [inline, protected] |
Set range of the container.
| I | the vertical range | |
| J | the horizontal range |
Definition at line 478 of file STK_ITContainer2D.h.
Referenced by STK::IArray2DBase< Real, Real *, ArrayHo< Real >, Array1D< Real >, MatrixUpperTriangular >::swap().
00479 { 00480 setRangeVe(I); 00481 setRangeHo(J); 00482 }
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::setRangeVe | ( | const Inx & | I = Inx() |
) | [inline, protected] |
Set the range of the number of rows.
| I | the range of the rows number |
Definition at line 487 of file STK_ITContainer2D.h.
Referenced by STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::setRange().
00488 { rangeVe_ = I;}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::incRangeVe | ( | const Integer & | inc = 1 |
) | [inline, protected] |
Increment the range of the number of rows.
| inc | the increment to apply |
Definition at line 493 of file STK_ITContainer2D.h.
00494 { rangeVe_.inc(inc);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::decRangeVe | ( | const Integer & | dec = 1 |
) | [inline, protected] |
Decrement range of the number of rows.
| dec | the decrement to apply |
Definition at line 499 of file STK_ITContainer2D.h.
00500 { rangeVe_.dec(dec);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::setFirstVe | ( | const Integer & | beg = 1 |
) | [inline, protected] |
Set the beginning of the rows.
| beg | the first index of the rows |
Definition at line 505 of file STK_ITContainer2D.h.
00506 { rangeVe_.shift(beg);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::incFirstVe | ( | const Integer & | inc = 1 |
) | [inline, protected] |
Increment the beginning of the number of rows.
| inc | the increment to apply |
Definition at line 511 of file STK_ITContainer2D.h.
00512 { rangeVe_.incFirst(inc);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::decFirstVe | ( | const Integer & | dec = 1 |
) | [inline, protected] |
Decrement the beginning of the number of rows.
| dec | the decrement to apply |
Definition at line 517 of file STK_ITContainer2D.h.
00518 { rangeVe_.decFirst(dec);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::incLastVe | ( | const Integer & | inc = 1 |
) | [inline, protected] |
Increment the end of the number of rows.
| inc | the increment to apply |
Definition at line 523 of file STK_ITContainer2D.h.
00524 { rangeVe_.incLast(inc);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::decLastVe | ( | const Integer & | dec = 1 |
) | [inline, protected] |
Decrement the end of the number of rows.
| dec | the decrement to apply |
Definition at line 529 of file STK_ITContainer2D.h.
00530 { rangeVe_.decLast(dec);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::infVe | ( | const Inx & | I = Inx() |
) | [inline, protected] |
Set the inf of the range of the rows and of I.
| I | the range to apply |
Definition at line 535 of file STK_ITContainer2D.h.
00536 { rangeVe_.inf(I);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::supve | ( | const Inx & | I = Inx() |
) | [inline, protected] |
Set the sup of the range of the rows and of I.
| I | the range to apply |
Definition at line 541 of file STK_ITContainer2D.h.
00542 { rangeVe_.sup(I);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::setRangeHo | ( | const Inx & | J = Inx() |
) | [inline, protected] |
Set the range of the cols.
| J | the range of the cols number |
Definition at line 547 of file STK_ITContainer2D.h.
Referenced by STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::setRange().
00548 { rangeHo_ = J;}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::incRangeHo | ( | const Integer & | inc = 1 |
) | [inline, protected] |
Increment the range of the number of cols.
| inc | the increment to apply |
Definition at line 553 of file STK_ITContainer2D.h.
00554 { rangeHo_.inc(inc);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::decRangeHo | ( | const Integer & | dec = 1 |
) | [inline, protected] |
Decrement range of the number of cols.
| dec | the decrement to apply |
Definition at line 559 of file STK_ITContainer2D.h.
00560 { rangeHo_.dec(dec);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::setFirstHo | ( | const Integer & | beg = 1 |
) | [inline, protected] |
Set the beginning of the number of cols.
| beg | the new first index |
Definition at line 565 of file STK_ITContainer2D.h.
00566 { rangeHo_.shift(beg);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::incFirstHo | ( | const Integer & | inc = 1 |
) | [inline, protected] |
inc the beginning of the number of cols.
| inc | the increment to apply |
Definition at line 571 of file STK_ITContainer2D.h.
00572 { rangeHo_.incFirst(inc);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::decFirstHo | ( | const Integer & | dec = 1 |
) | [inline, protected] |
Decrement the beginning of the number of cols.
| dec | the decrement to apply |
Definition at line 577 of file STK_ITContainer2D.h.
00578 { rangeHo_.decFirst(dec);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::incLastHo | ( | const Integer & | inc = 1 |
) | [inline, protected] |
Increment the end of the number of cols.
| inc | the increment to apply |
Definition at line 583 of file STK_ITContainer2D.h.
00584 { rangeHo_.incLast(inc);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::decLastHo | ( | const Integer & | dec = 1 |
) | [inline, protected] |
Decrement the end of the number of cols.
| dec | the decrement to apply |
Definition at line 589 of file STK_ITContainer2D.h.
00590 { rangeHo_.decLast(dec);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::infHo | ( | const Inx & | J = Inx() |
) | [inline, protected] |
Set the inf of the range of the cols and of I.
| J | the range to apply |
Definition at line 595 of file STK_ITContainer2D.h.
00596 { rangeHo_.inf(J);}
| void STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::supHo | ( | const Inx & | J = Inx() |
) | [inline, protected] |
Set the sup of the range of the cols and of I.
| J | the range to apply |
Definition at line 601 of file STK_ITContainer2D.h.
00602 { rangeHo_.sup(J);}
Inx STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::rangeHo_ [private] |
Definition at line 111 of file STK_ITContainer2D.h.
Referenced by STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::decFirstHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::decLastHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::decRangeHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::empty(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::firstCol(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::getRangeHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::getSizeHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::incFirstHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::incLastHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::incRangeHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::infHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::lastCol(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::resize(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::setFirstHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::setRangeHo(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::sizeHo(), and STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::supHo().
Inx STK::ITContainer2D< TYPE, TContainerHo, TContainerVe, TContainer2D >::rangeVe_ [private] |
Definition at line 112 of file STK_ITContainer2D.h.
Referenced by STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::decFirstVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::decLastVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::decRangeVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::empty(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::firstRow(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::getRangeVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::getSizeVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::incFirstVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::incLastVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::incRangeVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::infVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::lastRow(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::resize(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::setFirstVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::setRangeVe(), STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::sizeVe(), and STK::ITContainer2D< TYPE, TArrayHo, TArrayVe, TArray2D >::supve().
1.5.8