Thread Subject: gammainc - check in excel?

Subject: gammainc - check in excel?

From: Erik Gadzinski

Date: 8 Nov, 2009 17:54:01

Message: 1 of 2

This is not a Matlab question exactly, but does anybody know how I would check the code below in excel? I don't think excel can do an incomplete gamma. I was given this piece of code from somebody and I want to check it outside matlab because it is giving me values I didn't expect.

Thanks

gammainc((M+1)^N*(-log(q)),1/N,'upper')

Subject: gammainc - check in excel?

From: Steven Lord

Date: 8 Nov, 2009 22:53:17

Message: 2 of 2


"Erik Gadzinski" <ergadz@yahoo.com> wrote in message
news:hd70jp$1g2$1@fred.mathworks.com...
> This is not a Matlab question exactly, but does anybody know how I would
> check the code below in excel? I don't think excel can do an incomplete
> gamma. I was given this piece of code from somebody and I want to check it
> outside matlab because it is giving me values I didn't expect.
>
> Thanks
>
> gammainc((M+1)^N*(-log(q)),1/N,'upper')

For which values of M, N, and q do you receive values you didn't expect?

Anyway, to check this you can use the integral form of GAMMAINC with the
QUADGK integration function.

http://www.mathworks.com/access/helpdesk/help/techdoc/ref/gamma.html

Or you could check if the values of the input arguments for which you're
evaluating the incomplete gamma function are present in the table of values
for the function in Abramowitz & Stegun (see the second Reference on the
page I linked above.)

--
Steve Lord
slord@mathworks.com
comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ

Tags for this Thread

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

rssFeed for this Thread

Contact us at files@mathworks.com