Algosim documentation: PrimePi

PrimePi

The prime-counting function.

Syntax

Description

If n is an integer, then PrimePi(n) is the number of prime number less than or equal to n, that is,

PrimePi(n) = count(SequenceVector(n), IsPrime).

Examples

PrimePi(1000000)
78498

See also