Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=Int32), | intent(in), | dimension(3) | :: | ind | beam_grid indices |
|
real(kind=Float64), | intent(in), | dimension(3) | :: | pos | Neutral particle position [cm] |
|
real(kind=Float64), | intent(in), | dimension(3) | :: | vn | Neutral particle velocity [cm/s] |
|
integer, | intent(in) | :: | neut_type | Neutral type |
||
real(kind=Float64), | intent(in), | dimension(nlevs) | :: | dens | Neutral density [neutrals/cm^3] |
subroutine store_neutrals(ind, pos, vn, neut_type, dens)
!Store neutrals in [[libfida:neut]] at indices `ind`
integer(Int32), dimension(3), intent(in) :: ind
!+ [[libfida:beam_grid]] indices
real(Float64), dimension(3), intent(in) :: pos
!+ Neutral particle position [cm]
real(Float64), dimension(3), intent(in) :: vn
!+ Neutral particle velocity [cm/s]
integer, intent(in) :: neut_type
!+ Neutral type
real(Float64), dimension(nlevs), intent(in) :: dens
!+ Neutral density [neutrals/cm^3]
select case (neut_type)
case (nbif_type)
call update_neutrals(neut%full, ind, vn, dens)
case (nbih_type)
call update_neutrals(neut%half, ind, vn, dens)
case (nbit_type)
call update_neutrals(neut%third, ind, vn, dens)
case (dcx_type)
call update_neutrals(neut%dcx, ind, vn, dens)
case (halo_type)
call update_neutrals(neut%halo, ind, vn, dens)
case default
if(inputs%verbose.ge.0) then
write(*,'("STORE_NEUTRALS: Unknown neutral type: ",i2)') neut_type
endif
stop
end select
end subroutine store_neutrals