00001 subroutine helmholtz_solver_binary(fnc,sou,sou_exsurf,dsou_exsurf,sou_outsurf,dsou_outsurf,pot)
00002 use phys_constant, only : long
00003 use grid_parameter, only : nrg, npg, ntg
00004 use def_matter_parameter, only : ome
00005 use radial_green_fn_hrethadv
00006 use make_array_2d
00007 use make_array_3d
00008 use interface_copy_to_bsjy_and_sbsjy
00009 use interface_sourceterm_exsurf_eqm_binary
00010 use interface_sourceterm_outsurf_eqm_binary
00011 use interface_helmholtz_solver_binary_vol_int
00012 use interface_helmholtz_solver_binary_surf_int
00013 use interface_helmholtz_solver_outer_surf_int
00014 implicit none
00015 real(long), pointer :: pot(:,:,:), sou(:,:,:), fnc(:,:,:)
00016 real(long), pointer :: sou_exsurf(:,:), dsou_exsurf(:,:)
00017 real(long), pointer :: sou_outsurf(:,:), dsou_outsurf(:,:)
00018 real(long), pointer :: pot_vol(:,:,:),pot_exsurf(:,:,:),pot_outsurf(:,:,:)
00019
00020 call alloc_array3d(pot_vol,0,nrg,0,ntg,0,npg)
00021 call alloc_array3d(pot_exsurf,0,nrg,0,ntg,0,npg)
00022 call alloc_array3d(pot_outsurf,0,nrg,0,ntg,0,npg)
00023
00024 call calc_radial_green_fn_hrethadv(ome)
00025 call copy_to_bsjy_and_sbsjy(bsjy_hrha,sbsjy_hrha,sbsjyp_hrha)
00026 call helmholtz_solver_binary_vol_int(sou,pot_vol)
00027 call helmholtz_solver_binary_surf_int(sou_exsurf,dsou_exsurf,pot_exsurf)
00028 call helmholtz_solver_outer_surf_int(sou_outsurf,dsou_outsurf,pot_outsurf)
00029 pot(0:nrg,0:ntg,0:npg) = pot_vol(0:nrg,0:ntg,0:npg) &
00030 & + pot_exsurf(0:nrg,0:ntg,0:npg) &
00031 & + pot_outsurf(0:nrg,0:ntg,0:npg)
00032
00033 deallocate(pot_vol)
00034 deallocate(pot_exsurf)
00035 deallocate(pot_outsurf)
00036
00037 end subroutine helmholtz_solver_binary