calc_ToverW.f90

Go to the documentation of this file.
00001 subroutine calc_ToverW
00002   use phys_constant, only  : long, pi
00003   use grid_parameter, only : nrg, ntg, npg, nrf, ntf, npf
00004   use def_matter_parameter, only : ome, radi
00005   use def_quantities
00006   use def_quantities_derived, only : omega
00007   use make_array_3d
00008   use interface_source_mp_minus_madm
00009   use interface_vol_int_grav
00010   use interface_vol_int_fluid
00011   implicit none
00012   real(long) :: fac2pi
00013   real(long) :: volg, volf
00014   real(long), pointer :: soug(:,:,:), souf(:,:,:)
00015 !
00016   call alloc_array3d(soug, 0, nrg, 0, ntg, 0, npg)
00017   call alloc_array3d(souf, 0, nrf, 0, ntf, 0, npf)
00018 !
00019   omega = ome/radi
00020   T_kinene = 0.5d0*omega*angmom
00021 !!  W_gravene = propermass + T_kinene - admmass
00022   call source_mp_minus_madm(soug,souf)
00023   call vol_int_grav(soug,volg)
00024   call vol_int_fluid(souf,volf)
00025 !
00026   fac2pi = 0.5d0/pi
00027   W_gravene = fac2pi*(radi*volg + radi**3*volf) + T_kinene
00028 !
00029   ToverW = T_kinene/dabs(W_gravene)
00030   I_inertia = angmom/omega
00031 !
00032   deallocate(soug)
00033   deallocate(souf)
00034 end subroutine calc_ToverW

Generated on 27 Oct 2011 for Cocal by  doxygen 1.6.1