Almkvist-Giullera formula for pi: Difference between revisions

Content added Content deleted
(Realize in F#)
Line 427: Line 427:
This task uses [[Isqrt_(integer_square_root)_of_X#F.23]]
This task uses [[Isqrt_(integer_square_root)_of_X#F.23]]
<lang fsharp>
<lang fsharp>
// Almkvist-Giullera formula for pi. Nigel Galloway: August 1th., 202
// Almkvist-Giullera formula for pi. Nigel Galloway: August 17th., 2021
let factorial(n:bigint)=MathNet.Numerics.SpecialFunctions.Factorial n
let factorial(n:bigint)=MathNet.Numerics.SpecialFunctions.Factorial n
let fN g=(532I*g*g+126I*g+9I)*(factorial(6I*g))/(3I*(factorial g)**6)
let fN g=(532I*g*g+126I*g+9I)*(factorial(6I*g))/(3I*(factorial g)**6)
Line 449: Line 449:
pi to 70 decimal places is 3.14159265358979323846264338327950288419716939937510582097494459230781640
pi to 70 decimal places is 3.14159265358979323846264338327950288419716939937510582097494459230781640
</pre>
</pre>

=={{header|Factor}}==
=={{header|Factor}}==
{{works with|Factor|0.99 2020-08-14}}
{{works with|Factor|0.99 2020-08-14}}