Closed jackcshigz closed 2 years ago
Hello jackcshigz,
the name of the program shouldn't be an issue. In the error message is says MAIN__
because that's the internal name, so the OS knows where to start. You can keeps the name as is.
You need to keep in mind that Fortran (unlike C) also has module file (.mod) in addition to the .o files. Try compiling like this:
ifort npy.f90 dat_to_npy.f90 -o dat_to_txt.exe
It works! Thank you very much!
Hi!, I have very little experience with Fortran, but I still hope to use your script to save some Fortran arrays as npy files. And I am experiencing some issues right now. First of all, I have put the npy.f90 file and the simulation code in the directory And then in the simulation code, I added the
call save_npy("pressure.npy", p)
just after where the Fortran code reads the UNFORMATTED Fortran array.When I compile the main code, I get an error message
So I wonder if I need to compile npy.f90 before compiling my main code.
Also, the name of my main code is not called "main", instead it is Page up
PROGRAM als_projection_method
so I wonder I need to change somewhere to make things work and still keep the program nameals_projection_method
Thanks