fn_randn.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 inline
00023 const Op<mat, op_randn>
00024 randn(const u32 n_rows, const u32 n_cols)
00025 {
00026 arma_extra_debug_sigprint();
00027
00028 return Op<mat, op_randn>(n_rows, n_cols, 'j');
00029 }
00030
00031
00032
00033 template<typename mat_type>
00034 inline
00035 const Op<mat_type,op_randn>
00036 randn(const u32 n_rows, const u32 n_cols)
00037 {
00038 arma_extra_debug_sigprint();
00039
00040 arma_type_check<is_Mat<mat_type>::value == false>::apply();
00041
00042 return Op<mat_type,op_randn>(n_rows, n_cols, 'j');
00043 }
00044
00045
00046
00047
00048 inline
00049 const Op<colvec, op_randn>
00050 randn(const u32 n_elem)
00051 {
00052 arma_extra_debug_sigprint();
00053
00054 return Op<colvec, op_randn>(n_elem, 1, 'j');
00055 }
00056
00057
00058
00059 template<typename vec_type>
00060 inline
00061 const Op<vec_type,op_randn>
00062 randn(const u32 n_elem)
00063 {
00064 arma_extra_debug_sigprint();
00065
00066 arma_type_check< (is_Col<vec_type>::value == false) && (is_Row<vec_type>::value == false) >::apply();
00067
00068 return Op<vec_type,op_randn>(n_elem, 0, 'j');
00069 }
00070
00071