A086700 Euler phi function applied to the triangular numbers.
1, 2, 2, 4, 8, 12, 12, 12, 24, 40, 20, 24, 72, 48, 32, 64, 96, 108, 72, 48, 120, 220, 88, 80, 240, 216, 108, 168, 224, 240, 240, 160, 320, 384, 144, 216, 648, 432, 192, 320, 480, 504, 420, 240, 528, 1012, 368, 336, 840, 640, 384, 624, 936, 720, 480, 432, 1008, 1624, 464, 480, 1800, 1080, 576, 768, 960, 1320
Offset: 1
Examples
a(3) = phi(6) = 2.
Links
- Michel Marcus, Table of n, a(n) for n = 1..5000
Programs
-
Maple
with(numtheory):with(combinat):a:=n->phi(binomial(n,2)): seq(a(n), n=2..31); # Zerinvary Lajos, Oct 05 2007
-
Mathematica
EulerPhi[Accumulate[Range[70]]] (* Harvey P. Dale, Sep 16 2012 *)
-
PARI
vector(66,n,eulerphi(n*(n+1)/2))
-
Sage
[euler_phi(binomial(n,2)) for n in range(2,32)] # Zerinvary Lajos, Jun 06 2009
Formula
Sum_{k=1..n} a(k) = c * n^3 / 4 + O((n*log(n))^2), where c = Product_{p prime} (1 - 2/p^2) = 0.322634... (A065474). - Amiram Eldar, Dec 09 2024