Add array Q in the data block structure to store primitive variables.
This commit is contained in:
parent
5b2d79a0c4
commit
18b4de6458
@ -134,10 +134,16 @@ module blocks
|
||||
!
|
||||
type(block_meta), pointer :: meta
|
||||
|
||||
! an allocatable array to store all variables
|
||||
! an allocatable array to store all conserved
|
||||
! variables
|
||||
!
|
||||
real, dimension(:,:,:,:) , allocatable :: u
|
||||
|
||||
! an allocatable array to store all primitive
|
||||
! variables
|
||||
!
|
||||
real, dimension(:,:,:,:) , allocatable :: q
|
||||
|
||||
! an allocatable array to store all fluxes
|
||||
!
|
||||
real, dimension(:,:,:,:,:), allocatable :: f
|
||||
@ -1032,10 +1038,14 @@ module blocks
|
||||
nullify(pdata%next)
|
||||
nullify(pdata%meta)
|
||||
|
||||
! allocate space for the conserved variables
|
||||
! allocate space for conserved variables
|
||||
!
|
||||
allocate(pdata%u(nvars,nx,ny,nz))
|
||||
|
||||
! allocate space for primitive variables
|
||||
!
|
||||
allocate(pdata%q(nvars,nx,ny,nz))
|
||||
|
||||
! allocate space for the numerical fluxes
|
||||
!
|
||||
if (nflux .gt. 0) allocate(pdata%f(ndims,nflux,nx,ny,nz))
|
||||
|
Loading…
x
Reference in New Issue
Block a user