login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A278166 a(n) = number of integers one more than a prime encountered before reaching 0 when starting from k = ((n+1)^2)-1 and iterating map k -> k - A002828(k). 4
1, 3, 3, 5, 7, 9, 9, 11, 12, 14, 15, 18, 19, 22, 23, 26, 29, 31, 34, 37, 42, 46, 47, 51, 54, 58, 60, 64, 68, 70, 74, 78, 82, 85, 88, 92, 95, 99, 104, 109, 114, 118, 122, 128, 134, 137, 140, 149, 153, 158, 164, 173, 177, 183, 187, 191, 199, 205, 210, 217, 222, 231, 236, 241, 248, 256, 262, 273, 278, 287, 291, 298, 307, 316, 322, 332
(list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
FORMULA
a(1) = A277486(1); for n > 1, a(n) = A277486(n) + a(n-1).
EXAMPLE
For n=4, starting from k = ((4+1)^2)-1, and iterating k -> A255131(k), yields 24 -> 21 -> 18 -> 16 -> 15 -> 11 -> 8 -> 6 -> 3 before 0 is reached. Subtracting one from each gives [23, 20, 17, 15, 14, 10, 7, 5, 2], of which only 23, 17, 7, 5 and 2 are primes, thus a(4) = 5.
PROG
(Scheme) (definec (A278166 n) (if (= 1 n) (A277486 n) (+ (A277486 n) (A278166 (- n 1)))))
CROSSREFS
Partial sums of A277486.
Sequence in context: A076524 A168279 A171957 * A293990 A247130 A271974
KEYWORD
nonn
AUTHOR
Antti Karttunen, Nov 13 2016
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 19 12:25 EDT 2024. Contains 376010 sequences. (Running on oeis4.)