|
Search: id:A114652
|
|
|
| A114652 |
|
a(1)=1. For n>1, a(n) = a(n-1) + (number of terms among {a(1),a(2),...,a(n-1)} which are coprime to n). |
|
+0 2
|
|
| 1, 2, 4, 5, 8, 10, 16, 18, 25, 26, 36, 39, 49, 53, 61, 68, 83, 90, 108, 114, 127, 136, 158, 166, 186, 194, 213, 222, 250, 256, 285, 296, 318, 329, 355, 365, 399, 412, 437, 448, 488, 498, 540, 556, 580, 595, 640, 653, 696, 708, 739, 757, 807, 823, 865, 884, 922
(list; graph; listen)
|
|
|
OFFSET
|
1,2
|
|
|
EXAMPLE
|
Among the first 5 terms of the sequence (1,2,4,5,8) there are 2 terms (1, 5) which are coprime to 6. So a(6)
= a(5) + 2 = 10.
|
|
MATHEMATICA
|
f[l_] := Append[l, Last[l] + Length[Select[l, GCD[ #, Length[l] + 1] == 1 &]]]; Nest[f, {1}, 56] (*Chandler*)
a[1] = 1; a[n_] := a[n] = a[n - 1] + Count[GCD[Array[a, n - 1], n], 1]; Array[a, 57] (* Robert G. Wilson v *)
|
|
CROSSREFS
|
Cf. A114653.
Sequence in context: A032937 A126684 A089653 this_sequence A067943 A067937 A003592
Adjacent sequences: A114649 A114650 A114651 this_sequence A114653 A114654 A114655
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
Leroy Quet (qq-quet(AT)mindspring.com), Dec 21 2005
|
|
EXTENSIONS
|
Extended by Ray Chandler (rayjchandler(AT)sbcglobal.net) and Robert G. Wilson v (rgwv(at)rgwv.com), Dec 23 2005
|
|
|
Search completed in 0.002 seconds
|