Added point type for starting source.

This commit is contained in:
Paul Romano 2012-03-19 17:45:33 -04:00
parent 2a5b9cdcd5
commit 24bed26247
3 changed files with 6 additions and 2 deletions

View file

@ -321,8 +321,7 @@ module constants
! Source types
integer, parameter :: &
SRC_BOX = 1, & ! Source in a rectangular prism
SRC_CELL = 2, & ! Source in a cell
SRC_SURFACE = 3 ! Source on a surface
SRC_POINT = 2 ! Source at a single point
integer, parameter :: &
PROB_SOURCE = 1, & ! External source problem

View file

@ -140,6 +140,9 @@ contains
case ('box')
external_source % type = SRC_BOX
coeffs_reqd = 6
case ('point')
external_source % type = SRC_POINT
coeffs_reqd = 3
case default
message = "Invalid source type: " // trim(source_ % type)
call fatal_error()

View file

@ -93,6 +93,8 @@ contains
p_max = external_source % values(4:6)
r = (/ (prn(), k = 1,3) /)
source_bank(j) % xyz = p_min + r*(p_max - p_min)
case (SRC_POINT)
source_bank(j) % xyz = external_source % values
end select
! sample angle