Hey Guys,(adsbygoogle = window.adsbygoogle || []).push({});

I am converting my code from matlab to fortran. Now in matlab it is rather convenient to write a function which returns multiple variables.

I believe a function in fortran can return only one variable. I think a subroutine can return multiple variables. I was not able to find any syntax help for fortran to write such a routine. I was curious if anyone has any insight into this.

Thanks

Aditya

**Physics Forums | Science Articles, Homework Help, Discussion**

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Return Multiple variables in Fortran

**Physics Forums | Science Articles, Homework Help, Discussion**