Skip to content
Snippets Groups Projects
Commit 687bf2ac authored by Katharina Heck's avatar Katharina Heck Committed by Timo Koch
Browse files

[material][idealgas] change calculation of density, use molar density

parent ebd395cb
No related branches found
No related tags found
1 merge request!498Correct computation of molar densities (fixes small mass balances errors)
...@@ -50,7 +50,7 @@ public: ...@@ -50,7 +50,7 @@ public:
static constexpr Scalar density(Scalar avgMolarMass, static constexpr Scalar density(Scalar avgMolarMass,
Scalar temperature, Scalar temperature,
Scalar pressure) Scalar pressure)
{ return pressure*avgMolarMass/(R*temperature); } { return molarDensity(temperature,pressure)*avgMolarMass;}
/*! /*!
* \brief The pressure of the gas in \f$\mathrm{[Pa]}\f$, depending on * \brief The pressure of the gas in \f$\mathrm{[Pa]}\f$, depending on
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment