and 1 contributors

# NAME

Math::NumSeq::DedekindPsiCumulative -- cumulative Psi function

# SYNOPSIS

`````` use Math::NumSeq::DedekindPsiCumulative;
my \$seq = Math::NumSeq::DedekindPsiCumulative->new;
my (\$i, \$value) = \$seq->next;``````

# DESCRIPTION

The cumulative Dedekind Psi function,

``````    1, 4, 8, 14, 20, 32, 40, 52, 64, 82, 94, 118, ...
starting i=1

value = sum n=1 to n=i of Psi(n)``````

where the Psi function is

``````    Psi(n) =        product          (p+1) * p^(e-1)
prime factors p^e in n``````

The p+1 means one copy of each distinct prime in n is changed from p to p+1. This is similar to Euler's totient function phi(n) (see Math::NumSeq::Totient) but phi(n) is p-1 instead of p+1.

# FUNCTIONS

See "FUNCTIONS" in Math::NumSeq for behaviour common to all sequence classes.

`\$seq = Math::NumSeq::DedekindPsiCumulative->new ()`

Create and return a new sequence object.

`\$i = \$seq->value_to_i_estimate(\$value)`

Return an estimate of the i corresponding to `\$value`. Currently this is based on the asymptotic

``    value = 15*n^2/(2*Pi^2) + O(n*log(n))``

which neglecting the O(n*log(n)) becomes

``    i ~= sqrt(value) * pi/sqrt(15/2)``