OFFSET
1,2
COMMENTS
If n is a power of a prime (including 1 and primes), then a(n) = n, and in any other case a(n) > n. - M. F. Hasler, Sep 09 2017
If n is in A006881, then a(n)=n+1. - Robert Israel, Feb 10 2019
REFERENCES
Richard K. Guy, Unsolved Problems in Number Theory, 3rd Edition, Springer, 2004. See Section B41 (page 96 of 2nd ed., pages 147ff of 3rd ed.).
LINKS
Hugo Pfoertner, Table of n, a(n) for n = 1..10000
Marcin Mazur and Bogdan V. Petrenko, Generalizations of Arnold's version of Euler's theorem for matrices, Japanese Journal of Mathematics, 5:183-189, 2010.
FORMULA
Sum_{k=1..n} a(k) = c * n^2 + O(n*log(n)), where c = 21/(4*Pi^2) = 0.531936... . - Amiram Eldar, Dec 05 2023
MAPLE
f:= proc(n) local P, p;
P:= numtheory:-factorset(n);
n*(mul((p-1)/p, p=P) + mul((p+1)/p, p=P))/2
end proc:
map(f, [$1..100]); # Robert Israel, Feb 10 2019
MATHEMATICA
psi[n_] := If[n == 1, 1, n*Times @@ (1 + 1/FactorInteger[n][[All, 1]])];
a[n_] := (psi[n] + EulerPhi[n])/2;
Array[a, 100] (* Jean-François Alcover, Feb 25 2019 *)
PROG
(PARI) A291784(n)=(eulerphi(n)+n*sumdivmult(n, d, issquarefree(d)/d))\2 \\ M. F. Hasler, Sep 03 2017
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
N. J. A. Sloane, Sep 02 2017
STATUS
approved