Version 4 (modified by 10 years ago) ( diff ) | ,
---|
The current version of the code has changed the temperature from computational units to Kelvin or solves the energy equation instead of temperature. This note is to check the parameter and equations changes need to do to be consistent comparing the old ways of blog:bliu01092014 and blog:bliu01142014 . So the term won't show in the thermal diffusion equations.
- Equations
where T is in cgs unit or Kelvin.
In current version of AstroBEAR, we have
And same as blog:bliu01092014, we define
And so same as blog:bliu01092014, we have
In Betti's data,
and so- Scales for converting from cgs to cu ScaleFlux is the scale which converts the heat flux from cgs units to computational units in AstroBEAR. Since
The new scaleFlux is or as the temperature is in Kelvin now. While in the older version where the temperature is in c.u. scale, So scaleFlux is instead…
scaleDiff is the scale that converts the kappa1 from cgs units to computational units. Since
So- subroutine getdEdT in EOS.f90
This subroutine will return the value of dE/dT which has a unit as C.U. Energy/Kelvin
- source and stencil_fix(0) in diffusion.f90 will be modified as
source = ((ndiff-1.0)/(ndiff+1.0))*dot_product(T(0:2*nDim),stencil_fixed(0:2*nDim)) - T(0)*GetdEdT(Info%q(i,j,k,:)) stencil_fixed(0) = stencil_fixed(0) - GetdEdT(Info%q(i,j,k,:))
comparing with the old way
! source = ((ndiff-1.0)/(ndiff+1.0))*dot_product(T(0:2*nDim),stencil_fixed(0:2*nDim)) - T(0)*gamma7*Info%q(i,j,k,1) ! stencil_fixed(0) = stencil_fixed(0) - gamma7*Info%q(i,j,k,1)
So the lefthand side vector has unit of Kelvin and righthand side vector has unit of C.U.energy