login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A347754
a(n) = sqrt(A347594(n-1)^2 + n^2 + A347594(n)).
5
2, 3, 4, 8, 14, 28, 21, 33, 65, 50, 97, 73, 14, 30, 32, 22, 18, 32, 31, 32, 53, 68, 50, 43, 55, 100, 112, 154, 135, 226, 449, 832, 640, 194, 382, 302, 509, 665, 1213, 905, 213, 43, 57, 113, 49, 99, 126, 217, 269, 269, 173, 116, 153, 161, 212, 309, 540, 1057, 863, 1690, 3157, 2593, 1343, 1401, 1506, 1797, 2829, 1170, 87
OFFSET
1,1
LINKS
FORMULA
a(n) = floor(sqrt(A347594(n-1)^2 + n^2)) + 1.
MATHEMATICA
b[0]=1; b[m_]:=b[m]=(k=1; While[!IntegerQ@Sqrt[b[m-1]^2+m^2+k], k++]; k);
a[n_]:=a[n]=Sqrt[b[n-1]^2+n^2+b[n]]; Array[a, 100] (* Giorgos Kalogeropoulos, Sep 12 2021 *)
PROG
(Ruby)
def A347754(n)
s = 1
ary = []
(1..n).each{|i|
j = i * i + s * s
k = Math.sqrt(j).floor + 1
ary << k
s = k * k - j
}
ary
end
p A347754(100)
(Python)
from math import isqrt
A347754_list, a = [], 1
for n in range(1, 10**3):
m = a**2+n**2
k = isqrt(m)+1
a = k**2-m
A347754_list.append(k) # Chai Wah Wu, Sep 13 2021
(PARI) lista(nn) = {my(prec = 1, list=List(), x); for (n=1, nn, my(k = 1); while (!issquare(x = prec^2+n^2+k), k++); listput(list, sqrtint(x)); prec = k; ); Vec(list); } \\ Michel Marcus, Sep 13 2021
CROSSREFS
Cf. A347594.
Sequence in context: A100993 A117395 A006755 * A005853 A161460 A097029
KEYWORD
nonn
AUTHOR
Seiichi Manyama, Sep 12 2021
STATUS
approved