help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Asymptotic Expansions of acosh(x) for large x (was Unidentified s ubject


From: John W. Eaton
Subject: Asymptotic Expansions of acosh(x) for large x (was Unidentified s ubject!)
Date: Wed, 4 May 2005 22:24:54 -0400

On  4-May-2005, Hall, Benjamin wrote:

| >I've got a problem calculating "acosh". I have to calculate cosh^(-1) of
| >a very large complex number (-7.2718e+15 + 1.3382e+15i). If I try to

The trigonometric functions defined in the liboctave/lo-mappers.cc
file and also those defined in the scripts/elfun directory have
simplistic textbook definitions.  These are good for many purposes,
but as you have found, they may have limited ranges.

The reason that these functions use the textbook definitions is
because it was quick and easy to do, I had limited time, and so far,
no one has bothered to improve them.

It would be useful if someone who is interested in this problem could
work on that.  This project is perfect for someone who knows a bit
about programming and math.  But it doesn't require a detailed
knowledge of the internals of Octave.  The only important thing is
that the implementation must be independent or use code that is
distributed under terms that are compatible with the GPL.  You can't
adapt some proprietary implementation (this goes for all Octave
development, but seems worth repeating).

| The wolfram website indicates some asymtotic expansions for acosh(x) for
| large x
| 
| http://functions.wolfram.com/ElementaryFunctions/ArcCosh/06/01/04/
| 
| For your case it looks like 2 terms may be enough:
| 
| 
| octave:20> z = -7.28e+15 + 1.34e+15i
| z = -7.2800e+15 + 1.3400e+15i
| 
| ### Asymtotic expansion for acosh(z) for large z
| octave:21> y = log( -4*z^2 ) / 2 - pi*sqrt( -z^2 ) / (2*z)
| y = 37.2337 +  2.9596i

This might be better, but as written the expression has some problems.
You probably don't want to square Z unnecessarily.  I think this
expression can be rewritten to avoid that.

jwe



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]