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

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A135063 Define the sequence {b_n(m)} by b_n(0)=0; b_n(m) = A000005(b_n(m-1)+n), for all m >= 1. Then a(n) is the smallest positive integer such that b_n(m) = b_n(m + a(n)) for all m > some positive integer. 2
1, 2, 1, 1, 1, 1, 3, 2, 1, 1, 1, 1, 2, 1, 1, 2, 1, 1, 2, 3, 1, 1, 1, 2, 2, 2, 1, 2, 1, 1, 1, 3, 2, 1, 1, 2, 2, 2, 1, 2, 1, 2, 4, 1, 3, 1, 3, 1, 2, 2, 1, 4, 1, 1, 2, 3, 1, 1, 1, 1, 2, 1, 2, 3, 1, 2, 2, 5, 1, 1, 1, 1, 2, 2, 2, 2, 2, 1, 4, 3, 1, 1, 1, 1, 2, 1, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
EXAMPLE
{b_7(m)} is 0,2,3,4,2,3,4,..., with (2,3,4) repeating thereafter. So a(7) = 3, the length of the repeating subsequence (2,3,4).
MAPLE
b := proc(n, m) option remember; if m =0 then 0; else numtheory[tau]( procname(n, m-1)+n); end if; end proc:
A135063 := proc(n) bseq := [] ; for m from 0 do bs := b(n, m) ; if member(bs, bseq, 'w') then return 1+nops(bseq)-w ; else bseq := [op(bseq), bs] ; end if; end do: end proc: seq(A135063(n), n=1..120) ; # R. J. Mathar, Aug 09 2010
MATHEMATICA
b[n_, m_] := b[n, m] = If[m == 0, 0, DivisorSigma[0, b[n, m-1] + n]];
A135063[n_] := Module[{bseq = {}}, For[m = 0, True, m++, bs = b[n, m]; w = Position[bseq, bs]; If[w != {}, Return[1+Length[bseq]-w[[1, 1]]], AppendTo[bseq, bs]]]];
Table[A135063[n], {n, 1, 120}] (* Jean-François Alcover, Feb 08 2024, after R. J. Mathar *)
PROG
(PARI) a(n) = my(b, k, v=List([0])); until(k<#v, k=1; listput(v, b=numdiv(b+n)); until(v[k]==b||k==#v, k++)); #v-k; \\ Jinyuan Wang, Aug 22 2021
CROSSREFS
Sequence in context: A129265 A030358 A118914 * A370770 A124010 A212171
KEYWORD
nonn
AUTHOR
Leroy Quet, Nov 15 2007
EXTENSIONS
Terms beyond a(12) from R. J. Mathar, Aug 09 2010
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | 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 April 28 21:24 EDT 2024. Contains 372095 sequences. (Running on oeis4.)