login
a(n) is the smallest integer such that 1/a(1)^2 + 1/a(2)^2 + ... + 1/a(n-1)^2 + 1/a(n)^2 is less than e.
0

%I #15 Sep 17 2024 04:18:14

%S 1,1,2,2,3,4,5,15,67,535,8986,912849,1662587477,81083409799344,

%T 651628371908007046307,17425286333232464262345491287814,

%U 67473400772659322911375035883722405962101960016,12550884311528115972476468763183847895333364390665475583839492176837589

%N a(n) is the smallest integer such that 1/a(1)^2 + 1/a(2)^2 + ... + 1/a(n-1)^2 + 1/a(n)^2 is less than e.

%F a(n) = ceiling(sqrt(e - Sum_{i=1..n-1} 1/a(i)^2))

%e a(4) = 2 because the first three terms of the sequence are 1,1,2 and 2 is the smallest integer k such that 1/1^2 + 1/1^2 + 1/2^2 + 1/k^2 < e.

%o (PARI) \p150 \\ This is enough to print the first 17 terms correctly

%o my(l(x)=ceil(sqrt(1/x)), k=exp(1)); for(T=1, 17, print(l(k)); k=k-1/l(k)^2)

%K nonn

%O 1,3

%A Hauke Worpel (hw1(AT)email.com), Nov 11 2006