mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 21:55:41 -04:00
Added point type for starting source.
This commit is contained in:
parent
2a5b9cdcd5
commit
24bed26247
3 changed files with 6 additions and 2 deletions
|
|
@ -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
|
||||
|
|
|
|||
|
|
@ -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()
|
||||
|
|
|
|||
|
|
@ -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
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue