diff --git a/include/armadillo_bits/fn_rande.hpp b/include/armadillo_bits/fn_rande.hpp index d7c655f4..2e3177d2 100644 --- a/include/armadillo_bits/fn_rande.hpp +++ b/include/armadillo_bits/fn_rande.hpp @@ -47,7 +47,7 @@ rande(const uword n_rows, const uword n_cols, const distr_param& param = distr_p param.get_double_vals(lambda, unused); - arma_conform_check( (lambda <= double(0)), "rande(): incorrect distribution parameters; lambda must be greater than zero" ); + arma_conform_check( ((lambda > double(0)) == false), "rande(): incorrect distribution parameters; lambda must be greater than zero" ); obj_type out(n_rows, n_cols, arma_nozeros_indicator()); @@ -138,7 +138,7 @@ rande(const distr_param& param = distr_param()) param.get_double_vals(lambda, unused); - arma_conform_check( (lambda <= double(0)), "rande(): incorrect distribution parameters; lambda must be greater than zero" ); + arma_conform_check( ((lambda > double(0)) == false), "rande(): incorrect distribution parameters; lambda must be greater than zero" ); double out_val = double(0); @@ -162,7 +162,7 @@ rande(const distr_param& param = distr_param()) param.get_double_vals(lambda, unused); - arma_conform_check( (lambda <= double(0)), "rande(): incorrect distribution parameters; lambda must be greater than zero" ); + arma_conform_check( ((lambda > double(0)) == false), "rande(): incorrect distribution parameters; lambda must be greater than zero" ); eT out_val = eT(0); @@ -189,7 +189,7 @@ rande(const uword n_rows, const uword n_cols, const uword n_slices, const distr_ param.get_double_vals(lambda, unused); - arma_conform_check( (lambda <= double(0)), "rande(): incorrect distribution parameters; lambda must be greater than zero" ); + arma_conform_check( ((lambda > double(0)) == false), "rande(): incorrect distribution parameters; lambda must be greater than zero" ); cube_type out(n_rows, n_cols, n_slices, arma_nozeros_indicator()); diff --git a/include/armadillo_bits/fn_randg.hpp b/include/armadillo_bits/fn_randg.hpp index bacf51ef..5c1cfc2d 100644 --- a/include/armadillo_bits/fn_randg.hpp +++ b/include/armadillo_bits/fn_randg.hpp @@ -47,7 +47,7 @@ randg(const uword n_rows, const uword n_cols, const distr_param& param = distr_p param.get_double_vals(a,b); - arma_conform_check( ((a <= double(0)) || (b <= double(0))), "randg(): incorrect distribution parameters; a and b must be greater than zero" ); + arma_conform_check( ( ((a > double(0)) == false) || ((b > double(0)) == false) ), "randg(): incorrect distribution parameters; a and b must be greater than zero" ); obj_type out(n_rows, n_cols, arma_nozeros_indicator()); @@ -138,7 +138,7 @@ randg(const distr_param& param = distr_param()) param.get_double_vals(a,b); - arma_conform_check( ((a <= double(0)) || (b <= double(0))), "randg(): incorrect distribution parameters; a and b must be greater than zero" ); + arma_conform_check( ( ((a > double(0)) == false) || ((b > double(0)) == false) ), "randg(): incorrect distribution parameters; a and b must be greater than zero" ); double out_val = double(0); @@ -162,7 +162,7 @@ randg(const distr_param& param = distr_param()) param.get_double_vals(a,b); - arma_conform_check( ((a <= double(0)) || (b <= double(0))), "randg(): incorrect distribution parameters; a and b must be greater than zero" ); + arma_conform_check( ( ((a > double(0)) == false) || ((b > double(0)) == false) ), "randg(): incorrect distribution parameters; a and b must be greater than zero" ); eT out_val = eT(0); @@ -189,7 +189,7 @@ randg(const uword n_rows, const uword n_cols, const uword n_slices, const distr_ param.get_double_vals(a,b); - arma_conform_check( ((a <= double(0)) || (b <= double(0))), "randg(): incorrect distribution parameters; a and b must be greater than zero" ); + arma_conform_check( ( ((a > double(0)) == false) || ((b > double(0)) == false) ), "randg(): incorrect distribution parameters; a and b must be greater than zero" ); cube_type out(n_rows, n_cols, n_slices, arma_nozeros_indicator()); diff --git a/include/armadillo_bits/fn_randi.hpp b/include/armadillo_bits/fn_randi.hpp index 24baf306..0a7e9b70 100644 --- a/include/armadillo_bits/fn_randi.hpp +++ b/include/armadillo_bits/fn_randi.hpp @@ -47,7 +47,7 @@ randi(const uword n_rows, const uword n_cols, const distr_param& param = distr_p param.get_int_vals(a,b); - arma_conform_check( (a > b), "randi(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a <= b) == false), "randi(): incorrect distribution parameters; a must be less than b" ); obj_type out(n_rows, n_cols, arma_nozeros_indicator()); @@ -142,7 +142,7 @@ randi(const distr_param& param) param.get_int_vals(a,b); - arma_conform_check( (a > b), "randi(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a <= b) == false), "randi(): incorrect distribution parameters; a must be less than b" ); sword out_val = sword(0); @@ -166,7 +166,7 @@ randi(const distr_param& param) param.get_int_vals(a,b); - arma_conform_check( (a > b), "randi(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a <= b) == false), "randi(): incorrect distribution parameters; a must be less than b" ); eT out_val = eT(0); @@ -218,7 +218,7 @@ randi(const uword n_rows, const uword n_cols, const uword n_slices, const distr_ param.get_int_vals(a,b); - arma_conform_check( (a > b), "randi(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a <= b) == false), "randi(): incorrect distribution parameters; a must be less than b" ); cube_type out(n_rows, n_cols, n_slices, arma_nozeros_indicator()); diff --git a/include/armadillo_bits/fn_randn.hpp b/include/armadillo_bits/fn_randn.hpp index 86a6b826..fbfb8862 100644 --- a/include/armadillo_bits/fn_randn.hpp +++ b/include/armadillo_bits/fn_randn.hpp @@ -62,7 +62,7 @@ randn(const distr_param& param) param.get_double_vals(mu,sd); - arma_conform_check( (sd <= double(0)), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); + arma_conform_check( ((sd > double(0)) == false), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); const double val = double(arma_rng::randn()); @@ -86,7 +86,7 @@ randn(const distr_param& param) param.get_double_vals(mu,sd); - arma_conform_check( (sd <= double(0)), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); + arma_conform_check( ((sd > double(0)) == false), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); eT val = eT(0); @@ -119,7 +119,7 @@ randn(const uword n_elem, const distr_param& param = distr_param()) param.get_double_vals(mu,sd); - arma_conform_check( (sd <= double(0)), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); + arma_conform_check( ((sd > double(0)) == false), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); arma_rng::randn::fill(out.memptr(), n_elem, mu, sd); } @@ -156,7 +156,7 @@ randn(const uword n_elem, const distr_param& param = distr_param(), const typena param.get_double_vals(mu,sd); - arma_conform_check( (sd <= double(0)), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); + arma_conform_check( ((sd > double(0)) == false), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); arma_rng::randn::fill(out.memptr(), out.n_elem, mu, sd); } @@ -188,7 +188,7 @@ randn(const uword n_rows, const uword n_cols, const distr_param& param = distr_p param.get_double_vals(mu,sd); - arma_conform_check( (sd <= double(0)), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); + arma_conform_check( ((sd > double(0)) == false), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); arma_rng::randn::fill(out.memptr(), out.n_elem, mu, sd); } @@ -237,7 +237,7 @@ randn(const uword n_rows, const uword n_cols, const distr_param& param = distr_p param.get_double_vals(mu,sd); - arma_conform_check( (sd <= double(0)), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); + arma_conform_check( ((sd > double(0)) == false), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); arma_rng::randn::fill(out.memptr(), out.n_elem, mu, sd); } @@ -284,7 +284,7 @@ randn(const uword n_rows, const uword n_cols, const uword n_slices, const distr_ param.get_double_vals(mu,sd); - arma_conform_check( (sd <= double(0)), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); + arma_conform_check( ((sd > double(0)) == false), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); arma_rng::randn::fill(out.memptr(), out.n_elem, mu, sd); } @@ -330,7 +330,7 @@ randn(const uword n_rows, const uword n_cols, const uword n_slices, const distr_ param.get_double_vals(mu,sd); - arma_conform_check( (sd <= double(0)), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); + arma_conform_check( ((sd > double(0)) == false), "randn(): incorrect distribution parameters; standard deviation must be > 0" ); arma_rng::randn::fill(out.memptr(), out.n_elem, mu, sd); } diff --git a/include/armadillo_bits/fn_randu.hpp b/include/armadillo_bits/fn_randu.hpp index 63363e1d..264eeb72 100644 --- a/include/armadillo_bits/fn_randu.hpp +++ b/include/armadillo_bits/fn_randu.hpp @@ -62,7 +62,7 @@ randu(const distr_param& param) param.get_double_vals(a,b); - arma_conform_check( (a >= b), "randu(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a < b) == false), "randu(): incorrect distribution parameters; a must be less than b" ); const double val = double(arma_rng::randu()); @@ -86,7 +86,7 @@ randu(const distr_param& param) param.get_double_vals(a,b); - arma_conform_check( (a >= b), "randu(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a < b) == false), "randu(): incorrect distribution parameters; a must be less than b" ); eT val = eT(0); @@ -119,7 +119,7 @@ randu(const uword n_elem, const distr_param& param = distr_param()) param.get_double_vals(a,b); - arma_conform_check( (a >= b), "randu(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a < b) == false), "randu(): incorrect distribution parameters; a must be less than b" ); arma_rng::randu::fill(out.memptr(), n_elem, a, b); } @@ -156,7 +156,7 @@ randu(const uword n_elem, const distr_param& param = distr_param(), const typena param.get_double_vals(a,b); - arma_conform_check( (a >= b), "randu(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a < b) == false), "randu(): incorrect distribution parameters; a must be less than b" ); arma_rng::randu::fill(out.memptr(), out.n_elem, a, b); } @@ -188,7 +188,7 @@ randu(const uword n_rows, const uword n_cols, const distr_param& param = distr_p param.get_double_vals(a,b); - arma_conform_check( (a >= b), "randu(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a < b) == false), "randu(): incorrect distribution parameters; a must be less than b" ); arma_rng::randu::fill(out.memptr(), out.n_elem, a, b); } @@ -237,7 +237,7 @@ randu(const uword n_rows, const uword n_cols, const distr_param& param = distr_p param.get_double_vals(a,b); - arma_conform_check( (a >= b), "randu(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a < b) == false), "randu(): incorrect distribution parameters; a must be less than b" ); arma_rng::randu::fill(out.memptr(), out.n_elem, a, b); } @@ -284,7 +284,7 @@ randu(const uword n_rows, const uword n_cols, const uword n_slices, const distr_ param.get_double_vals(a,b); - arma_conform_check( (a >= b), "randu(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a < b) == false), "randu(): incorrect distribution parameters; a must be less than b" ); arma_rng::randu::fill(out.memptr(), out.n_elem, a, b); } @@ -330,7 +330,7 @@ randu(const uword n_rows, const uword n_cols, const uword n_slices, const distr_ param.get_double_vals(a,b); - arma_conform_check( (a >= b), "randu(): incorrect distribution parameters; a must be less than b" ); + arma_conform_check( ((a < b) == false), "randu(): incorrect distribution parameters; a must be less than b" ); arma_rng::randu::fill(out.memptr(), out.n_elem, a, b); }