Re: What inspite FindInstance ?
- To: mathgroup at smc.vnet.net
- Subject: [mg108000] Re: [mg107955] What inspite FindInstance ?
- From: Daniel Lichtblau <danl at wolfram.com>
- Date: Fri, 5 Mar 2010 04:30:39 -0500 (EST)
- References: <201003041025.FAA26461@smc.vnet.net>
Artur wrote:
> Dear Mathematica Gurus,
>
> Mathematical problem is following:
> Find rational numbers a,b,c such that
> (Pi^2)*a+b+c*Catalan==Zeta[2,5/k] for some k
> e.g.
> FindInstance[
> Zeta[2, 5/4] -a Pi^2 - b - c Catalan == 0, {a, b, c}, Rationals]
> give answer
> FindInstance::nsmet: The methods available to FindInstance are
> insufficient to find the requested instances or prove they do not exist. >>
>
>
> What inspite FindInstance? (I know that we can do 6 loops (3
> Denominators and 3 Numerators) but we have to have luck to give good
> range of loops..
>
> Good answer for my example is {a,b,c}={1,-16,8}but in general case these
> a,b,c will be rationals (not integers)
> e.g. (Pi^2)*a+b+c*Catalan==Zeta[2,5/2] we have {a,b,c}={1/2,-40/9,0}
> but this last case Mathematica deduced autmathically if we execute :
> Zeta[2,5/2]
> first one none.
>
> Best wishes
> Artur
Can be done using numerical approximation. One might then need to
provide proof that the given rationals are in fact correct (or not; I
make no attempt to check results).
There might be something already built in to Mathematica for this, but I
did not find anything in a brief search. So here is some code. It is
based on lattice reduction. One first finds an integer relation between
target and a given set of values. One then simply divides through by the
multiplier used for the target, in order to get rational multipliers for
the values.
findRelation[target_, vals_, prec_] := Module[
{nvals, lat, redlat, relation},
nvals = Round[10^prec*N[Append[vals, -target], prec]];
lat = Transpose[Join[IdentityMatrix[Length[nvals]], {nvals}]];
redlat = LatticeReduce[lat];
relation = Most[First[redlat]];
Most[relation]/Last[relation]
]
Here are your examples:
In[93]:= vals = {Pi^2, 1, Catalan};
findRelation[Zeta[2, 5/4], vals, 50]
findRelation[Zeta[2, 5/2], vals, 50]
Out[94]= {1, -16, 8}
Out[95]= {1/2, -(40/9), 0}
Daniel Lichtblau
Wolfram Research
- References:
- What inspite FindInstance ?
- From: Artur <grafix@csl.pl>
- What inspite FindInstance ?