Functions | |
template<typename T1 > | |
const Op< T1, op_max > | max (const Base< typename T1::elem_type, T1 > &X, const u32 dim=0) |
Delayed 'maximum values' operation. The dimension, along which the maxima are found, is set via 'dim'. For dim = 0, the maximum value of each column is found. For dim = 1, the maximum value of each row is found. The default is dim = 0. NOTE: This function works differently than in Matlab/Octave. | |
template<typename eT > | |
eT | max (const Row< eT > &A) |
Immediate 'find the maximum value in a row vector' operation. | |
template<typename eT > | |
eT | max (const Col< eT > &A) |
Immediate 'find the maximum value in a column vector' operation. | |
template<typename T1 > | |
T1::elem_type | max (const Op< T1, op_max > &in) |
Immediate 'find maximum value' operation, invoked, for example, by: max(max(A)). | |
template<typename T1 > | |
const Op< Op< T1, op_max > , op_max > | max (const Op< T1, op_max > &in, const u32 dim) |
template<typename eT > | |
eT | max (const subview_row< eT > &A) |
template<typename eT > | |
eT | max (const subview_col< eT > &A) |
template<typename eT > | |
eT | max (const Op< subview< eT >, op_max > &in) |
template<typename eT > | |
eT | max (const diagview< eT > &A) |
const Op<T1, op_max> max | ( | const Base< typename T1::elem_type, T1 > & | X, | |
const u32 | dim = 0 | |||
) | [inline] |
Delayed 'maximum values' operation. The dimension, along which the maxima are found, is set via 'dim'. For dim = 0, the maximum value of each column is found. For dim = 1, the maximum value of each row is found. The default is dim = 0. NOTE: This function works differently than in Matlab/Octave.
Definition at line 31 of file fn_max.hpp.
References Base< elem_type, derived >::get_ref().
Referenced by auxlib::eig_gen(), auxlib::eig_sym(), auxlib::inv_inplace(), auxlib::inv_noalias(), Math< eT >::log_max(), operator<<(), auxlib::qr(), auxlib::solve_od(), auxlib::solve_ud(), auxlib::svd(), and trunc_exp().
00032 { 00033 arma_extra_debug_sigprint(); 00034 00035 return Op<T1, op_max>(X.get_ref(), dim, 0); 00036 }
eT max | ( | const Row< eT > & | A | ) | [inline] |
Immediate 'find the maximum value in a row vector' operation.
Definition at line 43 of file fn_max.hpp.
References op_max::direct_max(), Mat< eT >::mem, and Mat< eT >::n_elem.
00044 { 00045 arma_extra_debug_sigprint(); 00046 00047 arma_debug_check( (A.n_elem == 0), "max(): given vector has no elements" ); 00048 00049 return op_max::direct_max(A.mem, A.n_elem); 00050 }
eT max | ( | const Col< eT > & | A | ) | [inline] |
Immediate 'find the maximum value in a column vector' operation.
Definition at line 58 of file fn_max.hpp.
References op_max::direct_max(), Mat< eT >::mem, and Mat< eT >::n_elem.
00059 { 00060 arma_extra_debug_sigprint(); 00061 00062 arma_debug_check( (A.n_elem == 0), "max(): given vector has no elements" ); 00063 00064 return op_max::direct_max(A.mem, A.n_elem); 00065 }
Immediate 'find maximum value' operation, invoked, for example, by: max(max(A)).
Definition at line 75 of file fn_max.hpp.
References op_max::direct_max(), Op< T1, op_type >::m, Mat< eT >::mem, and Mat< eT >::n_elem.
00076 { 00077 arma_extra_debug_sigprint(); 00078 arma_extra_debug_print("max(): two consecutive max() calls detected"); 00079 00080 typedef typename T1::elem_type eT; 00081 00082 const unwrap<T1> tmp1(in.m); 00083 const Mat<eT>& X = tmp1.M; 00084 00085 arma_debug_check( (X.n_elem == 0), "max(): given matrix has no elements" ); 00086 00087 return op_max::direct_max(X.mem, X.n_elem); 00088 }
const Op< Op<T1, op_max>, op_max> max | ( | const Op< T1, op_max > & | in, | |
const u32 | dim | |||
) | [inline] |
Definition at line 95 of file fn_max.hpp.
00096 { 00097 arma_extra_debug_sigprint(); 00098 00099 return Op< Op<T1, op_max>, op_max>(in, dim, 0); 00100 }
eT max | ( | const subview_row< eT > & | A | ) | [inline] |
Definition at line 107 of file fn_max.hpp.
References op_max::direct_max(), and subview< eT >::n_elem.
00108 { 00109 arma_extra_debug_sigprint(); 00110 00111 arma_debug_check( (A.n_elem == 0), "max(): given vector has no elements" ); 00112 00113 return op_max::direct_max(A); 00114 }
eT max | ( | const subview_col< eT > & | A | ) | [inline] |
Definition at line 121 of file fn_max.hpp.
References op_max::direct_max(), and subview< eT >::n_elem.
00122 { 00123 arma_extra_debug_sigprint(); 00124 00125 arma_debug_check( (A.n_elem == 0), "max(): given vector has no elements" ); 00126 00127 return op_max::direct_max(A); 00128 }
Definition at line 135 of file fn_max.hpp.
References op_max::direct_max(), and subview< eT >::n_elem.
00136 { 00137 arma_extra_debug_sigprint(); 00138 arma_extra_debug_print("max(): two consecutive max() calls detected"); 00139 00140 const subview<eT>& X = in.m; 00141 00142 arma_debug_check( (X.n_elem == 0), "max(): given matrix has no elements" ); 00143 00144 return op_max::direct_max(X); 00145 }
eT max | ( | const diagview< eT > & | A | ) | [inline] |
Definition at line 152 of file fn_max.hpp.
References op_max::direct_max(), and diagview< eT >::n_elem.
00153 { 00154 arma_extra_debug_sigprint(); 00155 00156 arma_debug_check( (A.n_elem == 0), "max(): given vector has no elements" ); 00157 00158 return op_max::direct_max(A); 00159 }