OFFSET
1,1
COMMENTS
Theorem: If (b-1)/(2q-1) = F(m)/F(m+1) then sqrt(q^2+b) = [q;1,1,...,1,1,2q,...], where F(m) are the Fibonacci numbers and the period contains m ones. - Thomas Ordowski, Jun 09 2012
Terms are all and only k = ((d*F(m+1) + 1)/2)^2 + d*F(m) + 1 for d>=1 odd, and m>=1 with m == 0 or 1 (mod 3) (so F(m+1) odd), and consequently lim_{n->oo} n/sqrt(a(n)) = A360957 - 1 = 1.696383... - Kevin Ryde, Mar 07 2023
LINKS
Kevin Ryde, Table of n, a(n) for n = 1..6000
Kevin Ryde, PARI/GP Code and Notes
FORMULA
sqrt(k) = [q;1,1,...,1,1,2q,...] = sqrt(q^2+b), where (2q-1)/(b-1) = F(m+1)/F(m) for m=1,3,4,6,7,9,10,12,13,... The period contains m ones. F(m) is the m-th Fibonacci number. Note that this formula does not generate all terms of this sequence. - Thomas Ordowski, Jun 08 2012
sqrt(k) = [q;1,1,...,1,1,2q,...] with m ones in its repeating continued fraction expansion precisely when q=floor(sqrt(k)) and k=q^2+2q*F(m)/F(m+1)+F(m-1)/F(m+1). Such k are integral precisely when 2q-1 is divisible by F(m+1). - Gary Walsh, Jan 06 2023
EXAMPLE
(2q-1)/(b-1) = 1/1 so b=2q. Let q=1, b=2; k = q^2 + b = 3.
MATHEMATICA
fQ[n_] := Union@ Most@ Last@ ContinuedFraction@ Sqrt[1/n] == {1}; Select[ Range@ 1000, fQ] (* Robert G. Wilson v, Jun 07 2012 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Walter Gilbert
STATUS
approved