I haven't had much luck searching for an answer, maybe a guru here has one.
This is the basic structure of my program:
program main
open(42,file='output.dat')
do while(x)
process a bunch of data
call output_function
end do
close(42)
end program
subroutine output_function
write(42,y) data_set N
end subroutine
The problem: the program writes many many data sets... but then stops. A new file, 'fort.42' is created, and the last data sets are written here - but many intermediate data sets are lost! This problem persists using Absoft fortran, gfortran, and g95.
Why is this, and how do I work around it? Is it simply a matter of writing too much data to a single datafile?
Thank you for your help.
This is the basic structure of my program:
program main
open(42,file='output.dat')
do while(x)
process a bunch of data
call output_function
end do
close(42)
end program
subroutine output_function
write(42,y) data_set N
end subroutine
The problem: the program writes many many data sets... but then stops. A new file, 'fort.42' is created, and the last data sets are written here - but many intermediate data sets are lost! This problem persists using Absoft fortran, gfortran, and g95.
Why is this, and how do I work around it? Is it simply a matter of writing too much data to a single datafile?
Thank you for your help.