|
|
A364392
|
|
a(1)=1 and thereafter a(n) is the least number of locations 1..n-1 which can be visited in a single path beginning at i=n-1, in which one proceeds from location i to i +- a(i) (within 1..n-1) until no further unvisited location is available.
|
|
5
|
|
|
1, 1, 2, 3, 4, 4, 3, 6, 3, 4, 4, 6, 3, 5, 4, 7, 5, 5, 6, 6, 5, 6, 6, 6, 6, 7, 3, 8, 5, 8, 7, 5, 6, 6, 7, 7, 9, 5, 9, 7, 5, 8, 7, 8, 3, 6, 9, 9, 7, 6, 4, 6, 6, 6, 10, 7, 7, 5, 10, 3, 6, 7, 7, 8, 3, 8, 6, 5, 9, 6, 4, 9, 9, 5, 7, 6, 5, 5, 7, 5, 6, 6, 6, 7, 7, 9, 7
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,3
|
|
COMMENTS
|
The sequence is 1244 initial terms followed by a repeating block of 4925 terms so that a(n) = a(n-4925) for n >= 6170. - Kevin Ryde, Jul 31 2023
|
|
LINKS
|
|
|
EXAMPLE
|
a(13)=3 because beginning at the most recent location i=n-1=12, where a(12)=6, we can visit (the fewest possible) 3 locations in a single path as follows:
1 2 3 4 5 6 7 8 9 10 11 12 location number i
1,1,2,3,4,4,3,6,3, 4, 4, 6 a(i)
<--------------6
4-------->
At i=10, the only jump is back to 10-a(10) = 6, which was already visited, so the path stops.
|
|
PROG
|
(PARI) See links.
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|