Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

subroutine call in a function

Status
Not open for further replies.

virk24

Technical User
Apr 6, 2023
4
NL
Hello all!

Decades ago I was busy with Fortran. Currently one question: Is it allow to call a subroutine in a function like:
Code:
real function f(x)
  real::x,t1misch
  pa1=0.407
  ha=-113.3
  hd12=1330.
  xd1hv=1350.
  x1misch=x
  call glgew(x1misch,xd1hv,t1misch,pa1,2)
  call hflues(x1misch,t1misch,pa1,hneu1)
  faktor=(x1misch-xa)/(1.-xa)
  h1mischhv=(1.-faktor)*ha+faktor*hd12
  f=h1mischhv-hneu1
  return
end function
 
Thank you, it works!

Greetings from Aachen, Germany
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top