# Energy Variation Within a Time Step

Let $T\left(t-\delta t\right)$ the temperature, $P\left(t-\delta t\right)$ the pressure, and $V\left(t-\delta t\right)$ the volume of the airbag at time $t-\delta t$ , and ${\text{m}}^{\left(i\right)}$ the mass of gas $i$ at time $t-\delta t$ . $T\left(t\right)$ , $P\left(t\right)$ , $V\left(t\right)$ are respectively temperature, pressure and volume of the airbag at time $t$ , and the mass of gas $i$ at time $t$ .

Using , the variation of total gas energy can be written as:(1)
$\text{Δ}E=\left[\sum _{i}\left({\text{m}}^{\text{(i)}}+\delta {m}^{\left(i\right)}{}_{\text{in}}-\delta {m}^{\left(i\right)}{}_{\text{out}}\right)\left({e}^{\left(i\right)}{}_{cold}+\underset{{T}_{cold}}{\overset{T\left(t\right)}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]-\left[\sum _{i}{\text{m}}^{\left(i\right)}\left({e}^{\left(i\right)}{}_{cold}+\underset{{T}_{cold}}{\overset{T\left(t-\delta t\right)}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]$
which can be written as: (2)
On the other hand, the basic energy equation Thermodynamical Equations, Equation 1 of the airbag and the expression of enthalpy in Thermodynamical Equations, Equation 5 gives:(3)
$\begin{array}{l}\text{Δ}E=\left[\sum _{i}\delta {m}^{\left(i\right)}{}_{in}\left({e}^{\left(i\right)}{}_{cold}+\frac{R}{{M}^{\left(i\right)}}{T}^{\left(i\right)}{}_{in}+\underset{{T}_{cold}}{\overset{{T}^{\left(i\right)}{}_{in}}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]-\\ \text{ }\text{ }\text{\hspace{0.17em}}\text{\hspace{0.17em}}\left[\sum _{i}\delta {m}^{\left(i\right)}{}_{out}\left({e}^{\left(i\right)}{}_{cold}+\frac{R}{{M}^{\left(i\right)}}{T}^{\left(i\right)}{}_{out}+\underset{{T}_{cold}}{\overset{{T}^{\left(i\right)}{}_{out}}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]-\delta W\end{array}$

Where, $\delta {\text{m}}_{\text{in}}^{\text{(i)}}$ and ${T}^{\left(i\right)}{}_{in}$ are characteristics of the inflator and are considered as input to the problem. $\delta {\text{m}}_{\text{out}}^{\text{(i)}}$ and ${T}^{\left(i\right)}{}_{out}$ can be estimated from the velocity at vent hole $u\left(t\right)$ . $\delta W$ is the variation of the external work. This estimation will be described hereafter.

It comes from Equation 1 and Equation 2:(4)
$\begin{array}{l}\sum _{i}\left({m}^{\left(i\right)}+\delta {m}^{\left(i\right)}{}_{in}-\delta {m}^{\left(i\right)}{}_{out}\right)\underset{T\left(t-\delta t\right)}{\overset{T\left(t\right)}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT=\\ \left[\sum _{i}\delta {m}_{in}^{\left(i\right)}\left(\frac{R}{{M}^{\left(i\right)}}{T}^{\left(i\right)}{}_{in}+\underset{T\left(t-\delta t\right)}{\overset{{T}_{in}^{\left(i\right)}}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]-\left[\sum _{i}\delta {m}_{out}^{\left(i\right)}\left(\frac{R}{{M}^{\left(i\right)}}{T}_{out}^{\left(i\right)}+\underset{T\left(t-\delta t\right)}{\overset{{T}_{out}^{\left(i\right)}}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]-\delta W\end{array}$
The variation of the external work can be written as:(5)
$\delta W=\frac{\left(P\left(t\right)+P\left(t-\delta t\right)\right)}{2}\left(V\left(t\right)-V\left(t-\delta t\right)\right)$
Using Thermodynamical Equations, Equation 9, the last expression can be written as:(6)
$\delta W=\frac{1}{2}\left(\frac{\left[\sum _{i}\frac{{m}^{\left(i\right)}+\delta {m}^{\left(i\right)}{}_{in}-\delta {m}^{\left(i\right)}{}_{out}}{{M}^{\left(i\right)}}\right]RT\left(t\right)}{V\left(t\right)}+\frac{\left[\sum _{i}\frac{{m}^{\left(i\right)}}{{M}^{\left(i\right)}}\right]RT\left(t-\delta t\right)}{V\left(t-\delta t\right)}\right)\left(V\left(t\right)-V\left(t-\delta t\right)\right)$
The last equation can be introduced to Equation 4:(7)
$\begin{array}{l}\left[\sum _{i}\left({m}^{\left(i\right)}+\delta {m}^{\left(i\right)}{}_{in}-\delta {m}^{\left(i\right)}{}_{out}\right)\underset{T\left(t-\delta t\right)}{\overset{T\left(t\right)}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right]+\left[\sum _{i}\frac{{m}^{\left(i\right)}+\delta {m}^{\left(i\right)}{}_{in}-\delta {m}^{\left(i\right)}{}_{out}}{{M}^{\left(i\right)}}\right]RT\left(t\right)\frac{V\left(t\right)-V\left(t-\delta t\right)}{2V\left(t\right)}\\ =\left[\sum _{i}\delta {m}^{\left(i\right)}{}_{in}\left(\frac{R}{{M}^{\left(i\right)}}{T}^{\left(i\right)}{}_{in}+\underset{T\left(t-\delta t\right)}{\overset{{T}^{\left(i\right)}{}_{in}}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]-\left[\sum _{i}\delta {m}^{\left(i\right)}{}_{out}\left(\frac{R}{{M}^{\left(i\right)}}{T}^{\left(i\right)}{}_{out}+\underset{T\left(t-\delta t\right)}{\overset{{T}^{\left(i\right)}{}_{out}}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]-\\ \text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}\left[\sum _{i}\frac{{m}^{\left(i\right)}}{{M}^{\left(i\right)}}\right]RT\left(t-\delta t\right)\frac{V\left(t\right)-V\left(t-\delta t\right)}{2V\left(t-\delta t\right)}\end{array}$
The first order approximation $\underset{T\left(t-\delta t\right)}{\overset{T\left(t\right)}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)\approx {c}_{v}{}^{\left(i\right)}\left({T}_{|t-\delta t}\right)\left(T\left(t\right)-T\left(t-\delta t\right)\right)$ for each gas, which allows rewrite Equation 7 as:(8)
$\begin{array}{l}\left[\sum _{i}\left({m}^{\left(i\right)}+\delta {m}^{\left(i\right)}{}_{in}-\delta {m}^{\left(i\right)}{}_{out}\right){c}_{v}{}^{\left(i\right)}\left({T}_{|t-\delta t}\right)\left(T\left(t\right)-T\left(t-\delta t\right)\right)\right]+\\ \left[\sum _{i}\frac{{m}^{\left(i\right)}+\delta {m}^{\left(i\right)}{}_{in}-\delta {m}^{\left(i\right)}{}_{out}}{{M}^{\left(i\right)}}\right]RT\left(t\right)\frac{V\left(t\right)-V\left(t-\delta t\right)}{2V\left(t\right)}\\ =\left[\sum _{i}\delta {m}^{\left(i\right)}{}_{in}\left(\frac{R}{{M}^{\left(i\right)}}{T}^{\left(i\right)}{}_{in}+\underset{T\left(t-\delta t\right)}{\overset{{T}^{\left(i\right)}{}_{in}}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]-\left[\sum _{i}\delta {m}^{\left(i\right)}{}_{out}\left(\frac{R}{{M}^{\left(i\right)}}{T}_{out}+\underset{T\left(t-\delta t\right)}{\overset{{T}^{\left(i\right)}{}_{out}}{\int }}{c}_{v}{}^{\left(i\right)}\left(T\right)dT\right)\right]-\\ \text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}\left[\sum _{i}\frac{{m}^{\left(i\right)}}{{M}^{\left(i\right)}}\right]RT\left(t-\delta t\right)\frac{V\left(t\right)-V\left(t-\delta t\right)}{2V\left(t-\delta t\right)}\end{array}$

Which allows to determine the actual temperature $T\left(t\right)$ . The actual pressure then computed from the equation of perfect gas (Thermodynamical Equations, Equation 9).