mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 13:45:36 -04:00
moved where source is allocated
This commit is contained in:
parent
3bf1d5c76a
commit
1e7ea6dbad
1 changed files with 4 additions and 3 deletions
|
|
@ -60,6 +60,7 @@ contains
|
|||
|
||||
! execute snes solver
|
||||
call cmfd_snes_execute()
|
||||
! call cmfd_slepc_execute()
|
||||
|
||||
! only run if master process
|
||||
if (master) call timer_stop(time_cmfd)
|
||||
|
|
@ -244,6 +245,9 @@ contains
|
|||
nz = cmfd%indices(3)
|
||||
ng = cmfd%indices(4)
|
||||
|
||||
! allocate cmfd source if not already allocated and allocate buffer
|
||||
if (.not. allocated(cmfd%source)) allocate(cmfd%source(ng,nx,ny,nz))
|
||||
|
||||
! reset cmfd source to 0
|
||||
cmfd%source = 0.0_8
|
||||
|
||||
|
|
@ -316,9 +320,6 @@ contains
|
|||
|
||||
end if
|
||||
|
||||
! allocate cmfd source if not already allocated and allocate buffer
|
||||
if (.not. allocated(cmfd%source)) allocate(cmfd%source(ng,nx,ny,nz))
|
||||
|
||||
! broadcast full source to all procs
|
||||
call MPI_BCAST(cmfd%source,ng*nx*ny*nz,MPI_REAL8,0,MPI_COMM_WORLD,mpi_err)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue