login

Revision History for A278049

(Bold, blue-underlined text is an addition; faded, red-underlined text is a deletion.)

Showing entries 1-10 | older changes
a(n) = 3*(Sum_{k=1..n} phi(k)) - 1, where phi = A000010.
(history; published version)
#22 by Susanna Cuyler at Fri Mar 26 08:42:28 EDT 2021
STATUS

proposed

approved

#21 by Chai Wah Wu at Thu Mar 25 21:53:42 EDT 2021
STATUS

editing

proposed

#20 by Chai Wah Wu at Thu Mar 25 21:53:38 EDT 2021
PROG

return 3*(n*(n-1)-c+j)//2 - 1 # Chai Wah Wu, Mar 25 2021

#19 by Chai Wah Wu at Thu Mar 25 21:53:15 EDT 2021
PROG

(Python)

from functools import lru_cache

@lru_cache(maxsize=None)

def A278049(n): # based on second formula in A018805

if n == 0:

return -1

c, j = 0, 2

k1 = n//j

while k1 > 1:

j2 = n//k1 + 1

c += (j2-j)*(2*A278049(k1)-1)//3

j, k1 = j2, n//j2

return 3*(n*(n-1)-c+j)//2 - 1 # Chai Wah Wu, Mar 25 2021

STATUS

approved

editing

#18 by Alois P. Heinz at Fri Feb 14 17:06:25 EST 2020
STATUS

proposed

approved

#17 by Ilya Gutkovskiy at Fri Feb 14 16:52:54 EST 2020
STATUS

editing

proposed

#16 by Ilya Gutkovskiy at Fri Feb 14 16:11:36 EST 2020
FORMULA

G.f.: (1/(1 - x)) * (-x + 3 * Sum_{k>=1} mu(k) * x^k / (1 - x^k)^2). - Ilya Gutkovskiy, Feb 14 2020

CROSSREFS
STATUS

approved

editing

#15 by N. J. A. Sloane at Fri Dec 16 12:24:06 EST 2016
STATUS

proposed

approved

#14 by Michael De Vlieger at Fri Dec 16 08:25:56 EST 2016
STATUS

editing

proposed

#13 by Michael De Vlieger at Fri Dec 16 08:25:53 EST 2016
MATHEMATICA

Table[3 Sum[EulerPhi@ k, {k, n}] - 1, {n, 57}] (* Michael De Vlieger, Dec 16 2016 *)

STATUS

proposed

editing