From 3b030471b01471dfed3cc2c0a7e6ff4bd2c00e33 Mon Sep 17 00:00:00 2001 From: ? Date: Mon, 25 Feb 2019 04:05:56 +0100 Subject: [PATCH] fixed a bug in inverse caused by precision issues --- hyperpoint.cpp | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/hyperpoint.cpp b/hyperpoint.cpp index 9559e2f4..97ed295b 100644 --- a/hyperpoint.cpp +++ b/hyperpoint.cpp @@ -515,13 +515,18 @@ transmatrix inverse(const transmatrix& T) { transmatrix T2 = Id; for(int a=0; a abs(T1[best][a])) + best = b; + + int b = best; + + if(b != a) + for(int c=0; c