login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

a(n) = ceiling((16^n)*Sum_{k=0..n+1} (4/(8k+1)-2/(8k+4)-1/(8k+5)-1/(8k+6))/16^k).
0

%I #38 May 02 2021 02:39:32

%S 4,51,805,12868,205888,3294199,52707179,843314857,13493037705,

%T 215888603273,3454217652358,55267482437723,884279719003556,

%U 14148475504056881,226375608064910089,3622009729038561422,57952155664616982740,927234490633871723826,14835751850141947581204

%N a(n) = ceiling((16^n)*Sum_{k=0..n+1} (4/(8k+1)-2/(8k+4)-1/(8k+5)-1/(8k+6))/16^k).

%C The formula gives an approximation to 16^n*Pi. The first 300 terms agree with ceiling(16^n*Pi) but this may not be true in general.

%C Terms in base 16 are 4, 33, 325, 3244, 32440, 3243F7, 3243F6B, 3243F6A9, 3243F6A89, 3243F6A889, 3243F6A8886, 3243F6A8885B, 3243F6A8885A4, 3243F6A8885A31, 3243F6A8885A309, 3243F6A8885A308E, 3243F6A8885A308D4, 3243F6A8885A308D32, 3243F6A8885A308D314, 3243F6A8885A308D3132, ...

%H William Blankenship, <a href="https://gist.github.com/retrohacker/e5fff72b7b75ee058924">First 8366 HEX digits of pi</a>

%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Bailey%E2%80%93Borwein%E2%80%93Plouffe_formula">Bailey-Borwein-Plouffe formula</a>

%F a(n) = ceiling((16^n)*Sum_{k=0..n+1} (4/(8k+1)-2/(8k+4)-1/(8k+5)-1/(8k+6))/16^k).

%t Array[Ceiling[(16^#)*Sum[(4/(8 k + 1) - 2/(8 k + 4) - 1/(8 k + 5) - 1/(8 k + 6))/16^k, {k, 0, # + 1}]] &, 19, 0] (* _Michael De Vlieger_, May 01 2021 *)

%o (PARI) a(n) = ceil((16^n)*sum(k=0, n+1, (4/(8*k+1)-2/(8*k+4)-1/(8*k+5)-1/(8*k+6))/16^k)); \\ _Michel Marcus_, Apr 23 2021

%Y Cf. A000796.

%K nonn

%O 0,1

%A _Arthur Lenskold_, Apr 20 2021

%E More terms from _Michel Marcus_, Apr 23 2021