# Pneumatic Cylinder Discharge Equations

1. Nov 27, 2013

### QQ2013

Hi all,

First post here and I hope that somebody can help.

I'm using Simulink/Simscape to model discharge of gas from a constant volume, pneumatic, pressurised cylinder. No heat exchange with surroundings yet. I have got the equations matching the stock models from AMESim and Simscape for ideal gas discharge, but the aim is to model real gas discharge. Currently I'm keeping it simple and using Van der Waals equations.

The required function is required to calculate the following:
INPUT
mass flow dm
all state variables m, p, V, T etc.

OUTPUT
pressure change dp
temp change dT

It will then integrate and iterate.

CURRENT ATTEMPT
I need two equations to solve for two variables. Currently these are:
1) Equation of State (Ideal gas OR Van der Waals)
pV = nRT => V*dp = R(T*dn + n*dT) ​
(or VdW equivalent) ​

2) Change of Internal Energy
du = Cv*dT + [T(dp/dT) - p]dv ​
(u, v are specific U, V; derivative is partial wrt v) ​

= p*V*dm/m^2 ​

(from du = p*A*dx)​

These equations work for ideal gas but not quite for real. I can provide graphs if necessary. Can anybody suggest why there's a discrepancy? Have I assumed something which isn't quite true? Or is what I'm comparing it to incorrect (AMESim)?

Thanks,
QQ

Last edited: Nov 27, 2013
2. Dec 3, 2013

### serbring

Up for you. I'm very interested in this topic. :)