aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrideout <rideout@89daf98e-ef62-4674-b946-b8ff9de2216c>2003-02-06 16:55:16 +0000
committerrideout <rideout@89daf98e-ef62-4674-b946-b8ff9de2216c>2003-02-06 16:55:16 +0000
commit4a7d93c3cf6d52f4245a57550578b64a70dc79b2 (patch)
treebe74d794e68b111c4260fcb777465d253cbedda9
parentbd0918bb4b99c0283c155bda1b667c1208e4434a (diff)
Use channel 11 rather than 1 for all output to files, since 1 may be
reserved for stdout on some machines. git-svn-id: http://svn.einsteintoolkit.org/cactus/EinsteinAnalysis/AHFinder/trunk@329 89daf98e-ef62-4674-b946-b8ff9de2216c
-rw-r--r--src/AHFinder.F152
-rw-r--r--src/AHFinder_dis.F12
-rw-r--r--src/AHFinder_flow.F50
-rw-r--r--src/AHFinder_gau.F14
-rw-r--r--src/AHFinder_min.F9
-rw-r--r--src/AHFinder_output.F276
6 files changed, 254 insertions, 259 deletions
diff --git a/src/AHFinder.F b/src/AHFinder.F
index 8b25e30..26bd1d3 100644
--- a/src/AHFinder.F
+++ b/src/AHFinder.F
@@ -347,15 +347,15 @@
if (logfile.and.(myproc.eq.0)) then
if (logfile) then
if (myproc.eq.0) then
- open(1,file=logf,form='formatted',status='replace')
- write(1,*)
- write(1,*) 'LOG FILE FOR APPARENT HORIZON FINDER'
- write(1,*)
- write(1,*) 'Note: During an evolution, this file will only'
- write(1,*) 'contain information about the last time that the'
- write(1,*) 'finder was called.'
- write(1,*)
- close(1)
+ open(11,file=logf,form='formatted',status='replace')
+ write(11,*)
+ write(11,*) 'LOG FILE FOR APPARENT HORIZON FINDER'
+ write(11,*)
+ write(11,*) 'Note: During an evolution, this file will only'
+ write(11,*) 'contain information about the last time that the'
+ write(11,*) 'finder was called.'
+ write(11,*)
+ close(11)
end if
end if
end if
@@ -959,7 +959,7 @@
! Open logfile.
if (logfile) then
- open(1,file=logf,form='formatted',
+ open(11,file=logf,form='formatted',
. status='old',position='append')
end if
@@ -1000,22 +1000,22 @@
end if
if (logfile) then
- write(1,*)
- write(1,*) 'Surface found, details below'
- write(1,*)
- write(1,"(A21,ES14.6)") ' Surface area =',intarea_h
- write(1,"(A21,ES14.6)") ' Surface mass =',
+ write(11,*)
+ write(11,*) 'Surface found, details below'
+ write(11,*)
+ write(11,"(A21,ES14.6)") ' Surface area =',intarea_h
+ write(11,"(A21,ES14.6)") ' Surface mass =',
. 0.141047396D0*sqrt(intarea_h)
- write(1,"(A21,ES14.6)") ' Mean value of H =',aux*intexp_h
- write(1,"(A21,ES14.6)") ' Mean value of H^2 =',aux*intexp2_h
- write(1,"(A21,ES14.6)") ' Standard deviation =',
+ write(11,"(A21,ES14.6)") ' Mean value of H =',aux*intexp_h
+ write(11,"(A21,ES14.6)") ' Mean value of H^2 =',aux*intexp2_h
+ write(11,"(A21,ES14.6)") ' Standard deviation =',
. sqrt(abs(aux*intexp2_h - (aux*intexp_h)**2))
- write(1,*)
+ write(11,*)
if (ahf_gaussout.ne.0) then
- write(1,"(A11,ES14.6)") ' circ_eq =',circ_eq
- write(1,"(A11,ES14.6)") ' meri_p1 =',meri_p1
- write(1,"(A11,ES14.6)") ' meri_p2 =',meri_p2
- write(1,*)
+ write(11,"(A11,ES14.6)") ' circ_eq =',circ_eq
+ write(11,"(A11,ES14.6)") ' meri_p1 =',meri_p1
+ write(11,"(A11,ES14.6)") ' meri_p2 =',meri_p2
+ write(11,*)
end if
end if
@@ -1023,7 +1023,7 @@
if (horizon) then
write(*,*) 'The surface seems to be an outer horizon.'
if (logfile) then
- write(1,*) 'The surface seems to be an outer horizon.'
+ write(11,*) 'The surface seems to be an outer horizon.'
end if
else
write(*,*) 'The surface is probably an outer horizon, but'
@@ -1031,17 +1031,17 @@
write(*,*) 'not small enough. Try a larger lmax, or a'
write(*,*) 'smaller grid size.'
if (logfile) then
- write(1,*) 'The surface is probably an outer horizon, but'
- write(1,*) 'the mean of the square of the expansion is'
- write(1,*) 'not small enough. Try a larger lmax, or a'
- write(1,*) 'smaller grid size.'
+ write(11,*) 'The surface is probably an outer horizon, but'
+ write(11,*) 'the mean of the square of the expansion is'
+ write(11,*) 'not small enough. Try a larger lmax, or a'
+ write(11,*) 'smaller grid size.'
end if
end if
else if (mtype.eq.2) then
if (horizon) then
write(*,*) 'The surface seems to be an inner horizon.'
if (logfile) then
- write(1,*) 'The surface seems to be an inner horizon.'
+ write(11,*) 'The surface seems to be an inner horizon.'
end if
else
write(*,*) 'The surface is probably an inner horizon, but'
@@ -1049,10 +1049,10 @@
write(*,*) 'not small enough. Try a larger lmax, or a'
write(*,*) 'smaller grid size.'
if (logfile) then
- write(1,*) 'The surface is probably an inner horizon, but'
- write(1,*) 'the mean of the square of the expansion is'
- write(1,*) 'not small enough. Try a larger lmax, or a'
- write(1,*) 'smaller grid size.'
+ write(11,*) 'The surface is probably an inner horizon, but'
+ write(11,*) 'the mean of the square of the expansion is'
+ write(11,*) 'not small enough. Try a larger lmax, or a'
+ write(11,*) 'smaller grid size.'
end if
end if
else if (mtype.eq.3)then
@@ -1061,14 +1061,14 @@
write(*,*) '(the integral of the expansion is negative'
write(*,*) 'on both sides.)'
if (logfile) then
- write(1,*) 'The surface seems to be a marginal horizon'
- write(1,*) '(the integral of the expansion is negative'
- write(1,*) 'on both sides.)'
+ write(11,*) 'The surface seems to be a marginal horizon'
+ write(11,*) '(the integral of the expansion is negative'
+ write(11,*) 'on both sides.)'
end if
else
write(*,*) 'The surface seems to be a trapped surface.'
if (logfile) then
- write(1,*) 'The surface seems to be a trapped surface.'
+ write(11,*) 'The surface seems to be a trapped surface.'
end if
end if
else if (mtype.eq.4)then
@@ -1077,14 +1077,14 @@
write(*,*) '(the integral of the expansion is positive'
write(*,*) 'on both sides.)'
if (logfile) then
- write(1,*) 'The surface seems to be a marginal horizon'
- write(1,*) '(the integral of the expansion is positive'
- write(1,*) 'on both sides.)'
+ write(11,*) 'The surface seems to be a marginal horizon'
+ write(11,*) '(the integral of the expansion is positive'
+ write(11,*) 'on both sides.)'
end if
else
write(*,*) 'The surface does not seem to be a horizon.'
if (logfile) then
- write(1,*) 'The surface does not seem to be a horizon.'
+ write(11,*) 'The surface does not seem to be a horizon.'
end if
end if
end if
@@ -1115,22 +1115,22 @@
if (logfile) then
- write(1,*)
- write(1,*) 'Shape coefficients:'
+ write(11,*)
+ write(11,*) 'Shape coefficients:'
if (offset) then
- write(1,*)
- write(1,"(A6,ES14.6)") ' xc =',xc
- write(1,"(A6,ES14.6)") ' yc =',yc
- write(1,"(A6,ES14.6)") ' zc =',zc
+ write(11,*)
+ write(11,"(A6,ES14.6)") ' xc =',xc
+ write(11,"(A6,ES14.6)") ' yc =',yc
+ write(11,"(A6,ES14.6)") ' zc =',zc
end if
- write(1,*)
+ write(11,*)
- write(1,"(A4,I2,A3,ES14.6)") ' c0(',0,') =',c0(0)
+ write(11,"(A4,I2,A3,ES14.6)") ' c0(',0,') =',c0(0)
do l=1+stepz,lmax,1+stepz
- write(1,"(A4,I2,A3,ES14.6)") ' c0(',l,') =',c0(l)
+ write(11,"(A4,I2,A3,ES14.6)") ' c0(',l,') =',c0(l)
end do
end if
@@ -1163,21 +1163,21 @@
end if
if (logfile) then
- write(1,*)
+ write(11,*)
do l=1,lmax
do m=1,l
if (stepz*mod(l-m,2).eq.0) then
- write(1,"(A4,I2,A1,I2,A4,ES14.6)") ' cc(',
+ write(11,"(A4,I2,A1,I2,A4,ES14.6)") ' cc(',
. l,',',m,') =',cc(l,m)
end if
end do
end do
- write(1,*)
+ write(11,*)
do l=1,lmax
do m=1,l
if (stepz*mod(l-m,2).eq.0) then
- write(1,"(A4,I2,A1,I2,A4,ES14.6)") ' cs(',
+ write(11,"(A4,I2,A1,I2,A4,ES14.6)") ' cs(',
. l,',',m,') =',cs(l,m)
end if
end do
@@ -1203,11 +1203,11 @@
if (logfile) then
- write(1,*)
+ write(11,*)
do l=1,lmax
do m=1,l
if (stepz*mod(l-m,2).eq.0) then
- write(1,"(A4,I2,A1,I2,A4,ES14.6)") ' cc(',
+ write(11,"(A4,I2,A1,I2,A4,ES14.6)") ' cc(',
. l,',',m,') =',cc(l,m)
end if
end do
@@ -1223,10 +1223,10 @@
write(*,*)
if (logfile) then
- write(1,*)
- write(1,*) 'END OF LOG FILE'
- write(1,*)
- close(1)
+ write(11,*)
+ write(11,*) 'END OF LOG FILE'
+ write(11,*)
+ close(11)
end if
! If we found a surface that is not a horizon and we
@@ -1238,7 +1238,7 @@
! Open logfile.
if (logfile) then
- open(1,file=logf,form='formatted',
+ open(11,file=logf,form='formatted',
. status='old',position='append')
end if
@@ -1248,9 +1248,9 @@
write(*,*) 'No horizon found.'
if (logfile) then
- write(1,*)
- write(1,*) 'No horizon found.'
- write(1,*)
+ write(11,*)
+ write(11,*) 'No horizon found.'
+ write(11,*)
end if
! Close logfile
@@ -1258,10 +1258,10 @@
write(*,*)
if (logfile) then
- write(1,*)
- write(1,*) 'END OF LOG FILE'
- write(1,*)
- close(1)
+ write(11,*)
+ write(11,*) 'END OF LOG FILE'
+ write(11,*)
+ close(11)
end if
end if
@@ -1278,7 +1278,7 @@
! Open logfile.
if (logfile) then
- open(1,file=logf,form='formatted',
+ open(11,file=logf,form='formatted',
. status='old',position='append')
end if
@@ -1288,9 +1288,9 @@
write(*,*) 'No horizon found.'
if (logfile) then
- write(1,*)
- write(1,*) 'No horizon found.'
- write(1,*)
+ write(11,*)
+ write(11,*) 'No horizon found.'
+ write(11,*)
end if
! Close logfile
@@ -1298,10 +1298,10 @@
write(*,*)
if (logfile) then
- write(1,*)
- write(1,*) 'END OF LOG FILE'
- write(1,*)
- close(1)
+ write(11,*)
+ write(11,*) 'END OF LOG FILE'
+ write(11,*)
+ close(11)
end if
end if
diff --git a/src/AHFinder_dis.F b/src/AHFinder_dis.F
index 47bcb82..e44be98 100644
--- a/src/AHFinder_dis.F
+++ b/src/AHFinder_dis.F
@@ -590,13 +590,13 @@
if (myproc.eq.0) then
inquire(file=disf, exist=disf_exists)
if (disf_exists) then
- open(1,file=disf,form='formatted',status='old', position='append')
+ open(11,file=disf,form='formatted',status='old', position='append')
else
- open(1,file=disf,form='formatted',status='replace')
- write(1,"(A18)") '" Horizon distance'
+ open(11,file=disf,form='formatted',status='replace')
+ write(11,"(A18)") '" Horizon distance'
end if
- write(1,"(2ES14.6)") cctk_time,d12
- close(1)
+ write(11,"(2ES14.6)") cctk_time,d12
+ close(11)
end if
@@ -605,5 +605,3 @@
! ***************
end subroutine AHFinder_dis
-
-
diff --git a/src/AHFinder_flow.F b/src/AHFinder_flow.F
index b5e4300..e867c83 100644
--- a/src/AHFinder_flow.F
+++ b/src/AHFinder_flow.F
@@ -366,7 +366,7 @@
logf = filestr(1:nfile)//"/ahf_logfile"
if (logfile.and.(myproc.eq.0)) then
- open(1,file=logf,form='formatted',status='old',
+ open(11,file=logf,form='formatted',status='old',
. position='append')
end if
@@ -413,8 +413,8 @@
if (logfile) then
- write(1,*)
- write(1,"(A16,I3)") ' FLOW ITERATION ',i
+ write(11,*)
+ write(11,"(A16,I3)") ' FLOW ITERATION ',i
if (intarea.ne.zero) then
aux = one/intarea
@@ -422,27 +422,27 @@
aux = one
end if
- write(1,*)
- write(1,"(A21,ES14.6)") ' Surface area =',intarea
- write(1,"(A21,ES14.6)") ' Mean value of H =',aux*intexp
- write(1,"(A21,ES14.6)") ' Mean value of H^2 =',aux*intexp2
- write(1,"(A21,ES14.6)") ' ahfdiff/ahfsum =',ahfdiff/ahfsum
+ write(11,*)
+ write(11,"(A21,ES14.6)") ' Surface area =',intarea
+ write(11,"(A21,ES14.6)") ' Mean value of H =',aux*intexp
+ write(11,"(A21,ES14.6)") ' Mean value of H^2 =',aux*intexp2
+ write(11,"(A21,ES14.6)") ' ahfdiff/ahfsum =',ahfdiff/ahfsum
if (offset) then
- write(1,*)
- write(1,"(A6,ES14.6)") ' xc =',xc
- write(1,"(A6,ES14.6)") ' yc =',yc
- write(1,"(A6,ES14.6)") ' zc =',zc
+ write(11,*)
+ write(11,"(A6,ES14.6)") ' xc =',xc
+ write(11,"(A6,ES14.6)") ' yc =',yc
+ write(11,"(A6,ES14.6)") ' zc =',zc
end if
- write(1,*)
- write(1,"(A20)") ' Shape coefficients:'
- write(1,*)
+ write(11,*)
+ write(11,"(A20)") ' Shape coefficients:'
+ write(11,*)
- write(1,"(A4,I2,A3,ES14.6)") ' c0(',0,') =',c0(0)
+ write(11,"(A4,I2,A3,ES14.6)") ' c0(',0,') =',c0(0)
do l=1+stepz,lmax,1+stepz
- write(1,"(A4,I2,A3,ES14.6)") ' c0(',l,') =',c0(l)
+ write(11,"(A4,I2,A3,ES14.6)") ' c0(',l,') =',c0(l)
end do
end if
@@ -477,21 +477,21 @@
if (logfile) then
- write(1,*)
+ write(11,*)
do l=1,lmax
do m=1,l
if (stepz*mod(l-m,2).eq.0) then
- write(1,"(A4,I2,A1,I2,A4,ES14.6)") ' cc(',
+ write(11,"(A4,I2,A1,I2,A4,ES14.6)") ' cc(',
. l,',',m,') =',cc(l,m)
end if
end do
end do
- write(1,*)
+ write(11,*)
do l=1,lmax
do m=1,l
if (stepz*mod(l-m,2).eq.0) then
- write(1,"(A4,I2,A1,I2,A4,ES14.6)") ' cs(',
+ write(11,"(A4,I2,A1,I2,A4,ES14.6)") ' cs(',
. l,',',m,') =',cs(l,m)
end if
end do
@@ -520,12 +520,12 @@
if (logfile) then
- write(1,*)
+ write(11,*)
do l=1,lmax
do m=1,l
if (stepz*mod(l-m,2).eq.0) then
- write(1,"(A4,I2,A1,I2,A4,ES14.6)") ' cc(',
+ write(11,"(A4,I2,A1,I2,A4,ES14.6)") ' cc(',
. l,',',m,') =',cc(l,m)
end if
end do
@@ -542,7 +542,7 @@
! Close logfile.
if (logfile.and.(myproc.eq.0)) then
- close(1)
+ close(11)
end if
@@ -604,5 +604,3 @@
! ***************
end subroutine AHFinder_flow
-
-
diff --git a/src/AHFinder_gau.F b/src/AHFinder_gau.F
index 8005843..ad79044 100644
--- a/src/AHFinder_gau.F
+++ b/src/AHFinder_gau.F
@@ -1180,13 +1180,13 @@
else
- open(1,file=gaussf,form='formatted', status='old',
+ open(11,file=gaussf,form='formatted', status='old',
. position='append')
- write(1,*)
- write(1,"(A11,I4)") '# Time step',cctk_iteration
- write(1,"(A6,ES11.3)") '# Time',cctk_time
- write(1,"(A6,I4)") '# Call',ahf_ncall
+ write(11,*)
+ write(11,"(A11,I4)") '# Time step',cctk_iteration
+ write(11,"(A6,ES11.3)") '# Time',cctk_time
+ write(11,"(A6,I4)") '# Call',ahf_ncall
end if
@@ -1194,13 +1194,13 @@
do i=1,ntheta+1
do j=1,nphi+1
- write(1,"(ES11.3)") gaussian(i,j)
+ write(11,"(ES11.3)") gaussian(i,j)
end do
end do
! Close file.
- close(1)
+ close(11)
end if
diff --git a/src/AHFinder_min.F b/src/AHFinder_min.F
index 1c4a044..de9856e 100644
--- a/src/AHFinder_min.F
+++ b/src/AHFinder_min.F
@@ -247,11 +247,11 @@
write(*,*) 'AHFinder: Too many iterations.'
if (logfile) then
- open(1,file=logf,form='formatted',
+ open(11,file=logf,form='formatted',
. status='old',position='append')
- write(1,*)
- write(1,*) 'AHFinder: Too many iterations.'
- close(1)
+ write(11,*)
+ write(11,*) 'AHFinder: Too many iterations.'
+ close(11)
end if
end if
@@ -270,4 +270,3 @@
! ***************
end subroutine AHFinder_min
-
diff --git a/src/AHFinder_output.F b/src/AHFinder_output.F
index 9073c3b..1369dcb 100644
--- a/src/AHFinder_output.F
+++ b/src/AHFinder_output.F
@@ -61,54 +61,54 @@ c some compilers cannot trim an empty string, so we add at least one char
gauss2f = filestr(1:nfile) // "/ahf_2.gauss"
- open(1,file=massf,form='formatted',status='replace')
- write(1,"(A14)") '" Horizon mass'
- close(1)
+ open(11,file=massf,form='formatted',status='replace')
+ write(11,"(A14)") '" Horizon mass'
+ close(11)
- open(1,file=radf,form='formatted',status='replace')
- write(1,"(A26)") '" Horizon radius'
- close(1)
+ open(11,file=radf,form='formatted',status='replace')
+ write(11,"(A26)") '" Horizon radius'
+ close(11)
- open(1,file=circeqf,form='formatted',status='replace')
- write(1,"(A26)") '" Equatorial circumference'
- close(1)
+ open(11,file=circeqf,form='formatted',status='replace')
+ write(11,"(A26)") '" Equatorial circumference'
+ close(11)
- open(1,file=merip1f,form='formatted',status='replace')
- write(1,"(A27)") '" Length of meridian, phi=0'
- close(1)
+ open(11,file=merip1f,form='formatted',status='replace')
+ write(11,"(A27)") '" Length of meridian, phi=0'
+ close(11)
- open(1,file=merip1f,form='formatted',status='replace')
- write(1,"(A27)") '" Length of meridian, phi=0'
- close(1)
+ open(11,file=merip1f,form='formatted',status='replace')
+ write(11,"(A27)") '" Length of meridian, phi=0'
+ close(11)
- open(1,file=merip2f,form='formatted',status='replace')
- write(1,"(A30)") '" Length of meridian, phi=pi/2'
- close(1)
+ open(11,file=merip2f,form='formatted',status='replace')
+ write(11,"(A30)") '" Length of meridian, phi=pi/2'
+ close(11)
- open(1,file=areaf,form='formatted',status='replace')
- write(1,"(A14)") '" Horizon area'
- close(1)
+ open(11,file=areaf,form='formatted',status='replace')
+ write(11,"(A14)") '" Horizon area'
+ close(11)
- open(1,file=asymxf,form='formatted',status='replace')
- write(1,"(A29)") '" Asymmetries on x reflection'
- close(1)
+ open(11,file=asymxf,form='formatted',status='replace')
+ write(11,"(A29)") '" Asymmetries on x reflection'
+ close(11)
- open(1,file=asymyf,form='formatted',status='replace')
- write(1,"(A29)") '" Asymmetries on y reflection'
- close(1)
+ open(11,file=asymyf,form='formatted',status='replace')
+ write(11,"(A29)") '" Asymmetries on y reflection'
+ close(11)
- open(1,file=asymzf,form='formatted',status='replace')
- write(1,"(A29)") '" Asymmetries on z reflection'
- close(1)
+ open(11,file=asymzf,form='formatted',status='replace')
+ write(11,"(A29)") '" Asymmetries on z reflection'
+ close(11)
- open(1,file=almf,form='formatted',status='replace')
- write(1,"(A21)") '# Radial coefficients'
- write(1,"(A1)") '#'
- close(1)
+ open(11,file=almf,form='formatted',status='replace')
+ write(11,"(A21)") '# Radial coefficients'
+ write(11,"(A1)") '#'
+ close(11)
- open(1,file=disf,form='formatted',status='replace')
- write(1,"(A18)") '" Horizon distance'
- close(1)
+ open(11,file=disf,form='formatted',status='replace')
+ write(11,"(A18)") '" Horizon distance'
+ close(11)
if (find3) then
call AHFinder_WriteGaussHeader(CCTK_PASS_FTOF, gauss0f)
@@ -133,37 +133,37 @@ c some compilers cannot trim an empty string, so we add at least one char
call AHFinder_SetReflections(CCTK_ARGUMENTS)
- open(1,file=filename,form='formatted', status='replace')
+ open(11,file=filename,form='formatted', status='replace')
- write(1,"(A20)") '# GAUSSIAN CURVATURE'
- write(1,"(A1)") '#'
- write(1,"(A35)") '# The data is written in a loop as:'
- write(1,"(A1)") '#'
- write(1,"(A17)") '# do i=1,ntheta'
- write(1,"(A18)") '# do j=1,nphi'
- write(1,"(A27)") '# write gaussian(i,j)'
- write(1,"(A11)") '# end do'
- write(1,"(A8)") '# end do'
- write(1,"(A1)") '#'
- write(1,"(A40)") '# theta and phi are subdivided uniformly'
- write(1,"(A26)") '# according to symmetries:'
- write(1,"(A1)") '#'
- write(1,"(A36)") '# phi=[0,2 pi] (refx=refy=.false.)'
- write(1,"(A44)") '# phi=[0,pi] (refx=.false., refy=.true.)'
- write(1,"(A35)") '# phi=[0,pi/2] (refx=refy=.true.)'
- write(1,"(A1)") '#'
- write(1,"(A31)") '# theta=[0,pi] (refz=.false.)'
- write(1,"(A30)") '# theta=[0,pi/2] (refz=.true.)'
- write(1,"(A1)") '#'
-
- write(1,"(A9,L1)") '# refx = ',refx
- write(1,"(A9,L1)") '# refy = ',refy
- write(1,"(A9,L1)") '# refz = ',refz
- write(1,"(A1)") '#'
- write(1,"(A11,I7)") '# ntheta = ',(ahf_ntheta+1)
- write(1,"(A11,I7)") '# nphi = ',(ahf_nphi+1)
-
- close(1)
+ write(11,"(A20)") '# GAUSSIAN CURVATURE'
+ write(11,"(A1)") '#'
+ write(11,"(A35)") '# The data is written in a loop as:'
+ write(11,"(A1)") '#'
+ write(11,"(A17)") '# do i=1,ntheta'
+ write(11,"(A18)") '# do j=1,nphi'
+ write(11,"(A27)") '# write gaussian(i,j)'
+ write(11,"(A11)") '# end do'
+ write(11,"(A8)") '# end do'
+ write(11,"(A1)") '#'
+ write(11,"(A40)") '# theta and phi are subdivided uniformly'
+ write(11,"(A26)") '# according to symmetries:'
+ write(11,"(A1)") '#'
+ write(11,"(A36)") '# phi=[0,2 pi] (refx=refy=.false.)'
+ write(11,"(A44)") '# phi=[0,pi] (refx=.false., refy=.true.)'
+ write(11,"(A35)") '# phi=[0,pi/2] (refx=refy=.true.)'
+ write(11,"(A1)") '#'
+ write(11,"(A31)") '# theta=[0,pi] (refz=.false.)'
+ write(11,"(A30)") '# theta=[0,pi/2] (refz=.true.)'
+ write(11,"(A1)") '#'
+
+ write(11,"(A9,L1)") '# refx = ',refx
+ write(11,"(A9,L1)") '# refy = ',refy
+ write(11,"(A9,L1)") '# refz = ',refz
+ write(11,"(A1)") '#'
+ write(11,"(A11,I7)") '# ntheta = ',(ahf_ntheta+1)
+ write(11,"(A11,I7)") '# nphi = ',(ahf_nphi+1)
+
+ close(11)
end subroutine AHFinder_WriteGaussHeader
@@ -261,10 +261,10 @@ c some compilers cannot trim an empty string, so we add at least one char
inquire(file=massf, exist=massf_exists)
if (massf_exists) then
- open(1,file=massf,form='formatted',status='old',position='append')
+ open(11,file=massf,form='formatted',status='old',position='append')
else
- open(1,file=massf,form='formatted',status='replace')
- write(1,"(A14)") '" Horizon mass'
+ open(11,file=massf,form='formatted',status='replace')
+ write(11,"(A14)") '" Horizon mass'
end if
if (status.and.report) then
@@ -272,18 +272,18 @@ c some compilers cannot trim an empty string, so we add at least one char
else
out_mass = 0.0
end if
- write(1,"(2ES14.6)") cctk_time, out_mass
+ write(11,"(2ES14.6)") cctk_time, out_mass
- close(1)
+ close(11)
! Radius.
inquire(file=radf, exist=radf_exists)
if (radf_exists) then
- open(1,file=radf,form='formatted',status='old',position='append')
+ open(11,file=radf,form='formatted',status='old',position='append')
else
- open(1,file=radf,form='formatted',status='replace')
- write(1,"(A26)") '" Horizon radius'
+ open(11,file=radf,form='formatted',status='replace')
+ write(11,"(A26)") '" Horizon radius'
end if
if (status.and.report) then
@@ -291,18 +291,18 @@ c some compilers cannot trim an empty string, so we add at least one char
else
out_radius = 0.0
end if
- write(1,"(2ES14.6)") cctk_time, out_radius
+ write(11,"(2ES14.6)") cctk_time, out_radius
- close(1)
+ close(11)
! Equatorial circumference.
inquire(file=circeqf, exist=circeqf_exists)
if (circeqf_exists) then
- open(1,file=circeqf,form='formatted',status='old',position='append')
+ open(11,file=circeqf,form='formatted',status='old',position='append')
else
- open(1,file=circeqf,form='formatted',status='replace')
- write(1,"(A26)") '" Equatorial circumference'
+ open(11,file=circeqf,form='formatted',status='replace')
+ write(11,"(A26)") '" Equatorial circumference'
end if
if (status.and.report) then
@@ -310,18 +310,18 @@ c some compilers cannot trim an empty string, so we add at least one char
else
out_perimeter = 0.0
end if
- write(1,"(2ES14.6)") cctk_time, out_perimeter
+ write(11,"(2ES14.6)") cctk_time, out_perimeter
- close(1)
+ close(11)
! Meridians.
inquire(file=merip1f, exist=merip1f_exists)
if (merip1f_exists) then
- open(1,file=merip1f,form='formatted',status='old',position='append')
+ open(11,file=merip1f,form='formatted',status='old',position='append')
else
- open(1,file=merip1f,form='formatted',status='replace')
- write(1,"(A27)") '" Length of meridian, phi=0'
+ open(11,file=merip1f,form='formatted',status='replace')
+ write(11,"(A27)") '" Length of meridian, phi=0'
end if
if (status.and.report) then
@@ -329,16 +329,16 @@ c some compilers cannot trim an empty string, so we add at least one char
else
out_meridian1 = 0.0
end if
- write(1,"(2ES14.6)") cctk_time, out_meridian1
+ write(11,"(2ES14.6)") cctk_time, out_meridian1
- close(1)
+ close(11)
inquire(file=merip2f, exist=merip2f_exists)
if (merip2f_exists) then
- open(1,file=merip2f,form='formatted',status='old', position='append')
+ open(11,file=merip2f,form='formatted',status='old', position='append')
else
- open(1,file=merip2f,form='formatted',status='replace')
- write(1,"(A30)") '" Length of meridian, phi=pi/2'
+ open(11,file=merip2f,form='formatted',status='replace')
+ write(11,"(A30)") '" Length of meridian, phi=pi/2'
end if
if (status.and.report) then
@@ -346,18 +346,18 @@ c some compilers cannot trim an empty string, so we add at least one char
else
out_meridian2 = 0.0
end if
- write(1,"(2ES14.6)") cctk_time, out_meridian2
+ write(11,"(2ES14.6)") cctk_time, out_meridian2
- close(1)
+ close(11)
! Area.
inquire(file=areaf, exist=areaf_exists)
if (areaf_exists) then
- open(1,file=areaf,form='formatted',status='old',position='append')
+ open(11,file=areaf,form='formatted',status='old',position='append')
else
- open(1,file=areaf,form='formatted',status='replace')
- write(1,"(A14)") '" Horizon area'
+ open(11,file=areaf,form='formatted',status='replace')
+ write(11,"(A14)") '" Horizon area'
end if
if (status.and.report) then
@@ -365,9 +365,9 @@ c some compilers cannot trim an empty string, so we add at least one char
else
out_area = 0.0
end if
- write(1,"(2ES14.6)") cctk_time, out_area
+ write(11,"(2ES14.6)") cctk_time, out_area
- close(1)
+ close(11)
! Asymmetries in x. Coefficients cc with odd m, and
! coefficients cs with even m indicate asymmetries
@@ -375,10 +375,10 @@ c some compilers cannot trim an empty string, so we add at least one char
inquire(file=asymxf, exist=asymxf_exists)
if (asymxf_exists) then
- open(1,file=asymxf,form='formatted',status='old', position='append')
+ open(11,file=asymxf,form='formatted',status='old', position='append')
else
- open(1,file=asymxf,form='formatted',status='replace')
- write(1,"(A29)") '" Asymmetries on x reflection'
+ open(11,file=asymxf,form='formatted',status='replace')
+ write(11,"(A29)") '" Asymmetries on x reflection'
end if
out_asymx = 0.0D0
@@ -394,19 +394,19 @@ c some compilers cannot trim an empty string, so we add at least one char
end do
out_asymx = out_asymx / c0(0)
end if
- write(1,"(2ES14.6)") cctk_time, out_asymx
+ write(11,"(2ES14.6)") cctk_time, out_asymx
- close(1)
+ close(11)
! Asymmetries in y. Any cs coefficient different from
! zero indicates asymmetries on reflection y<->-y.
inquire(file=asymyf, exist=asymyf_exists)
if (asymyf_exists) then
- open(1,file=asymyf,form='formatted',status='old', position='append')
+ open(11,file=asymyf,form='formatted',status='old', position='append')
else
- open(1,file=asymyf,form='formatted',status='replace')
- write(1,"(A29)") '" Asymmetries on y reflection'
+ open(11,file=asymyf,form='formatted',status='replace')
+ write(11,"(A29)") '" Asymmetries on y reflection'
end if
out_asymy = 0.0D0
@@ -418,9 +418,9 @@ c some compilers cannot trim an empty string, so we add at least one char
end do
out_asymy = out_asymy / c0(0)
end if
- write(1,"(2ES14.6)") cctk_time, out_asymy
+ write(11,"(2ES14.6)") cctk_time, out_asymy
- close(1)
+ close(11)
! Asymmetries in z. Any coefficient c0 with odd l,
! or any coefficient cc and cs with odd (l-m) indicate
@@ -428,10 +428,10 @@ c some compilers cannot trim an empty string, so we add at least one char
inquire(file=asymzf, exist=asymzf_exists)
if (asymzf_exists) then
- open(1,file=asymzf,form='formatted',status='old',position='append')
+ open(11,file=asymzf,form='formatted',status='old',position='append')
else
- open(1,file=asymzf,form='formatted',status='replace')
- write(1,"(A29)") '" Asymmetries on z reflection'
+ open(11,file=asymzf,form='formatted',status='replace')
+ write(11,"(A29)") '" Asymmetries on z reflection'
end if
out_asymz = 0.0D0
@@ -446,49 +446,49 @@ c some compilers cannot trim an empty string, so we add at least one char
end do
out_asymz = out_asymz / c0(0)
end if
- write(1,"(2ES14.6)") cctk_time, out_asymz
+ write(11,"(2ES14.6)") cctk_time, out_asymz
- close(1)
+ close(11)
! Expansion coefficients.
inquire(file=almf, exist=almf_exists)
if (almf_exists) then
- open(1,file=almf,form='formatted',status='old',position='append')
+ open(11,file=almf,form='formatted',status='old',position='append')
else
- open(1,file=almf,form='formatted',status='replace')
- write(1,"(A21)") '# Radial coefficients'
- write(1,"(A1)") '#'
+ open(11,file=almf,form='formatted',status='replace')
+ write(11,"(A21)") '# Radial coefficients'
+ write(11,"(A1)") '#'
end if
- write(1,"(A12,I4)") '# Time step ',cctk_iteration
- write(1,"(A7,ES14.6)") '# Time ',cctk_time
- write(1,"(A7,I4)") '# Call ',ahf_ncall
+ write(11,"(A12,I4)") '# Time step ',cctk_iteration
+ write(11,"(A7,ES14.6)") '# Time ',cctk_time
+ write(11,"(A7,I4)") '# Call ',ahf_ncall
if (status.and.report) then
if (mtype.eq.1) then
if (horizon) then
- write(1,"(A30,I4)") '# Surface found: Outer horizon'
+ write(11,"(A30,I4)") '# Surface found: Outer horizon'
else
- write(1,"(A31,I4)") '# Surface found: Outer horizon?'
+ write(11,"(A31,I4)") '# Surface found: Outer horizon?'
end if
else if (mtype.eq.2) then
if (horizon) then
- write(1,"(A30,I4)") '# Surface found: Inner horizon'
+ write(11,"(A30,I4)") '# Surface found: Inner horizon'
else
- write(1,"(A31,I4)") '# Surface found: Inner horizon?'
+ write(11,"(A31,I4)") '# Surface found: Inner horizon?'
end if
else if (mtype.eq.3) then
if (horizon) then
- write(1,"(A34,I4)") '# Surface found: Marginal horizon?'
+ write(11,"(A34,I4)") '# Surface found: Marginal horizon?'
else
- write(1,"(A32,I4)") '# Surface found: Trapped surface'
+ write(11,"(A32,I4)") '# Surface found: Trapped surface'
end if
else if (mtype.eq.4) then
if (horizon) then
- write(1,"(A34,I4)") '# Surface found: Marginal horizon?'
+ write(11,"(A34,I4)") '# Surface found: Marginal horizon?'
else
- write(1,"(A30,I4)") '# Surface found: Not a horizon'
+ write(11,"(A30,I4)") '# Surface found: Not a horizon'
end if
end if
@@ -496,13 +496,13 @@ c some compilers cannot trim an empty string, so we add at least one char
out_centery = yc
out_centerz = zc
- write(1,"(A15,3ES14.6)") '# centered on: ', out_centerx, out_centery, out_centerz
+ write(11,"(A15,3ES14.6)") '# centered on: ', out_centerx, out_centery, out_centerz
- write(1,"(A1)") '#'
- write(1,"(A22)") '# a_lm l m'
- write(1,"(A1)") '#'
+ write(11,"(A1)") '#'
+ write(11,"(A22)") '# a_lm l m'
+ write(11,"(A1)") '#'
- write(1,"(ES14.6,2I4)") c0(0),0,0
+ write(11,"(ES14.6,2I4)") c0(0),0,0
if (lmax .gt. 0) then
out_c0 = c0(1:)
@@ -511,20 +511,20 @@ c some compilers cannot trim an empty string, so we add at least one char
do l=1,lmax
do m=l,1,-1
- write(1,"(ES14.6,2I4)") out_cs(l,m),l,-m
+ write(11,"(ES14.6,2I4)") out_cs(l,m),l,-m
end do
- write(1,"(ES14.6,2I4)") out_c0(l),l,0
+ write(11,"(ES14.6,2I4)") out_c0(l),l,0
do m=1,l
- write(1,"(ES14.6,2I4)") out_cc(l,m),l,m
+ write(11,"(ES14.6,2I4)") out_cc(l,m),l,m
end do
end do
end if
- write(1,*)
+ write(11,*)
else
- write(1,"(A18,I4)") '# No surface found'
+ write(11,"(A18,I4)") '# No surface found'
end if
- close(1)
+ close(11)
end if