ME 200 – Thermodynamics I – Spring 2020

Homework 20: Transient Open Systems

Piston-cylinder device

Given:

A piston-cylinder device intially contains $0.6 kg$ in a $0.1 m^3$ volume at an absolute pressure of $10 bar$. Steam at $40 bar$ and $500°C$ is supplied through a valve. The steam flows into the device until the volume reaches $0.2 m^3$ and the temperature is $240°C$. Pressure in the cylinder is constant.

In [18]:
#Given Input:
P = 1000                 # pressure inside the cylinder [kPa]
m_1 = 0.6                # initial mass of water inside the cylinder [kg]
V_1 = 0.1                # initial volume inside cylinder [m^3]
P_in = 4000              # pressure of steam supplied from the reservoir [kPa]
T_in = 500 + 273.15      # temperature of the steam supplied from the reservoir [K]
T_2 = 240 + 273.15       # final temperature inside of the cylinder [K]
V_2 = 0.2                # final volume inside cylinder [m^3]

Find:

A) Calculate the final mass inside of the piston cylinder system and the mass added to the system

B) Find the work during the process, in kJ

C) Determine the heat transfer during the process, in kJ

System Diagram:

Assumptions:

1) quasi-equilibrium process, 2) one-dimensional uniform flow at the inlet, 3) negligible changes in potential and kinetic energy

Basic Equations:

$$\dfrac{dm}{dt}=\Sigma \dot m_{in}-\Sigma \dot m_{out}$$$$\dfrac{dE}{dt} = \dot Q- \dot W + \displaystyle\sum_{in} \dot m_{in} (h+ke+pe)_{in}-\displaystyle\sum_{out} \dot m_{out}(h+ke+pe)_{out}$$$$z_{mix}=xz_g+(1-x)z_f$$$$W_{boundary}=\int PdV$$

Solution:

Part A)

First we consider conservation of mass applied to the steam in the cylinder for this single inlet system.

$$\dfrac{dm}{dt} = \dot m_{in}$$

Rearranging and integrating this differential equation gives

$$m_{in} = \int\limits_{t_1}^{t_2}{\dot m_{in}dt} = \int\limits_{m_1}^{m_2}{dm} = m_2 - m_1$$

The initial mass ($m_1$) is given whereas the final mass can be determined from the final specific volume.

$$m_2=\dfrac{V_2}{v_2}$$

State 2 is a superheated vapor tables at 240°C and 10 bar.

In [19]:
from CoolProp.CoolProp import PropsSI

v_2 = 1./PropsSI('D','T',T_2,'P',P*1000,'Water')   # specific volume of the superheated water vapor at state 2 [m^3/kg]

m_2 = V_2/v_2
m_in = m_2 - m_1

print('m_2 = ',round(m_2,3),'kg')
print('m_in = ',round(m_in,3),'kg')
m_2 =  0.879 kg
m_in =  0.279 kg

Part B)

This is a constant pressure expansion process such that the boundary work is

$$W_{12}=\int PdV = P(V_2-V_1)$$
In [23]:
W_12 = P*(V_2-V_1)  #boundary work for process 1 to 2 [kJ]

print('W_12 = ',round(W_12,3),'kJ')
W_12 =  100.0 kJ

Part C)

Now consider conservation of energy applied to the steam in the cylinder in order to determine the heat transfer. This system has a single inlet with negligible changes in kinetic and potential energy, so that

$$\dfrac{dU}{dt} = \dot Q - \dot W + \dot m_{in}h_{in}$$

The inlet steam condition does not change with time. Thus, the energy balance can be rearranged and integrated to give

$$U_2-U_1 = \int\limits_{U_1}^{U_2}{dU} = \int\limits_{t_1}^{t_2}{\dot Qdt}+\int\limits_{t_1}^{t_2}{\dot QWdt}+h_{in}\int\limits_{t_1}^{t_2}{\dot m_{in}dt}$$

or

$$m_2u_2-m_1u_1 = Q_{12} - W_{12} + m_{in}h_{in}$$

Then, the heat transfer can be determined in terms of the states and work as

$$Q_{12} = W_{12} + m_2u_2 - m_1u_1 - m_{in}h_{in})$$

Both the inlet and final condition of the steam are superheated vapor and found in the superheated vapor table for steam. In order to determine the condition at the initial state, we need to determine the initial specific volume from the known mass and volume and compare it to the saturated liquid and vapor specific volumes at the initial pressure.

In [21]:
v_1 = V_1/m_1
v_f_1 = 1./PropsSI('D','P',P*1000,'Q',0.0,'Water')  # specific volume of the saturated water liquid state 1 [m^3/kg]
v_g_1 = 1./PropsSI('D','P',P*1000,'Q',1.0,'Water')  # specific volume of the saturated water vapor state 1 [m^3/kg]

print('v_1 = ',round(v_1,3),'m^3/kg')
print('v_f_1 = ',round(v_f_1,5),'m^3/kg')
print('v_g_1 = ',round(v_g_1,3),'m^3/kg')
v_1 =  0.167 m^3/kg
v_f_1 =  0.00113 m^3/kg
v_g_1 =  0.194 m^3/kg

Since $v_f(10 bar) < v_1 < v_g(10 bar)$, then state 1 is a SLVM and the quality and internal energy can be determined as

$$x_1=\dfrac{v_1-v_f}{v_g-v_f}$$$$u_1=x_1(u_g-u_f)+u_f$$

The heat transfer is determined in the following code block.

In [22]:
x_1 = (v_1 - v_f_1)/(v_g_1 - v_f_1)
u_f_1 = PropsSI('U','P',P*1000,'Q',0.0,'Water')/1000.  # specific volume of the saturated water liquid state 1 [m^3/kg]
u_g_1 = PropsSI('U','P',P*1000,'Q',1.0,'Water')/1000.  # specific volume of the saturated water vapor state 1 [m^3/kg]
u_1 = u_f_1 + x_1*(u_g_1-u_f_1)

u_2 = PropsSI('U','P',P*1000,'T',T_2,'Water')/1000.
h_in = PropsSI('H','P',P_in*1000,'T',T_in,'Water')/1000.

Q_12 = m_2*u_2 - m_1*u_1 + W_12 - m_in*h_in

print('Q_12 = ',round(Q_12,0),'kJ')
Q_12 =  113.0 kJ