00001 subroutine source_ang_mom_asymp(sousf,irg)
00002 use phys_constant, only : long, pi
00003 use grid_parameter, only : nrg, ntg, npg
00004 use def_metric, only : tfkij, psi, alph, bvxd, bvyd, bvzd
00005 use coordinate_grav_r, only : hrg
00006 use trigonometry_grav_theta, only : hsinthg, hcosthg
00007 use trigonometry_grav_phi, only : hsinphig, hcosphig
00008 use def_vector_phi, only : hvec_phig
00009 implicit none
00010 real(long), pointer :: sousf(:,:)
00011 integer, intent(in) :: irg
00012 integer :: itg, ipg, ia, ib
00013 real(long) :: vphig(1:3), rna(1:3)
00014 real(long) :: psiw
00015
00016 do ipg = 1, npg
00017 do itg = 1, ntg
00018
00019 vphig(1) = hvec_phig(irg,itg,ipg,1)
00020 vphig(2) = hvec_phig(irg,itg,ipg,2)
00021 vphig(3) = hvec_phig(irg,itg,ipg,3)
00022 rna(1) = hsinthg(itg)*hcosphig(ipg)
00023 rna(2) = hsinthg(itg)*hsinphig(ipg)
00024 rna(3) = hcosphig(ipg)
00025
00026 sousf(itg,ipg) = 0.0d0
00027 do ib = 1, 3
00028 do ia = 1, 3
00029 sousf(itg,ipg) = sousf(itg,ipg) &
00030 & + tfkij(irg,itg,ipg,ia,ib)*vphig(ia)*rna(ib)
00031 end do
00032 end do
00033
00034 end do
00035 end do
00036
00037 end subroutine source_ang_mom_asymp