gives the number of distinct primes in n.

# Details and Options

• Integer mathematical function, suitable for both symbolic and numerical manipulation.
• PrimeNu gives the number of distinct prime factors.
• For a number with a unit and primes, PrimeNu[n] returns m.
• With the setting , PrimeNu gives the number of Gaussian prime factors.
• PrimeNu[m+In] automatically works over Gaussian integers.

# Examples

open allclose all

## Basic Examples(2)

Plot the PrimeNu sequence for the first 100 numbers:

## Scope(9)

### Numerical Evaluation(4)

Gaussian integers:

Compute for large integers:

### Symbolic Manipulation(5)

Reduce expressions:

Solve equalities:

Compare with DirichletTransform:

## Options(1)

### GaussianIntegers(1)

Gaussian integers:

## Applications(7)

### Basic Applications(2)

Table of the values of PrimeNu for the integers up to 100:

Histogram of the values of PrimeNu:

### Number Theory(5)

Use PrimeNu to test for a prime power:

Use PrimeNu to compute MoebiusMu and LiouvilleLambda for square-free numbers:

PrimeNu is related to MoebiusMu through the following formula:

Plot the average over values of PrimeNu for different ranges of integer arguments:

The Fourier statistics of the PrimeNu sequence:

## Properties & Relations(6)

Use FactorInteger to find the number of distinct prime factors:

PrimeNu gives 1 for a prime power:

PrimeNu and PrimeOmega are equivalent when the argument is square free:

PrimeNu is always smaller than or equal to PrimeOmega:

If n is square free, PrimeNu is related to MoebiusMu and LiouvilleLambda:

## Possible Issues(1)

PrimeNu is not defined at 0:

## Neat Examples(2)

Plot the arguments of the Fourier transform of PrimeNu:

Plot the Ulam spiral of PrimeNu:

#### CMS

Wolfram Language. 2008. "PrimeNu." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/PrimeNu.html.