From 95438ff89d7b9beadfc9641b6349629e1fb702e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89milie=20Feral?= Date: Thu, 14 Dec 2017 10:17:23 +0100 Subject: [PATCH] [poincare] In Logarithm, fix bug in logarithm approximation: log(x,y) = ln(x)/ln(y) (instead of ln(y)/ln(x)) --- poincare/src/logarithm.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/poincare/src/logarithm.cpp b/poincare/src/logarithm.cpp index 52d275150..c7b991272 100644 --- a/poincare/src/logarithm.cpp +++ b/poincare/src/logarithm.cpp @@ -212,7 +212,7 @@ Expression * Logarithm::templatedApproximate(Context& context, AngleUnit angleUn if (x->type() == Type::Complex && n->type() == Type::Complex) { Complex * xc = static_cast *>(x); Complex * nc = static_cast *>(n); - result = Division::compute(computeOnComplex(*nc, angleUnit), computeOnComplex(*xc, angleUnit)); + result = Division::compute(computeOnComplex(*xc, angleUnit), computeOnComplex(*nc, angleUnit)); } delete x; delete n;