Col_meat.hpp

Go to the documentation of this file.
00001 // Copyright (C) 2010 NICTA and the authors listed below
00002 // http://nicta.com.au
00003 // 
00004 // Authors:
00005 // - Conrad Sanderson (conradsand at ieee dot org)
00006 // 
00007 // This file is part of the Armadillo C++ library.
00008 // It is provided without any warranty of fitness
00009 // for any purpose. You can redistribute this file
00010 // and/or modify it under the terms of the GNU
00011 // Lesser General Public License (LGPL) as published
00012 // by the Free Software Foundation, either version 3
00013 // of the License or (at your option) any later version.
00014 // (see http://www.opensource.org/licenses for more info)
00015 
00016 
00017 //! \addtogroup Col
00018 //! @{
00019 
00020 
00021 //! construct an empty column vector
00022 template<typename eT>
00023 inline
00024 Col<eT>::Col()
00025   : Mat<eT>()
00026   {
00027   arma_extra_debug_sigprint();
00028   }
00029 
00030 
00031 
00032 //! construct a column vector with the specified number of n_elem
00033 template<typename eT>
00034 inline
00035 Col<eT>::Col(const u32 in_n_elem)
00036   : Mat<eT>(in_n_elem, 1)
00037   {
00038   arma_extra_debug_sigprint();
00039   }
00040 
00041 
00042 
00043 template<typename eT>
00044 inline
00045 Col<eT>::Col(const u32 in_n_rows, const u32 in_n_cols)
00046   : Mat<eT>(in_n_rows, in_n_cols)
00047   {
00048   arma_extra_debug_sigprint();
00049   
00050   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00051   }
00052 
00053 
00054 
00055 //! construct a column vector from specified text
00056 template<typename eT>
00057 inline
00058 Col<eT>::Col(const char* text)
00059   : Mat<eT>(text)
00060   {
00061   arma_extra_debug_sigprint();
00062   
00063   std::swap( access::rw(Mat<eT>::n_rows), access::rw(Mat<eT>::n_cols) );
00064   
00065   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00066   }
00067 
00068 
00069 
00070 //! construct a column vector from specified text
00071 template<typename eT>
00072 inline
00073 const Col<eT>&
00074 Col<eT>::operator=(const char* text)
00075   {
00076   arma_extra_debug_sigprint();
00077   
00078   Mat<eT>::operator=(text);
00079   
00080   std::swap( access::rw(Mat<eT>::n_rows), access::rw(Mat<eT>::n_cols) );
00081   
00082   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00083   
00084   return *this;
00085   }
00086 
00087 
00088 
00089 //! construct a column vector from specified text
00090 template<typename eT>
00091 inline
00092 Col<eT>::Col(const std::string& text)
00093   : Mat<eT>(text)
00094   {
00095   arma_extra_debug_sigprint();
00096   
00097   std::swap( access::rw(Mat<eT>::n_rows), access::rw(Mat<eT>::n_cols) );
00098   
00099   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00100   }
00101 
00102 
00103 
00104 //! construct a column vector from specified text
00105 template<typename eT>
00106 inline
00107 const Col<eT>&
00108 Col<eT>::operator=(const std::string& text)
00109   {
00110   arma_extra_debug_sigprint();
00111   
00112   Mat<eT>::operator=(text);
00113   
00114   std::swap( access::rw(Mat<eT>::n_rows), access::rw(Mat<eT>::n_cols) );
00115   
00116   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00117   
00118   return *this;
00119   }
00120 
00121 
00122 
00123 //! construct a column vector from a given column vector
00124 template<typename eT>
00125 inline
00126 Col<eT>::Col(const Col<eT>& X)
00127   : Mat<eT>(X)
00128   {
00129   arma_extra_debug_sigprint();
00130   }
00131 
00132 
00133 
00134 //! construct a column vector from a given column vector
00135 template<typename eT>
00136 inline
00137 const Col<eT>&
00138 Col<eT>::operator=(const Col<eT>& X)
00139   {
00140   arma_extra_debug_sigprint();
00141   
00142   Mat<eT>::operator=(X);
00143   
00144   return *this;
00145   }
00146 
00147 
00148 
00149 //! construct a column vector from a given matrix; the matrix must have exactly one column
00150 template<typename eT>
00151 inline
00152 Col<eT>::Col(const Mat<eT>& X)
00153   : Mat<eT>(X)
00154   {
00155   arma_extra_debug_sigprint();
00156   
00157   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00158   }
00159 
00160 
00161 
00162 //! construct a column vector from a given matrix; the matrix must have exactly one column
00163 template<typename eT>
00164 inline
00165 const Col<eT>&
00166 Col<eT>::operator=(const Mat<eT>& X)
00167   {
00168   arma_extra_debug_sigprint();
00169   
00170   Mat<eT>::operator=(X);
00171   
00172   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00173   
00174   return *this;
00175   }
00176 
00177 
00178 
00179 template<typename eT>
00180 inline
00181 const Col<eT>&
00182 Col<eT>::operator*=(const Mat<eT>& X)
00183   {
00184   arma_extra_debug_sigprint();
00185   
00186   Mat<eT>::operator*=(X);
00187   
00188   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00189   
00190   return *this;
00191   }
00192 
00193 
00194 
00195 //! construct a column vector from a given auxiliary array of eTs
00196 template<typename eT>
00197 inline
00198 Col<eT>::Col(eT* aux_mem, const u32 aux_n_rows, const u32 aux_n_cols, const bool copy_aux_mem)
00199   : Mat<eT>(aux_mem, aux_n_rows, aux_n_cols, copy_aux_mem)
00200   {
00201   arma_extra_debug_sigprint();
00202   
00203   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00204   }
00205 
00206 
00207 
00208 //! construct a column vector from a given auxiliary array of eTs
00209 template<typename eT>
00210 inline
00211 Col<eT>::Col(const eT* aux_mem, const u32 aux_n_rows, const u32 aux_n_cols)
00212   : Mat<eT>(aux_mem, aux_n_rows, aux_n_cols)
00213   {
00214   arma_extra_debug_sigprint();
00215   
00216   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00217   }
00218 
00219 
00220 
00221 //! construct a column vector from a given auxiliary array of eTs
00222 template<typename eT>
00223 inline
00224 Col<eT>::Col(eT* aux_mem, const u32 aux_length, const bool copy_aux_mem)
00225   : Mat<eT>(aux_mem, aux_length, 1, copy_aux_mem)
00226   {
00227   arma_extra_debug_sigprint();
00228   
00229 //   set_size(aux_length, 1);
00230 // 
00231 //   arma_check( (Mat<eT>::n_elem != aux_length), "Col::Col(): don't know how to handle the given array" );
00232 // 
00233 //   syslib::copy_elem( Mat<eT>::memptr(), aux_mem, Mat<eT>::n_elem );
00234   }
00235 
00236 
00237 
00238 //! construct a column vector from a given auxiliary array of eTs
00239 template<typename eT>
00240 inline
00241 Col<eT>::Col(const eT* aux_mem, const u32 aux_length)
00242   : Mat<eT>(aux_mem, aux_length, 1)
00243   {
00244   arma_extra_debug_sigprint();
00245   
00246 //   set_size(aux_length, 1);
00247 // 
00248 //   arma_check( (Mat<eT>::n_elem != aux_length), "Col::Col(): don't know how to handle the given array" );
00249 // 
00250 //   syslib::copy_elem( Mat<eT>::memptr(), aux_mem, Mat<eT>::n_elem );
00251   }
00252 
00253 
00254 
00255 template<typename eT>
00256 template<typename T1, typename T2>
00257 inline
00258 Col<eT>::Col
00259   (
00260   const Base<typename Col<eT>::pod_type, T1>& A,
00261   const Base<typename Col<eT>::pod_type, T2>& B
00262   )
00263   : Mat<eT>(A,B)
00264   {
00265   arma_extra_debug_sigprint();
00266   
00267   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00268   }
00269 
00270 
00271 
00272 //! construct a column vector from given a submatrix; the submatrix must have exactly one column
00273 template<typename eT>
00274 inline
00275 Col<eT>::Col(const subview<eT>& X)
00276   : Mat<eT>(X)
00277   {
00278   arma_extra_debug_sigprint();
00279   
00280   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00281   }
00282 
00283 
00284 
00285 //! construct a column vector from given a submatrix; the submatrix must have exactly one column
00286 template<typename eT>
00287 inline
00288 const Col<eT>&
00289 Col<eT>::operator=(const subview<eT>& X)
00290   {
00291   arma_extra_debug_sigprint();
00292   
00293   Mat<eT>::operator=(X);
00294   
00295   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00296   
00297   return *this;
00298   }
00299 
00300 
00301 
00302 template<typename eT>
00303 inline
00304 const Col<eT>&
00305 Col<eT>::operator*=(const subview<eT>& X)
00306   {
00307   arma_extra_debug_sigprint();
00308   
00309   Mat<eT>::operator*=(X);
00310   
00311   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00312   
00313   return *this;
00314   }
00315 
00316 
00317 
00318 //! construct a column vector from given a subcube; the subcube must have exactly one column
00319 template<typename eT>
00320 inline
00321 Col<eT>::Col(const subview_cube<eT>& X)
00322   : Mat<eT>(X)
00323   {
00324   arma_extra_debug_sigprint();
00325   
00326   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00327   }
00328 
00329 
00330 
00331 //! construct a column vector from given a subcube; the subcube must have exactly one column
00332 template<typename eT>
00333 inline
00334 const Col<eT>&
00335 Col<eT>::operator=(const subview_cube<eT>& X)
00336   {
00337   arma_extra_debug_sigprint();
00338   
00339   Mat<eT>::operator=(X);
00340   
00341   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00342   
00343   return *this;
00344   }
00345 
00346 
00347 
00348 template<typename eT>
00349 inline
00350 const Col<eT>&
00351 Col<eT>::operator*=(const subview_cube<eT>& X)
00352   {
00353   arma_extra_debug_sigprint();
00354   
00355   Mat<eT>::operator*=(X);
00356   
00357   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00358   
00359   return *this;
00360   }
00361 
00362 
00363 
00364 //! construct a column vector from given a diagview
00365 template<typename eT>
00366 inline
00367 Col<eT>::Col(const diagview<eT>& X)
00368   : Mat<eT>(X)
00369   {
00370   arma_extra_debug_sigprint();
00371   
00372   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00373   }
00374 
00375 
00376 
00377 //! construct a column vector from given a diagview
00378 template<typename eT>
00379 inline
00380 const Col<eT>&
00381 Col<eT>::operator=(const diagview<eT>& X)
00382   {
00383   arma_extra_debug_sigprint();
00384   
00385   Mat<eT>::operator=(X);
00386   
00387   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00388   
00389   return *this;
00390   }
00391 
00392 
00393 
00394 template<typename eT>
00395 inline
00396 const Col<eT>&
00397 Col<eT>::operator*=(const diagview<eT>& X)
00398   {
00399   arma_extra_debug_sigprint();
00400   
00401   Mat<eT>::operator*=(X);
00402   
00403   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00404   
00405   return *this;
00406   }
00407 
00408 
00409 
00410 template<typename eT>
00411 arma_inline
00412 eT&
00413 Col<eT>::row(const u32 row_num)
00414   {
00415   arma_debug_check( (row_num >= Mat<eT>::n_rows), "Col::row(): out of bounds" );
00416   
00417   return access::rw(Mat<eT>::mem[row_num]);
00418   }
00419 
00420 
00421 
00422 template<typename eT>
00423 arma_inline
00424 eT
00425 Col<eT>::row(const u32 row_num)
00426   const
00427   {
00428   arma_debug_check( (row_num >= Mat<eT>::n_rows), "Col::row(): out of bounds" );
00429   
00430   return Mat<eT>::mem[row_num];
00431   }
00432 
00433 
00434 
00435 template<typename eT>
00436 arma_inline
00437 subview_col<eT>
00438 Col<eT>::rows(const u32 in_row1, const u32 in_row2)
00439   {
00440   arma_debug_check( ( (in_row1 > in_row2) || (in_row2 >= Mat<eT>::n_rows) ), "Col::rows(): indices out of bounds or incorrectly used");
00441   
00442   return subview_col<eT>(*this, 0, in_row1, in_row2);
00443   }
00444 
00445 
00446 
00447 template<typename eT>
00448 arma_inline
00449 const subview_col<eT>
00450 Col<eT>::rows(const u32 in_row1, const u32 in_row2)
00451   const
00452   {
00453   arma_debug_check( ( (in_row1 > in_row2) || (in_row2 >= Mat<eT>::n_rows) ), "Col::rows(): indices out of bounds or incorrectly used");
00454   
00455   return subview_col<eT>(*this, 0, in_row1, in_row2);
00456   }
00457 
00458 
00459 
00460 //! construct a column vector from Op, i.e. run the previously delayed operations; the result of the operations must have exactly one column
00461 template<typename eT>
00462 template<typename T1, typename op_type>
00463 inline
00464 Col<eT>::Col(const Op<T1, op_type>& X)
00465   : Mat<eT>(X)
00466   {
00467   arma_extra_debug_sigprint();
00468   
00469   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00470   }
00471 
00472 
00473 
00474 //! construct a column vector from Op, i.e. run the previously delayed operations; the result of the operations must have exactly one column
00475 template<typename eT>
00476 template<typename T1, typename op_type>
00477 inline
00478 const Col<eT>&
00479 Col<eT>::operator=(const Op<T1, op_type>& X)
00480   {
00481   arma_extra_debug_sigprint();
00482   
00483   Mat<eT>::operator=(X);
00484   arma_debug_check( (Mat<eT>::n_cols > 1), "Col::operator=(): given matrix can't be interpreted as a column vector" );
00485   return *this;
00486   }
00487 
00488 
00489 
00490 template<typename eT>
00491 template<typename T1, typename op_type>
00492 inline
00493 const Col<eT>&
00494 Col<eT>::operator*=(const Op<T1, op_type>& X)
00495   {
00496   arma_extra_debug_sigprint();
00497   
00498   Mat<eT>::operator*=(X);
00499   
00500   arma_debug_check( (Mat<eT>::n_cols > 1), "Col::operator=(): incompatible dimensions" );
00501   
00502   return *this;
00503   }
00504 
00505 
00506 
00507 template<typename eT>
00508 template<typename T1, typename eop_type>
00509 inline
00510 Col<eT>::Col(const eOp<T1, eop_type>& X)
00511   : Mat<eT>(X)
00512   {
00513   arma_extra_debug_sigprint();
00514   
00515   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00516   }
00517 
00518 
00519 
00520 template<typename eT>
00521 template<typename T1, typename eop_type>
00522 inline
00523 const Col<eT>&
00524 Col<eT>::operator=(const eOp<T1, eop_type>& X)
00525   {
00526   arma_extra_debug_sigprint();
00527   
00528   Mat<eT>::operator=(X);
00529   arma_debug_check( (Mat<eT>::n_cols > 1), "Col::operator=(): given matrix can't be interpreted as a column vector" );
00530   return *this;
00531   }
00532 
00533 
00534 
00535 template<typename eT>
00536 template<typename T1, typename eop_type>
00537 inline
00538 const Col<eT>&
00539 Col<eT>::operator*=(const eOp<T1, eop_type>& X)
00540   {
00541   arma_extra_debug_sigprint();
00542   
00543   Mat<eT>::operator*=(X);
00544   
00545   arma_debug_check( (Mat<eT>::n_cols > 1), "Col::operator=(): incompatible dimensions" );
00546   
00547   return *this;
00548   }
00549 
00550 
00551 
00552 //! construct a column vector from Glue, i.e. run the previously delayed operations; the result of the operations must have exactly one column
00553 template<typename eT>
00554 template<typename T1, typename T2, typename glue_type>
00555 inline
00556 Col<eT>::Col(const Glue<T1, T2, glue_type>& X)
00557   : Mat<eT>(X)
00558   {
00559   arma_extra_debug_sigprint();
00560   
00561   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00562   }
00563 
00564 
00565 
00566 //! construct a column vector from Glue, i.e. run the previously delayed operations; the result of the operations must have exactly one column
00567 template<typename eT>
00568 template<typename T1, typename T2, typename glue_type>
00569 inline
00570 const Col<eT>&
00571 Col<eT>::operator=(const Glue<T1, T2, glue_type>& X)
00572   {
00573   arma_extra_debug_sigprint();
00574   
00575   Mat<eT>::operator=(X);
00576   
00577   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00578   
00579   return *this;
00580   }
00581 
00582 
00583 
00584 template<typename eT>
00585 template<typename T1, typename T2, typename glue_type>
00586 inline
00587 const Col<eT>&
00588 Col<eT>::operator*=(const Glue<T1, T2, glue_type>& X)
00589   {
00590   arma_extra_debug_sigprint();
00591   
00592   Mat<eT>::operator*=(X);
00593   
00594   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00595   
00596   return *this;
00597   }
00598 
00599 
00600 
00601 template<typename eT>
00602 template<typename T1, typename T2, typename eglue_type>
00603 inline
00604 Col<eT>::Col(const eGlue<T1, T2, eglue_type>& X)
00605   : Mat<eT>(X)
00606   {
00607   arma_extra_debug_sigprint();
00608   
00609   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00610   }
00611 
00612 
00613 
00614 template<typename eT>
00615 template<typename T1, typename T2, typename eglue_type>
00616 inline
00617 const Col<eT>&
00618 Col<eT>::operator=(const eGlue<T1, T2, eglue_type>& X)
00619   {
00620   arma_extra_debug_sigprint();
00621   
00622   Mat<eT>::operator=(X);
00623   
00624   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00625   
00626   return *this;
00627   }
00628 
00629 
00630 
00631 template<typename eT>
00632 template<typename T1, typename T2, typename eglue_type>
00633 inline
00634 const Col<eT>&
00635 Col<eT>::operator*=(const eGlue<T1, T2, eglue_type>& X)
00636   {
00637   arma_extra_debug_sigprint();
00638   
00639   Mat<eT>::operator*=(X);
00640   
00641   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00642   
00643   return *this;
00644   }
00645 
00646 
00647 
00648 //! change the number of rows
00649 template<typename eT>
00650 inline
00651 void
00652 Col<eT>::set_size(const u32 in_n_elem)
00653   {
00654   arma_extra_debug_sigprint();
00655   
00656   Mat<eT>::set_size(in_n_elem,1);
00657   }
00658 
00659 
00660 
00661 //! change the number of n_rows  (this function re-implements mat::set_size() in order to check the number of columns)
00662 template<typename eT>
00663 inline
00664 void
00665 Col<eT>::set_size(const u32 in_n_rows, const u32 in_n_cols)
00666   {
00667   arma_extra_debug_sigprint();
00668 
00669   // min() is used in case in_n_cols is zero
00670   Mat<eT>::set_size( in_n_rows, (std::min)( u32(1), in_n_cols ) );
00671   
00672   arma_debug_check( (in_n_cols > 1), "Col::set_size(): incompatible dimensions" );
00673   }
00674 
00675 
00676 
00677 //! change the number of n_rows  (this function re-implements mat::copy_size() in order to check the number of columns)
00678 template<typename eT>
00679 template<typename eT2>
00680 inline
00681 void
00682 Col<eT>::copy_size(const Mat<eT2>& x)
00683   {
00684   arma_extra_debug_sigprint();
00685   
00686   // min() is used in case x.n_cols is zero
00687   Mat<eT>::set_size( x.n_rows, (std::min)( u32(1), x.n_cols ) );
00688   
00689   arma_debug_check( (x.n_cols > 1), "Col::copy_size(): incompatible dimensions" );
00690   }
00691 
00692 
00693 
00694 template<typename eT>
00695 inline
00696 void
00697 Col<eT>::zeros()
00698   {
00699   arma_extra_debug_sigprint();
00700   
00701   Mat<eT>::zeros();
00702   }
00703 
00704 
00705 
00706 template<typename eT>
00707 inline
00708 void
00709 Col<eT>::zeros(const u32 in_n_elem)
00710   {
00711   arma_extra_debug_sigprint();
00712   
00713   Mat<eT>::zeros(in_n_elem, 1);
00714   }
00715 
00716 
00717 
00718 template<typename eT>
00719 inline
00720 void
00721 Col<eT>::zeros(const u32 in_n_rows, const u32 in_n_cols)
00722   {
00723   arma_extra_debug_sigprint();
00724   
00725   // min() is used in case in_n_cols is zero
00726   Mat<eT>::zeros( in_n_rows, (std::min)( u32(1), in_n_cols ) );
00727   
00728   arma_debug_check( (in_n_cols > 1), "Col::zeros(): incompatible dimensions" );
00729   }
00730 
00731 
00732 
00733 template<typename eT>
00734 inline
00735 void
00736 Col<eT>::ones()
00737   {
00738   arma_extra_debug_sigprint();
00739   
00740   Mat<eT>::ones();
00741   }
00742 
00743 
00744 
00745 template<typename eT>
00746 inline
00747 void
00748 Col<eT>::ones(const u32 in_n_elem)
00749   {
00750   arma_extra_debug_sigprint();
00751   
00752   Mat<eT>::ones(in_n_elem, 1);
00753   }
00754 
00755 
00756 
00757 template<typename eT>
00758 inline
00759 void
00760 Col<eT>::ones(const u32 in_n_rows, const u32 in_n_cols)
00761   {
00762   arma_extra_debug_sigprint();
00763   
00764   // min() is used in case in_n_cols is zero
00765   Mat<eT>::ones( in_n_rows, (std::min)( u32(1), in_n_cols ) );
00766   
00767   arma_debug_check( (in_n_cols > 1), "Col::ones(): incompatible dimensions" );
00768   }
00769 
00770 
00771 
00772 template<typename eT>
00773 inline
00774 void
00775 Col<eT>::load(const std::string name, const file_type type)
00776   {
00777   arma_extra_debug_sigprint();
00778   
00779   Mat<eT>::load(name,type);
00780   
00781   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00782   }
00783 
00784 
00785 
00786 template<typename eT>
00787 inline
00788 void
00789 Col<eT>::load(std::istream& is, const file_type type)
00790   {
00791   arma_extra_debug_sigprint();
00792   
00793   Mat<eT>::load(is, type);
00794   
00795   arma_debug_check( (Mat<eT>::n_cols > 1), "Col(): incompatible dimensions" );
00796   }
00797 
00798 
00799 //! @}