My environment is Oracle VM (Ubuntu)==>GFortran.
I have a problem with my GFortran. I have an input file
(anglesV1.dat) with two columns of numbers:
Then I run a subroutine that reads them and prints them on the screen:
real*8 :: phi,theta
integer*4 :: counter
open (unit=1,file='anglesV1.dat', status='old')
counter = 0
10 FORMAT (2F12.5)
do while (counter .lt. 20)
counter = counter + 1
read (1,10) theta,phi
write (6,10) theta,phi
end subroutine determinant
This is what I get in the terminal:
I don't understand the result. In the first column all exponents are -1. It means that the numbers (mantissas) must be multiplied by 10 to the power -1, meaning it is 1/10, correct? So when I use F12.6 format the numbers in the first column should come out like this:
In the second column the exponents are +1 meaning that the mantissas should be multiplied by 10.0, that is:
Why do I have negative sign in the output for the second column?
Please help, thanks.