00001 module grid_parameter
00002 use phys_constant, only : long
00003 use def_matter_parameter, only : emdc, pinx
00004 use def_quantities, only : restmass_sph, gravmass_sph, &
00005 & MoverR_sph, schwarz_radi_sph
00006 implicit none
00007 integer :: nrg, ntg, npg
00008 Integer :: nlg
00009 integer :: nrf, ntf, npf
00010 Integer :: nlf
00011 Integer :: nrf_deform, nrgin
00012 integer :: ntgpolp, ntgpolm, ntgeq, ntgxy, npgxzp, npgxzm, npgyzp, npgyzm
00013 integer :: ntfpolp, ntfpolm, ntfeq, ntfxy, npfxzp, npfxzm, npfyzp, npfyzm
00014 integer :: iter_max, num_sol_seq, deform_par
00015 character(2) :: indata_type, outdata_type, NS_shape, EQ_point
00016 character(1) :: chrot, chgra, chope, sw_mass_iter, sw_art_deform
00017 real(long) :: rgin, rgmid, rgout, ratio
00018 real(long) :: conv_gra, conv_den, conv_vep, conv_ini
00019 real(long) :: conv0_gra, conv0_den, conv0_vep
00020 real(long) :: eps, mass_eps
00021 integer :: nrg_1
00022 real(long) :: r_surf
00023 character(1) :: sw_L1_iter
00024 integer :: sw_sepa, sw_quant, sw_spin
00025 real(long) :: target_sepa, target_qt, target_sx, target_sy, target_sz
00026 contains
00027 subroutine read_parameter
00028 implicit none
00029 real(long) :: emdc_ini
00030 open(1,file='rnspar.dat',status='old')
00031 read(1,'(4i5)') nrg, ntg, npg, nlg
00032 read(1,'(4i5)') nrf, ntf, npf, nlf
00033 read(1,'(2i5,2(3x,a2))') nrf_deform, nrgin, NS_shape, EQ_point
00034 read(1,'(1p,3e10.3)') rgin, rgmid, rgout
00035 read(1,'(/,1i5,2(4x,a1))') iter_max, sw_mass_iter, sw_art_deform
00036 read(1,'(1p,2e10.3)') conv0_gra, conv_ini
00037 read(1,'(1p,2e10.3)') conv0_den, conv0_vep
00038 read(1,'(2(3x,a2),3x,3a1)') indata_type, outdata_type, chrot, chgra, chope
00039 read(1,'(1p,2e10.3)') eps, mass_eps
00040 read(1,'(/,2i5)') num_sol_seq, deform_par
00041 read(1,'(1p,2e14.6)') emdc_ini, pinx
00042 read(1,'(1p,2e14.6)') restmass_sph, gravmass_sph
00043 read(1,'(1p,2e14.6)') MoverR_sph, schwarz_radi_sph
00044 close(1)
00045 ratio = dble(nrf_deform)/dble(nrf)
00046 emdc = emdc_ini
00047 ntgpolp = 0; ntgpolm = ntg; ntgeq = ntg/2; ntgxy = ntg/2
00048 npgxzp = 0; npgxzm = npg/2; npgyzp = npg/4; npgyzm = 3*(npg/4)
00049 ntfpolp = 0; ntfpolm = ntf; ntfeq = ntf/2; ntfxy = ntf/2
00050 npfxzp = 0; npfxzm = npf/2; npfyzp = npf/4; npfyzm = 3*(npf/4)
00051 end subroutine read_parameter
00052
00053
00054
00055 subroutine read_parameter_cactus(dir_path)
00056 implicit none
00057 character*400, intent(in) :: dir_path
00058 real(long) :: emdc_ini
00059 open(1,file=trim(dir_path)//'/'//'rnspar.dat',status='old')
00060 read(1,'(4i5)') nrg, ntg, npg, nlg
00061 read(1,'(4i5)') nrf, ntf, npf, nlf
00062 read(1,'(2i5,2(3x,a2))') nrf_deform, nrgin, NS_shape, EQ_point
00063 read(1,'(1p,3e10.3)') rgin, rgmid, rgout
00064 read(1,'(/,1i5,2(4x,a1))') iter_max, sw_mass_iter, sw_art_deform
00065 read(1,'(1p,2e10.3)') conv0_gra, conv_ini
00066 read(1,'(1p,2e10.3)') conv0_den, conv0_vep
00067 read(1,'(2(3x,a2),3x,3a1)') indata_type, outdata_type, chrot, chgra, chope
00068 read(1,'(1p,2e10.3)') eps, mass_eps
00069 read(1,'(/,2i5)') num_sol_seq, deform_par
00070 read(1,'(1p,2e14.6)') emdc_ini, pinx
00071 read(1,'(1p,2e14.6)') restmass_sph, gravmass_sph
00072 read(1,'(1p,2e14.6)') MoverR_sph, schwarz_radi_sph
00073 close(1)
00074 ratio = dble(nrf_deform)/dble(nrf)
00075 emdc = emdc_ini
00076 ntgpolp = 0; ntgpolm = ntg; ntgeq = ntg/2; ntgxy = ntg/2
00077 npgxzp = 0; npgxzm = npg/2; npgyzp = npg/4; npgyzm = 3*(npg/4)
00078 ntfpolp = 0; ntfpolm = ntf; ntfeq = ntf/2; ntfxy = ntf/2
00079 npfxzp = 0; npfxzm = npf/2; npfyzp = npf/4; npfyzm = 3*(npf/4)
00080 end subroutine read_parameter_cactus
00081
00082 end module grid_parameter