From 3c0f18f05875385c570bf390aca3604dfeabdad4 Mon Sep 17 00:00:00 2001 From: Jens Vollinga Date: Wed, 4 May 2005 19:00:00 +0000 Subject: [PATCH] Synced to HEAD: Fixed bug in gcd (patch from Sheplyakov Alexei). --- ginac/normal.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/ginac/normal.cpp b/ginac/normal.cpp index 9e9bde18..fa09e429 100644 --- a/ginac/normal.cpp +++ b/ginac/normal.cpp @@ -1247,11 +1247,7 @@ static ex heur_gcd(const ex &a, const ex &b, ex *ca, ex *cb, sym_desc_vec::const ex dummy; if (divide_in_z(p, g, ca ? *ca : dummy, var) && divide_in_z(q, g, cb ? *cb : dummy, var)) { g *= gc; - ex lc = g.lcoeff(x); - if (is_exactly_a(lc) && ex_to(lc).is_negative()) - return -g; - else - return g; + return g; } } -- 2.49.0