|
|
A214636
|
|
A213437 becomes periodic mod n starting at this position.
|
|
3
|
|
|
1, 1, 3, 2, 1, 3, 4, 3, 3, 1, 5, 3, 1, 4, 3, 4, 3, 3, 6, 2, 4, 5, 7, 3, 2, 1, 3, 4, 10, 3, 5, 4, 5, 3, 4, 3, 6, 6, 3, 3, 1, 4, 8, 5, 3, 7, 11, 4, 4, 2, 3, 2, 8, 3, 5, 4, 6, 10, 9, 3, 6, 5, 4, 5, 1, 5, 11, 3, 7, 4, 8, 3, 4, 6, 3, 6, 5, 3, 5, 4, 3, 1, 7, 4, 3, 8, 10, 5, 3, 3, 4
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,3
|
|
LINKS
|
|
|
FORMULA
|
Empirically,
A214636(2^n) = (1,2,3,4,4,5,6,6,7,8,8,...) = A004523(n+2) for n>1.
|
|
PROG
|
(PARI) A214636(n, N=199)={my(a=[Mod(1, n)]); for(n=1, N-1, a=concat(a, a[n]+(a[n]+1)*prod(k=1, n-1, a[k]))); for(p=1, N\3, forstep(m=N, p+1, -1, a[m]==a[m-p]&next; 3*m>N&next(2); return(m-p+1)); return(1))} /* the 2nd optional parameter must be taken large enough, at least 3 times the period length and starting position. The script returns zero if the period is not found (most probably due to these constraints). */
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|