Hi,
I am new to Fortran. I can not understand why the following code
produce strange result : The print out N is always 0, no matter the
what size the array b is ( I thought it should be 3, in this case)
Can anyone give me a reason? Thanks.
Richard
--------------------------------------------------------------------
program test
real*8, dimension(3) :: b
real*8 :: e
e=RMSE(b)
end program
function RMSE(Integral)result(e)
real*8, dimension(:), intent(in) :: Integral
real*8 :: e
integer :: N = size(Integral)
e=1.
print*, N
end function RMSE
|