From fc5e63f85181c379558f290dbe6056ca83456f3a Mon Sep 17 00:00:00 2001 From: Ben Date: Wed, 28 Feb 2024 20:51:48 +0000 Subject: [PATCH] fix issue 104 --- estimator/reduction.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/estimator/reduction.py b/estimator/reduction.py index 2f3837a..cbdac59 100644 --- a/estimator/reduction.py +++ b/estimator/reduction.py @@ -382,7 +382,9 @@ def _short_vectors_sieve(self, beta, d, N=None, B=None, preprocess=True, sieve_d elif N is None: N = floor(2 ** (0.2075 * beta)) # pick something - c = N / floor(2 ** (0.2075 * beta)) + c0 = RR(N) + c1 = RR(2 ** (RR(0.2075 * beta))) + c = c0 / c1 rho = sqrt(4 / 3.0) * RR( self.delta(sieve_dim) ** (sieve_dim - 1) * self.delta(beta) ** (1 - sieve_dim) @@ -391,7 +393,7 @@ def _short_vectors_sieve(self, beta, d, N=None, B=None, preprocess=True, sieve_d return ( rho, ceil(c) * self(beta, d), - ceil(c) * floor(2 ** (0.2075 * beta)), + ceil(c) * floor(c1), sieve_dim, )