It appears that the message board will not accept the spreadsheet
attachment.  Sorry.

Leigh

  _____  

From: Leigh J. Halliwell [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, May 08, 2007 6:05 PM
To: 'Programming forum'
Subject: RE: [Jprogramming] Digamma function

 

Dear J Forum:

 

Thank you all for your comments.  Indeed, it is better to calculate lngamma
from numerical recipies than to take the log of the J function.  I compared
J with numerical differentiation against R in the domain [0, 10]. (See
attached spreadsheet.)  Lngamma and digamma (first numerical derivative D.1)
were good. Trigamma was fair, and tetragamma was nonsense.  Trigamma was a
little better if I defined it as D.1 of digamma than as D.2 of lngamma.  In
no way could a get a good calculation of tetragamma.  This just goes to show
that I'll have to program it from some numerical recipe to assure accuracy.
Thanks. 

 

Sincerely,

 

Leigh

 

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of R.A. MacDonald
Sent: Tuesday, May 08, 2007 4:03 PM
To: Programming forum
Subject: Re: [Jprogramming] Digamma function

 

Leigh;

 

Do you have examples: x y pairs where you can test y = foo D.n x?  I 

suspect that Roger et al have covered many of the usual suspects: 

polynomials, trig functions, even gamma... the J help page for D. seems 

to confirm this.

 

Leigh J. Halliwell wrote:

> Dear Raul and J Forum:

> 

> I was aware of the D. operator, and admire the solution.  My only question

> is how accurately D. performs numerical differentiation.  Can I rely on
it,

> or should I seek numerical methods for deriving the gamma functions?

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to