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_ENOReconstruct_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_ENOReconstruct_drv.F90')
-rw-r--r-- | src/GRHydro_ENOReconstruct_drv.F90 | 48 |
1 files changed, 40 insertions, 8 deletions
diff --git a/src/GRHydro_ENOReconstruct_drv.F90 b/src/GRHydro_ENOReconstruct_drv.F90 index 3fb0c8f..26bbb58 100644 --- a/src/GRHydro_ENOReconstruct_drv.F90 +++ b/src/GRHydro_ENOReconstruct_drv.F90 @@ -161,6 +161,15 @@ subroutine GRHydro_ENOReconstruct_drv(CCTK_ARGUMENTS) Y_e_minus(i,j,k) = 0.0d0 endif + if (evolve_temper .ne. 0) then + ! initialize with cell-center values + ! to make sure we have safe initial + ! guesses at interfaces even if + ! temperature is not reconstructed + tempplus(i,j,k) = temperature(i,j,k) + tempminus(i,j,k) = temperature(i,j,k) + endif + enddo enddo enddo @@ -176,13 +185,6 @@ subroutine GRHydro_ENOReconstruct_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 @@ -221,6 +223,16 @@ subroutine GRHydro_ENOReconstruct_drv(CCTK_ARGUMENTS) entropy(:,j,k),entropyminus(:,j,k),entropyplus(:,j,k),& trivial_rp(:,j,k), hydro_excision_mask(:,j,k)) endif + if (evolve_Y_e.ne.0) then + call GRHydro_ENOReconstruct1d(eno_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_ENOReconstruct1d(eno_order,cctk_lsh(1),& + temperature(:,j,k),tempminus(:,j,k),tempplus(:,j,k),& + trivial_rp(:,j,k), hydro_excision_mask(:,j,k)) + endif else if (CCTK_EQUALS(recon_vars,"conservative")) then call GRHydro_ENOReconstruct1d(eno_order,cctk_lsh(1),& dens(:,j,k),densminus(:,j,k),densplus(:,j,k),& @@ -313,6 +325,16 @@ subroutine GRHydro_ENOReconstruct_drv(CCTK_ARGUMENTS) entropy(j,:,k),entropyminus(j,:,k),entropyplus(j,:,k),& trivial_rp(j,:,k), hydro_excision_mask(j,:,k)) endif + if (evolve_Y_e.ne.0) then + call GRHydro_ENOReconstruct1d(eno_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_ENOReconstruct1d(eno_order,cctk_lsh(2),& + temperature(j,:,k),tempminus(j,:,k),tempplus(j,:,k),& + trivial_rp(j,:,k), hydro_excision_mask(j,:,k)) + endif else if (CCTK_EQUALS(recon_vars,"conservative")) then call GRHydro_ENOReconstruct1d(eno_order,cctk_lsh(2),& dens(j,:,k),densminus(j,:,k),densplus(j,:,k),& @@ -401,10 +423,20 @@ subroutine GRHydro_ENOReconstruct_drv(CCTK_ARGUMENTS) trivial_rp(j,k,:), hydro_excision_mask(j,k,:)) endif if (evolve_entropy .ne. 0) then - call GRHydro_ENOReconstruct1d(eno_order,cctk_lsh(2),& + call GRHydro_ENOReconstruct1d(eno_order,cctk_lsh(3),& entropy(j,k,:),entropyminus(j,k,:),entropyplus(j,k,:),& trivial_rp(j,k,:), hydro_excision_mask(j,k,:)) endif + if (evolve_Y_e.ne.0) then + call GRHydro_ENOReconstruct1d(eno_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_ENOReconstruct1d(eno_order,cctk_lsh(3),& + temperature(j,k,:),tempminus(j,k,:),tempplus(j,k,:),& + trivial_rp(j,k,:), hydro_excision_mask(j,k,:)) + endif else if (CCTK_EQUALS(recon_vars,"conservative")) then call GRHydro_ENOReconstruct1d(eno_order,cctk_lsh(3),& dens(j,k,:),densminus(j,k,:),densplus(j,k,:),& |