From f07528dace9fc00c178c290ea8b43873f57a2735 Mon Sep 17 00:00:00 2001 From: Kat Richey Date: Thu, 27 Oct 2022 23:57:29 -0500 Subject: [PATCH] Why am I doing exp(24)?! It's a constant!!! --- math/log.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/math/log.c b/math/log.c index a0a0c15..51567fc 100644 --- a/math/log.c +++ b/math/log.c @@ -15,7 +15,7 @@ double _agm(double x, double y) { } double log(double x) { - double s = x * exp2(24); + double s = x * 16777216; double nat_log = (M_PI / (2 * _agm(1, 4/s))) - (24 * M_LN2); return nat_log; } \ No newline at end of file