From 663d9cc36e2d85e5e5d41463f4b2b408fdf9d161 Mon Sep 17 00:00:00 2001 From: conrad Date: Mon, 5 Feb 2024 11:19:43 +1000 Subject: [PATCH] unsure consistency with op_pinv --- include/armadillo_bits/op_rank_meat.hpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/armadillo_bits/op_rank_meat.hpp b/include/armadillo_bits/op_rank_meat.hpp index ef00dd39..7301a7fb 100644 --- a/include/armadillo_bits/op_rank_meat.hpp +++ b/include/armadillo_bits/op_rank_meat.hpp @@ -44,7 +44,9 @@ op_rank::apply(uword& out, const Base& expr, const ty bool do_sym = false; - if((arma_config::optimise_sym) && (auxlib::crippled_lapack(A) == false) && (A.n_rows >= (is_cx::yes ? uword(64) : uword(128)))) + const bool is_sym_size_ok = (A.n_rows == A.n_cols) && (A.n_rows > (is_cx::yes ? uword(20) : uword(40))); // for consistency with op_pinv + + if( (is_sym_size_ok) && (arma_config::optimise_sym) && (auxlib::crippled_lapack(A) == false) ) { bool is_approx_sym = false; bool is_approx_sympd = false;