operator_cube_times.hpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 template<typename T1>
00025 arma_inline
00026 const OpCube<T1, op_scalar_times>
00027 operator*
00028 (const BaseCube<typename T1::elem_type,T1>& X, const typename T1::elem_type k)
00029 {
00030 arma_extra_debug_sigprint();
00031
00032 return OpCube<T1, op_scalar_times>(X.get_ref(),k);
00033 }
00034
00035
00036
00037
00038 template<typename T1>
00039 arma_inline
00040 const OpCube<T1,op_scalar_times>
00041 operator*
00042 (const OpCube<T1,op_scalar_times>& X, const typename T1::elem_type k)
00043 {
00044 arma_extra_debug_sigprint();
00045
00046 return OpCube<T1, op_scalar_times>(X.m, X.aux * k);
00047 }
00048
00049
00050
00051
00052 template<typename eT>
00053 arma_inline
00054 Cube<eT>
00055 operator*
00056 (const OpCube<Cube<eT>,op_ones_full>& X, const eT k)
00057 {
00058 arma_extra_debug_sigprint();
00059
00060 Cube<eT> tmp(X.aux_u32_a, X.aux_u32_b, X.aux_u32_c);
00061 tmp.fill(k);
00062
00063 return tmp;
00064 }
00065
00066
00067
00068
00069 template<typename T1>
00070 arma_inline
00071 const OpCube<T1, op_scalar_times>
00072 operator*
00073 (const typename T1::elem_type k, const BaseCube<typename T1::elem_type,T1>& X)
00074 {
00075 arma_extra_debug_sigprint();
00076
00077 return OpCube<T1, op_scalar_times>(X.get_ref(),k);
00078 }
00079
00080
00081
00082
00083 template<typename eT>
00084 arma_inline
00085 Cube<eT>
00086 operator*
00087 (const eT k, const OpCube<Cube<eT>,op_ones_full>& X)
00088 {
00089 arma_extra_debug_sigprint();
00090
00091 Cube<eT> tmp(X.aux_u32_a, X.aux_u32_b, X.aux_u32_c);
00092 tmp.fill(k);
00093
00094 return tmp;
00095 }
00096
00097
00098
00099