|
Search: id:A146326
|
|
|
| A146326 |
|
a(n) = length of period continued fraction of (1+Sqrt[n])/2 |
|
+0 39
|
|
| 0, 2, 2, 0, 1, 4, 4, 4, 0, 2, 2, 2, 1, 4, 2, 0, 3, 6, 6, 4, 2, 6, 4, 4, 0, 2, 2, 4, 1, 2, 8, 4, 4, 4, 2, 0, 3, 6, 6, 8, 5, 4, 10, 6, 2, 8, 4, 4, 0, 2, 2, 4, 1, 6, 4, 2, 6, 6, 6, 4, 3, 4, 2, 0, 3, 6, 10, 6, 4, 6, 8, 4, 9, 6, 4, 8, 2, 4, 4, 4, 0, 2, 2, 2, 1, 6, 2, 8, 7, 2, 8, 8, 2, 12, 4, 8, 9, 4, 2, 0
(list; graph; listen)
|
|
|
OFFSET
|
1,2
|
|
|
COMMENT
|
First occurence of n in this sequence see A146343.
Records see A146344.
Indices where records occured see A146345.
a(n)=0 when n = k^2 <a(A000290(m+1))=0>.
a(n)=1 when n = 4 k^2 + 4 k + 5 <a(A078370(m))=1>.
a(n)=2 when n belonging to A146327.
a(n)=3 when n belonging to A146328.
a(n)=4 when n belonging to A146329.
a(n)=5 when n belonging to A146330.
a(n)=6 when n belonging to A146331.
a(n)=7 when n belonging to A146332.
a(n)=8 when n belonging to A146333.
a(n)=9 when n belonging to A146334.
a(n)=10 when n belonging to A146335.
a(n)=11 when n belonging to A146336.
a(n)=12 when n belonging to A146337.
a(n)=13 when n belonging to A146338.
a(n)=14 when n belonging to A146339.
a(n)=15 when n belonging to A146340.
a(n)=16 when n belonging to A146341.
a(n)=17 when n belonging to A146342.
|
|
LINKS
|
R. J. Mathar, Table of n, a(n) for n=1,...,20000.
|
|
EXAMPLE
|
a(2) = 2 because continued fraction of (1+Sqrt[2])/2 = 1, 4, 1, 4, 1, 4, 1, ...
has period (1,4) length 2
|
|
MAPLE
|
A146326 := proc(n) if not issqr(n) then numtheory[cfrac]( (1+sqrt(n))/2, 'periodic', 'quotients') ; nops(%[2]) ; else 0 ; fi; end: seq(A146326(n), n=1..100) ; [From R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Sep 06 2009]
|
|
MATHEMATICA
|
s = 10; aa = {}; Do[k = ContinuedFraction[(1 + Sqrt[n])/2, 1000]; If[Length[k] < 190, AppendTo[aa, 0], m = 1; While[k[[s ]] != k[[s + m]] || k[[s + m]] != k[[s + 2 m]] || k[[s + 2 m]] != k[[s + 3 m]] || k[[s + 3 m]] != k[[s + 4 m]], m++ ]; s = s + 1; While[k[[s ]] != k[[s + m]] || k[[s + m]] != k[[s + 2 m]] || k[[s + 2 m]] != k[[s + 3 m]] || k[[s + 3 m]] != k[[s + 4 m]], m++ ]; s = s + 1; While[k[[s ]] != k[[s + m]] || k[[s + m]] != k[[s + 2 m]] || k[[s + 2 m]] != k[[s + 3 m]] || k[[s + 3 m]] != k[[s + 4 m]], m++ ]; AppendTo[aa, m]], {n, 1, 500}]; aa (*Artur Jasinski*)
|
|
CROSSREFS
|
A000290, A078370, A146326-A146345.
Sequence in context: A144074 A124540 A124550 this_sequence A158852 A102404 A089246
Adjacent sequences: A146323 A146324 A146325 this_sequence A146327 A146328 A146329
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
Artur Jasinski (grafix(AT)csl.pl), Oct 30 2008
|
|
EXTENSIONS
|
a(39) and a(68) corrected by R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Sep 06 2009
|
|
|
Search completed in 0.003 seconds
|