Re: A question regarding a hyperbolic geometric function

• To: mathgroup at smc.vnet.net
• Subject: [mg86423] Re: [mg86396] A question regarding a hyperbolic geometric function
• From: "Ali K. Ozdagli" <ozdagli at gmail.com>
• Date: Tue, 11 Mar 2008 02:57:07 -0500 (EST)
• References: <200803100704.CAA24775@smc.vnet.net>

```Hi Bob and all,

I originally figured this problem while I was working with a second
order ODE of which solution involves Hypergeometric1F1. I have plugged
the solution back to the ODE and it turned out that the equation is
not satisfied for all values of the independent variable. I know the
solution is correct as I have checked it both with Mathematica and
another software. The mistake in the result becomes apparent when you
check the accuracy and precision with Accuracy[] and Precision[]. For
example, Hypergeometric1F1[-26.9, -20.1, 30000] gives

5.868090710725125*10^13007

However, if you check accuracy and precision of the result you get

Accuracy[Hypergeometric1F1[-26.9, -20.1, 30000]] = -12991.8 (negative is bad!!!)
Precision[Hypergeometric1F1[-26.9, -20.1, 30000]] = 15.9546

Where the latter is also the machine precision in Mathematica. This
means that the results are precisely wrong although we want them to be
roughly correct. :)

Any ideas about this?

Best,

Ali

On 3/10/08, Bob Hanlon <hanlonr at cox.net> wrote:
> v1 = Hypergeometric1F1[-26.9, -20.1, 30000]
>
>  5.86809071072512533577549124209830605005026`\
>   15.954589770191005*^13007
>
>  Use exact values until evaluating the Hypergeometric1F1 with extended precision
>
>  v2 = N[Hypergeometric1F1[-269/10, -201/10, 30000], 100]
>
>  5.86809071072500808515263985241332834422719\
>   \
>  6477241041525402740155487068020893691436344\
>   \
>  4849172908349727305685895816448516416585189\
>   1451997662`100.*^13007
>
>  Although even without extra precision v1 is very close to v2
>
>  (v1 - v2)/v2
>
>  1.99810515261962031039159`2.2552081099371497\
>   *^-14
>
>
>
>  Bob Hanlon
>
>
>  ---- "Ali K. Ozdagli" <ozdagli at gmail.com> wrote:
>  > Hi,
>  >
>  > I am working with Mathematica in order to solve an ordinary
>  > differential equation with several boundary conditions. It turned out
>  > that the solution is Kummer confluent hypergeometric function,
>  > HyperGeometric1F1[a,b,x]. My problem is that for the values of a, b
>  > and x I am interested in, e.g. a=-26.9, b=-20.1, x=300000, the
>  > numerical accuracy of Mathematica is very poor.
>  >
>  > Can somebody suggest me a way to improve the mathematical accuracy of
>  > HyperGeometric1F1? I prefer a quick and easy way but also appreciate
>  > any hard way.
>  >
>  > Best,
>  >
>  > Ali
>  >
>  > --
>  >
>  > Ali K. Ozdagli
>  > Ph.D. Student in Economics
>  > at University of Chicago
>  >
>
>

--

Ali K. Ozdagli
Ph.D. Student in Economics
at University of Chicago

```

• Prev by Date: Re: Re: Re: Assignment problem
• Next by Date: Re: How to use Thread when second argument to function is a list of
• Previous by thread: Re: A question regarding a hyperbolic geometric function
• Next by thread: Re: A question regarding a hyperbolic geometric function