proposed
approved
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”).
proposed
approved
editing
proposed
The primorial expansion a(n) of a real number x is defined as x = a(0) + sum(i>=0, a(i) / prime(i)# ) where a(0) = floor(x) and 0 <= a(i) < prime(i) for all i > 0.
e = 2/prime(0)# + 1/prime(1)# + 1/prime(2)# + 1/prime(3)# + 3/prime(4)# + 9/prime(5)# + ...
where prime(n)# = A002110(n) is the n-th primorial number.
proposed
editing
editing
proposed
allocated for Albert LauPrimorial expansion of e.
2, 1, 1, 1, 3, 9, 3, 0, 1, 1, 16, 25, 8, 3, 32, 32, 37, 24, 53, 17, 28, 67, 52, 2, 21, 81, 56, 88, 9, 3, 80, 42, 15, 37, 107, 52, 32, 120, 49, 46, 84, 3, 129, 29, 159, 103, 90, 172, 128, 98, 202, 138, 207, 150, 249, 131, 132, 66, 9, 86, 137, 191, 236, 141, 222, 285, 8, 205, 310, 250, 63, 173, 288, 93, 294, 84, 66, 104, 28, 154, 93, 229, 96, 254, 333, 89, 126, 393, 388, 396, 418, 424, 356, 299, 482, 64, 114, 60, 513, 471
0,1
The primorial expansion a(n) of a real number x is defined as x = sum(i>=0, a(i) / prime(i)# ) where a(0) = floor(x) and 0 <= a(i) < prime(i) for all i > 0.
x(0) = e;
a(n) = floor(x(n));
x(n + 1) = prime(n) * (x(n) - a(n));
where prime(n) = A000040(n) is the n-th prime number.
a(n) gives the primorial expansion of x(0) = e.
e = 2/prime(0)# + 1/prime(1)# + 1/prime(2)# + 1/prime(3)# + 3/prime(4)# + 9/prime(5)# + ...
where prime(n)# = A002110(n) is the n-th primorial number.
pe = Block[{x = #, $MaxExtraPrecision = \[Infinity]},
Do[x = Prime[i] (x - Sow[x // Floor]) // Expand, {i, #2 - 1}];
x // Floor // Sow] // Reap // Last // Last // Function;
pe[E, 100]
allocated
nonn
Albert Lau, Apr 06 2014
approved
editing
allocated for Albert Lau
allocated
approved