OFFSET
1,2
LINKS
David A. Corneth, Table of n, a(n) for n = 1..10000
FORMULA
For odd n: a(n) = phi(n) (sequence A000010).
Conjecture: a(n) = 6*phi(n) if n mod 4 = 2 and a(n) = 4*phi(n) if n mod 4 = 0. - Vladeta Jovovic, Jul 20 2001
Conjecture confirmed. - Christian G. Bower, May 20 2005
Multiplicative with a(2) = 6, a(2^e) = 2^(e+1), e>1, a(p^e) = (p-1)*p^(e-1), p>2. - Christian G. Bower, May 18 2005
Sum_{k=1..n} a(k) ~ c * n^2, where c = 7/Pi^2 = 0.709248... . - Amiram Eldar, Oct 30 2022
Dirichlet g.f.: (zeta(s-1)/zeta(s))*((2^s-4/2^s+4)/(2^s-1)). - Amiram Eldar, Dec 30 2022
MATHEMATICA
a[n_] := Switch[Mod[n, 4], 0, 4, 2, 6, _, 1]*EulerPhi[n];
Array[a, 69] (* Jean-François Alcover, Apr 19 2018 *)
PROG
(PARI) a(n)=my(p=eulerphi(n)); if(n%2==1, p, if(n%4==2, 6*p, 4*p)); \\ Joerg Arndt, Sep 09 2020
CROSSREFS
KEYWORD
nonn,easy,mult
AUTHOR
Ahmed Fares (ahmedfares(AT)my-deja.com), Jul 18 2001
EXTENSIONS
More terms from Christian G. Bower, May 20 2005
STATUS
approved