Re: computing Bernoulli numbers
- From: Michel Olagnon <molagnon@xxxxxxxxxxxxxxxxx>
- Date: Thu, 31 Jan 2008 16:32:05 +0100
Bart Vandewoestyne wrote:
On 2008-01-31, Michel Olagnon <molagnon@xxxxxxxxxxxxxxxxx> wrote:
Can't see the interface declaring real_factorial() as (kind=qp) in
the calling routine.
Michel,
I'm afraid I don't understand what you mean with your response.
I did show how real_factorial(n) looks like:
function real_factorial(n) result(res)
integer(kind=i4b), intent(in) :: n
real(kind=qp) :: res
integer(kind=i4b) :: i
res = 1.0_qp
do i = 1,n
res = res*i
end do
end function real_factorial
and I use it like
bn = 2*mysum*real_factorial(n)/((2*pi)**n)
which looks OK to me.
What would you like to know/see more?
interface
function real_factorial(n) result(res)
integer(kind=i4b), intent(in) :: n
real(kind=qp) :: res
end function real_factorial
end interface
or even
external, real(kind=qp) :: real_factorial
in bernoulli_series
Michel
.
- Follow-Ups:
- Re: computing Bernoulli numbers
- From: Bart Vandewoestyne
- Re: computing Bernoulli numbers
- References:
- computing Bernoulli numbers
- From: Bart Vandewoestyne
- Re: computing Bernoulli numbers
- From: Michel Olagnon
- Re: computing Bernoulli numbers
- From: Bart Vandewoestyne
- computing Bernoulli numbers
- Prev by Date: Re: Fortran 2003: abstract interfaces
- Next by Date: Re: computing Bernoulli numbers
- Previous by thread: Re: computing Bernoulli numbers
- Next by thread: Re: computing Bernoulli numbers
- Index(es):
Relevant Pages
|
|