00001 subroutine printout_axis_irrot_BNS_mpt(impt,filename)
00002 use phys_constant, only : long
00003 use def_metric
00004 use def_matter
00005 use def_velocity_potential
00006 use coordinate_grav_r, only : rg
00007 use coordinate_grav_theta, only : thg
00008 use coordinate_grav_phi, only : phig
00009 use grid_parameter, only : ntgeq, npgxzp, npgxzm, nrg, &
00010 & npgyzp, npgyzm, ntgpolp, ntgpolm
00011 use grid_points_binary_excision, only : irg_exin, irg_exout
00012 use grid_parameter_binary_excision, only :ex_radius
00013 use def_binary_parameter, only : sepa, dis
00014 implicit none
00015 integer :: irg, itg, ipg, impt, npg_l, npg_r, count
00016 real(long) :: work_shift, pari
00017 character(len=1) :: np(5) = (/'1', '2','3', '4', '5'/), char_1
00018 character(30) :: filename
00019
00020 if (impt.eq.1) then
00021 npg_l = npgxzm
00022 npg_r = npgxzp
00023 work_shift = - dis
00024 pari = 1.0
00025 else if(impt.eq.2) then
00026 npg_l = npgxzp
00027 npg_r = npgxzm
00028 work_shift = dis
00029 pari = -1.0
00030 else if(impt.eq.3) then
00031 npg_l = npgxzm
00032 npg_r = npgxzp
00033 work_shift = 0.0d0
00034 pari = 1.0
00035 end if
00036
00037 open(12,file=filename,status='unknown')
00038 count = 0
00039 do irg = nrg, 0, -1
00040 char_1 = ' '
00041 if (impt.ne.3) then
00042 if (irg.gt.irg_exin(ntgeq,npg_l).and.irg.lt.irg_exout(ntgeq,npg_l)) then
00043 char_1 = '#'
00044 count = count + 1
00045 end if
00046 end if
00047 write(12,'(a1,1p,10e20.12)') char_1, -rg(irg)+work_shift &
00048 & , psi(irg,ntgeq,npg_l) &
00049 & , alph(irg,ntgeq,npg_l) &
00050 & , bvxd(irg,ntgeq,npg_l)*pari &
00051 & , bvyd(irg,ntgeq,npg_l)*pari &
00052 & , emd(irg,ntgeq,npg_l) &
00053 & , vep(irg,ntgeq,npg_l) &
00054 & , vepxf(irg,ntgeq,npg_l)*pari &
00055 & , vepyf(irg,ntgeq,npg_l)*pari
00056 if (count.eq.1) write(12,'(/)')
00057 end do
00058 write(12,'(/)')
00059 count = 0
00060 do irg = 0, nrg
00061 char_1 = ' '
00062 if (impt.ne.3) then
00063 if (irg.gt.irg_exin(ntgeq,npg_r).and.irg.lt.irg_exout(ntgeq,npg_r)) then
00064 char_1 = '#'
00065 count = count + 1
00066 end if
00067 end if
00068 write(12,'(a1,1p,10e20.12)') char_1, rg(irg)+work_shift &
00069 & , psi(irg,ntgeq,npg_r) &
00070 & , alph(irg,ntgeq,npg_r) &
00071 & , bvxd(irg,ntgeq,npg_r)*pari &
00072 & , bvyd(irg,ntgeq,npg_r)*pari &
00073 & , emd(irg,ntgeq,npg_r) &
00074 & , vep(irg,ntgeq,npg_r) &
00075 & , vepxf(irg,ntgeq,npg_r)*pari &
00076 & , vepyf(irg,ntgeq,npg_r)*pari
00077 if (count.eq.1) write(12,'(/)')
00078 end do
00079 close(12)
00080
00081 end subroutine printout_axis_irrot_BNS_mpt