Skip to content

Commit

Permalink
Update comments
Browse files Browse the repository at this point in the history
  • Loading branch information
kimwalisch committed Jan 8, 2024
1 parent 40ccd65 commit 0a54c46
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/nthPrimeApprox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ uint64_t Ri_inverse(uint64_t x)
uint64_t primePiApprox(uint64_t x)
{
// Li(x) is faster but less accurate than Ri(x).
// For small n speed is more important than accuracy.
// For small x speed is more important than accuracy.
if (x < 1e10)
return Li(x);
else
Expand All @@ -266,7 +266,7 @@ uint64_t primePiApprox(uint64_t x)

uint64_t nthPrimeApprox(uint64_t n)
{
// Li_inverse(x) is faster but less accurate than Ri_inverse(x).
// Li_inverse(n) is faster but less accurate than Ri_inverse(n).
// For small n speed is more important than accuracy.
if (n < 1e8)
return Li_inverse(n);
Expand Down

0 comments on commit 0a54c46

Please sign in to comment.