diff options
author | rhaas <rhaas@c83d129a-5a75-4d5a-9c4d-ed3a5855bf45> | 2013-02-11 16:30:06 +0000 |
---|---|---|
committer | rhaas <rhaas@c83d129a-5a75-4d5a-9c4d-ed3a5855bf45> | 2013-02-11 16:30:06 +0000 |
commit | a2508f3d268c2abf4fab3eeb6e553508d32a0436 (patch) | |
tree | cd1ec9efe5c8e27c9f866f4a0b78d42e1c20bd0c /src/GRHydro_WENOReconstruct_drv.F90 | |
parent | b770b656fbd9926096a99da9b72dc39c44a4fcf9 (diff) |
* add option to reconstruct temperature to GRHydro
This does not yet work with the MHD part of the code,
but Philipp is going to change this.
* Improve TOVSolverHot; in particular, give functions unique
names to avoid duplicate symbols with TOVSolverC
From: Christian Ott <cott@bethe.tapir.caltech.edu>
git-svn-id: http://svn.einsteintoolkit.org/cactus/EinsteinEvolve/GRHydro/trunk@473 c83d129a-5a75-4d5a-9c4d-ed3a5855bf45
Diffstat (limited to 'src/GRHydro_WENOReconstruct_drv.F90')
-rw-r--r-- | src/GRHydro_WENOReconstruct_drv.F90 | 47 |
1 files changed, 40 insertions, 7 deletions
diff --git a/src/GRHydro_WENOReconstruct_drv.F90 b/src/GRHydro_WENOReconstruct_drv.F90 index 2c748c5..0a6374c 100644 --- a/src/GRHydro_WENOReconstruct_drv.F90 +++ b/src/GRHydro_WENOReconstruct_drv.F90 @@ -161,6 +161,14 @@ subroutine GRHydro_WENOReconstruct_drv(CCTK_ARGUMENTS) Y_e_minus(i,j,k) = 0.0d0 endif + if (evolve_temper .ne. 0) then + ! set this to cell center value to have + ! good initial guesses at interfaces + ! in case we don't reconstruct temp + tempplus(i,j,k) = temperature(i,j,k) + tempminus(i,j,k) = temperature(i,j,k) + endif + enddo enddo enddo @@ -176,13 +184,6 @@ subroutine GRHydro_WENOReconstruct_drv(CCTK_ARGUMENTS) enddo end if - if (evolve_Y_e .ne. 0) then - call tvdreconstruct(nx, ny, nz, xoffset, yoffset, zoffset, & - Y_e(:,:,:), Y_e_plus(:,:,:), & - Y_e_minus(:,:,:), & - trivial_rp, hydro_excision_mask) - endif - if (flux_direction == 1) then ! constraint transport needs to be able to average fluxes in the directions ! other that flux_direction, which in turn need the primitives on interfaces @@ -205,6 +206,16 @@ subroutine GRHydro_WENOReconstruct_drv(CCTK_ARGUMENTS) call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(1),& eps(:,j,k),epsminus(:,j,k),epsplus(:,j,k),& trivial_rp(:,j,k), hydro_excision_mask(:,j,k)) + if(evolve_Y_e.ne.0) then + call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(1),& + Y_e(:,j,k),Y_e_minus(:,j,k),Y_e_plus(:,j,k),& + trivial_rp(:,j,k), hydro_excision_mask(:,j,k)) + endif + if(evolve_temper.ne.0.and.reconstruct_temper.ne.0) then + call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(1),& + temperature(:,j,k),tempminus(:,j,k),tempplus(:,j,k),& + trivial_rp(:,j,k), hydro_excision_mask(:,j,k)) + endif if(evolve_mhd.ne.0) then call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(1),& Bvecx(:,j,k),Bvecxminus(:,j,k),Bvecxplus(:,j,k),& @@ -297,6 +308,16 @@ subroutine GRHydro_WENOReconstruct_drv(CCTK_ARGUMENTS) call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(2),& eps(j,:,k),epsminus(j,:,k),epsplus(j,:,k),& trivial_rp(j,:,k), hydro_excision_mask(j,:,k)) + if(evolve_Y_e.ne.0) then + call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(2),& + Y_e(j,:,k),Y_e_minus(j,:,k),Y_e_plus(j,:,k),& + trivial_rp(j,:,k), hydro_excision_mask(j,:,k)) + endif + if(evolve_temper.ne.0.and.reconstruct_temper.ne.0) then + call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(2),& + temperature(j,:,k),tempminus(j,:,k),tempplus(j,:,k),& + trivial_rp(j,:,k), hydro_excision_mask(j,:,k)) + endif if(evolve_mhd.ne.0) then call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(2),& Bvecx(j,:,k),Bvecxminus(j,:,k),Bvecxplus(j,:,k),& @@ -389,6 +410,16 @@ subroutine GRHydro_WENOReconstruct_drv(CCTK_ARGUMENTS) call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(3),& eps(j,k,:),epsminus(j,k,:),epsplus(j,k,:),& trivial_rp(j,k,:), hydro_excision_mask(j,k,:)) + if(evolve_Y_e.ne.0) then + call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(3),& + Y_e(j,k,:),Y_e_minus(j,k,:),Y_e_plus(j,k,:),& + trivial_rp(j,k,:), hydro_excision_mask(j,k,:)) + endif + if(evolve_temper.ne.0.and.reconstruct_temper.ne.0) then + call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(3),& + temperature(j,k,:),tempminus(j,k,:),tempplus(j,k,:),& + trivial_rp(j,k,:), hydro_excision_mask(j,k,:)) + endif if(evolve_mhd.ne.0) then call GRHydro_WENOReconstruct1d(WENO_order,cctk_lsh(3),& Bvecx(j,k,:),Bvecxminus(j,k,:),Bvecxplus(j,k,:),& @@ -464,8 +495,10 @@ subroutine GRHydro_WENOReconstruct_drv(CCTK_ARGUMENTS) end if !!$ WENO ends. + deallocate(trivial_rp) deallocate(dum,dump,dumm) + end subroutine GRHydro_WENOReconstruct_drv |