[Commits] [svn:einsteintoolkit] EOS_Omni/trunk/src/nuc_eos/ (Rev. 31)
knarf at cct.lsu.edu
knarf at cct.lsu.edu
Thu Dec 16 15:02:36 CST 2010
User: knarf
Date: 2010/12/16 03:02 PM
Modified:
/trunk/src/nuc_eos/
nuc_eos.F90
Log:
remove some usage of uninitialized memory. Tidy up code a bit
File Changes:
Directory: /trunk/src/nuc_eos/
==============================
File [modified]: nuc_eos.F90
Delta lines: +12 -16
===================================================================
--- trunk/src/nuc_eos/nuc_eos.F90 2010-12-06 19:47:12 UTC (rev 30)
+++ trunk/src/nuc_eos/nuc_eos.F90 2010-12-16 21:02:36 UTC (rev 31)
@@ -233,13 +233,13 @@
lr = log10(xrho)
lt = log10(xtemp)
y = xye
- xeps = xenr + energy_shift
- leps = log10(max(xeps,1.0d0))
keyerr = 0
if(keytemp.eq.0) then
!need to find temperature based on xeps
+ xeps = xenr + energy_shift
+ leps = log10(max(xeps,1.0d0))
call findtemp(lr,lt,y,leps,keyerrt,rfeps)
if(keyerrt.ne.0) then
keyerr = keyerrt
@@ -349,35 +349,31 @@
endif
endif
- lr = log10(xrho)
- lt = log10(xtemp)
- y = xye
- xeps = xenr + energy_shift
- leps = log10(max(xeps,1.0d0))
-
keyerr = 0
+ if(keytemp.gt.1) then
+ stop "eos_nuc_press does not support keytemp other than 0 and 1"
+ endif
+
+ lr = log10(xrho)
+ lt = log10(xtemp)
+ y = xye
if(keytemp.eq.0) then
!need to find temperature based on xeps
+ xeps = xenr + energy_shift
+ leps = log10(max(xeps,1.0d0))
call findtemp(lr,lt,y,leps,keyerrt,rfeps)
if(keyerrt.ne.0) then
keyerr = keyerrt
return
endif
xtemp = 10.0d0**lt
-
- elseif(keytemp.gt.1) then
- stop "eos_nuc_press does not support keytemp other than 0 and 1"
endif
-
! have temperature, proceed:
call findall_press_eps(lr,lt,y,ff)
xprs = 10.0d0**ff(1)
+ xenr = 10.0d0**ff(2) - energy_shift
- if(keytemp.eq.1) then
- xenr = 10.0d0**ff(2) - energy_shift
- endif
-
end subroutine nuc_eos_press_eps
subroutine nuc_eos_dpdr_dpde(xrho,xtemp,xye,xenr,xdpdrhoe,&
More information about the Commits
mailing list