|
[Date Index]
[Thread Index]
[Author Index]
Re: Re: Re: Re: smallest
- To: mathgroup at smc.vnet.net
- Subject: [mg86869] Re: [mg86833] Re: [mg86828] Re: [mg86792] Re: [mg86771] smallest
- From: danl at wolfram.com
- Date: Mon, 24 Mar 2008 01:45:05 -0500 (EST)
- References: <200803200757.CAA29500@smc.vnet.net>
> If we want to find rational fraction f =p/q such that 113/355<f<106/333
> and sum p+q is minimal
> anyone procedure proposed up to now doesn't work
> good result should be
> {137563,{p->13215,q->104348}}
> but isn't
> ARTUR
You can use continued fractions to get a contender, as below.
In[8]:= ContinuedFraction[355/113]
Out[8]= {3, 7, 16}
In[15]:= ContinuedFraction[333/106]
Out[15]= {3, 7, 15}
What this suggest is that a plausible result might be obtained by
splitting the difference on the last convergent:
1/(3+
1/(7+
2/31)))
This yields 219/688.
That happens to agree with Minimize:
In[17]:= Minimize[{p+q, {355*p>113*q,333*p<106*q,p>=1,q>=1}}, {p,q},
Integers]
Out[17]= {907, {p -> 219, q -> 688}}
I notice that 907 is considerably smaller than 137563.
Daniel Lichtblau
Wolfram Research
Prev by Date:
Re: Possible values for the Method option for Graphics??
Next by Date:
Re: Converting 3D graphics to 2D polygons
Previous by thread:
Re: Re: smallest fraction
Next by thread:
Fast way to select those elements from a list that are in another
|