00001 subroutine calc_physq_center_peos_grid
00002 use grid_parameter, only : nrf, ntf, npf
00003 use def_matter, only : emd
00004 use def_quantities, only : rho_c, pre_c, epsi_c, q_c, &
00005 & rho_max, pre_max, epsi_max, q_max
00006 implicit none
00007 real(8) :: hh, emdmax=-1.0d0
00008 integer :: irf,itf,ipf, irfmax, itfmax, ipfmax
00009
00010 q_c = emd(0,0,0)
00011 call peos_q2hprho(q_c, hh, pre_c, rho_c, epsi_c)
00012 write(6,'(a6,1p,e23.15,a21,i3,a1,i3,a1,i3,a1)') "q_c =", q_c," at (irf,itf,ipf)=(", &
00013 & 0, ",", 0, ",", 0,")"
00014
00015 q_max = 0.0d0
00016 do irf=0, nrf
00017 do itf=0, ntf
00018 do ipf=0, npf
00019 if ( emd(irf,itf,ipf) > q_max ) then
00020 irfmax = irf
00021 itfmax = itf
00022 ipfmax = ipf
00023 q_max = emd(irf,itf,ipf)
00024 end if
00025 end do
00026 end do
00027 end do
00028
00029 write(6,'(a6,1p,e23.15,a21,i3,a1,i3,a1,i3,a1)') "q_max=", q_max," at (irf,itf,ipf)=(", &
00030 & irfmax, ",", itfmax, ",", ipfmax,")"
00031
00032 call peos_q2hprho(q_max, hh, pre_max, rho_max, epsi_max)
00033
00034 end subroutine calc_physq_center_peos_grid