Look at the small denominators in Roger's first way (here slightly modified):
how do your denominators compare?
vv =: 2 1 , [: , 1 ,.~ 1 ,.~ 2 + 2 * i.
]v =: vv 3x
2 1 2 1 1 4 1 1 6 1 1
,. (+%)/\ v
2
3
8r3
11r4
19r7
87r32
106r39
0j1100 ": +`%/1x, 1100#1'
0.722473
Linda
-Original Message-
From: programming-boun...@forums.jsoftware.com
[mailto:programming-boun...@forums.jsoftware.com] On Behalf Of Bo Jacoby
Sent: Tuesday, March 11, 2014 4:30 AM
To: programm...@jsoftware.com
Subject: Re: [Jprogramming
0j1100 ": +`%/1x, 1100#1'
0.722473
Linda
-Original Message-
From: programming-boun...@forums.jsoftware.com
[mailto:programming-boun...@forums.jsoftware.com] On Behalf Of Bo Jacoby
Sent: Tuesday, March 11, 2014 4:30 AM
To: programm...@jsoftware.com
Subject: Re: [Jprogramming] Approximating e
s information become fiction. Also
>> how can I get the best possible and correct decimal approximation from
>> these
>> rational numbers?
>>
>> Linda
>>
>>
>>
>> Original Message-
>> From: programming-boun...@for
3826
>
>
>
> 734544867157818093234908902110449296423351%453973694165307953197296969697410
> 619233826
> 1.61803
>
> How can I get the best possible decimal approximation (I have 32 bit
> digits)?
>
> Linda
>
>
>
> -Original Message-
> From: progr
on from
> these
> rational numbers?
>
> Linda
>
>
>
> Original Message-
> From: programming-boun...@forums.jsoftware.com
> [mailto:programming-boun...@forums.jsoftware.com] On Behalf Of Linda
> Alvord
> Sent: Monday, March 10, 2014 9:32 PM
> To: programm
Message-
From: programming-boun...@forums.jsoftware.com
[mailto:programming-boun...@forums.jsoftware.com] On Behalf Of Linda Alvord
Sent: Monday, March 10, 2014 9:32 PM
To: programm...@jsoftware.com
Subject: Re: [Jprogramming] Approximating e
Thanks for your hints. I always wanted to get rational ap
449296423351r453973694165307953197296969697410
> > > 619233826
> > >
> > >
> > >
> > >
> >
> 734544867157818093234908902110449296423351%453973694165307953197296969697410
> > > 619233826
> > > 1.61803
> > >
> > >
t;
> > -----Original Message-
> > From: programming-boun...@forums.jsoftware.com
> > [mailto:programming-boun...@forums.jsoftware.com] On Behalf Of EelVex
> > Sent: Monday, March 10, 2014 7:12 PM
> > To: Programming forum
> > Subject: Re: [Jprogramming
ftware.com
> [mailto:programming-boun...@forums.jsoftware.com] On Behalf Of EelVex
> Sent: Monday, March 10, 2014 7:12 PM
> To: Programming forum
> Subject: Re: [Jprogramming] Approximating e
>
> * Summing infinite series
>
>+/%!i.100x
>+/^ t. i.100x NB. Taylor
mming-boun...@forums.jsoftware.com
[mailto:programming-boun...@forums.jsoftware.com] On Behalf Of EelVex
Sent: Monday, March 10, 2014 7:12 PM
To: Programming forum
Subject: Re: [Jprogramming] Approximating e
* Summing infinite series
+/%!i.100x
+/^ t. i.100x NB. Taylor coefficients
%+/((_1&^
* Summing infinite series
+/%!i.100x
+/^ t. i.100x NB. Taylor coefficients
%+/((_1&^)%!)i.100x
etc
* Taking an asymptotic
(-^~1-%) 100x
((^~%~^~@>:) - (^~%^~@<:))100x
etc
* Continued fractions
+`%/2 1,2#>:i.100x
+`%/2, 2#2+i.100x
(+%)/2 1, ,(1 1,~])"0 +:>:i.100x NB. canonical
Two of a large number of ways:
n=: 20x
v=: 2 , ,1,.(2+2*i.n),.1
v
2 1 2 1 1 4 1 1 6 1 1 8 1 1 10 1 1 12 1 1 14 1 1 16 1 1 18 1 1 20 1 1 22 1
1 24 1 1 26 1 1 28 1 1 30 1 1 32 1 1 34 1 1 36 1 1 38 1 1 40 1
(+%)/v
22876575111522797753057490407482r8415821667943532643424692161961
0j20 "
The rational 2721r1001 approximates e to six, almost seven decimal places:
0j7 ": (^ 1) ,: 2721r1001
2.7182818
2.7182817
I got 2721r1001 from a continued fraction. How would you look for rational
approximations to e ?
--Kip Murray
Sent from my iPad
14 matches
Mail list logo