A017911 Powers of sqrt(2) rounded to nearest integer.
1, 1, 2, 3, 4, 6, 8, 11, 16, 23, 32, 45, 64, 91, 128, 181, 256, 362, 512, 724, 1024, 1448, 2048, 2896, 4096, 5793, 8192, 11585, 16384, 23170, 32768, 46341, 65536, 92682, 131072, 185364, 262144, 370728, 524288
Offset: 0
Examples
sqrt(2)^3 = 2.82842712474619..., so a(3) = 3. sqrt(2)^4 = 4, so a(4) = 4. sqrt(2)^5 = 5.6568542494923801952..., so a(5) = 6. sqrt(2)^6 = 8, so a(6) = 8. sqrt(2)^7 = 11.31370849898476..., so a(7) = 11.
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..5000
- Kival Ngaokrajang, Illustration of initial terms of square inscribing
- Eric Weisstein's World of Mathematics, Polygon Inscribing
Programs
-
Magma
[Round(Sqrt(2)^n): n in [0..40]]; // Vincenzo Librandi, Nov 19 2011
-
Mathematica
Floor[(Sqrt[2]^Range[0, 40] + 1/2)] (* Vincenzo Librandi, Nov 19 2011 *)
-
PARI
a(n)=round(sqrt(2)^n) \\ Charles R Greathouse IV, Nov 18 2011
-
Python
from math import isqrt def A017911(n): return -isqrt(m:=1<
Chai Wah Wu, Jun 18 2024
Comments