### Computer simulation of gas exchange

The mathematical model of gas exchange should be rapid and precise, because the calculation of gas exchange takes a considerable proportion of total time.
In a program DIESEL-2/4t, parameters of gas in manifolds and ducts of the engine are specified by decision of systems of equations including the conservation
equation of energy, gas weight, concentration, pulse, and also equation of state written down for these elements of engine. The gas parameters  in cylinders are specified by decision of  system of conservation equation of energy, weight, concentration, and also equation of state  written down for an open thermodynamic system. In each element of engine, except for the pulse converter the heat interchange with walls is taken into account.

Calculation of lengthy fragments of gas-air part of engine

For calculation of lengthy fragments of an engine with high gradients of pressure   the equations of one-dimensional, non-steady flow are used. The used simulation method was designed by the Professor A.S. Orlin for calculation of a flow velocity in exhaust port of high-speed engines.

Equation of motion for one-dimensional, non-steady flow:

,

where: W is the gas velocity; P is the gas pressure; r is the gas density; õ is the length of the duct, t is the time.

By multiplication of both sides of this equation on dx, integration of it on a length of the duct from 0 up to lc at assumptions that dW/dt does not depend on x and W (0, t) = 0, and also taking into account the Bernoulli's equation:

we get differential equation:

where: Wo(t)  is a velocity of a steady-stated stream in the duct depending only on relation  between cylinder pressures and  manifold one in each instant:

where: Pc, Tc are the pressure and temperature in cylinder;

Pr is the exhaust manifold pressure.

At the given calculation step of time the assumption about the gas pressure and temperature in cylinder and manifolds are constants is used. The value of velocity Wo(t) at the same calculation step is a stationary value too.
Let
Wo be the value of Wo(t);

t,  the value of calculation step of time;
W
1,   the value of velocity in the end of the duct at a start of a calculation step;

WL,  the value of velocity in the end of the duct at the end of a calculation step.
A solution of the differential equation (1) in view of adopted labels is:

 Critical velocity of the outflow is .

l= WL / akp is a reduced velocity at the end of the channel. The exhaust port has not a profile of a Laval nozzle. The sudden expansions and rotational displacements take place in it. The sharp increase of losses in the duct starts already at medial values of llim = (0.65 ... 0.75). A reason of increase of losses is the formation of local zones of flow with a sound velocity. The supersonic flows in elements of a piston engine are impossible generally even at supercritical differences of pressure. Therefore if  l > llim then WL = llim akp.
The mean velocity of the flow at a small calculation step is    W = (WL + W1) / 2.

 There are temperature, pressure and density in the gas portion which has flowed out from the cylinder:

Mass and enthalpy of a portion of gas flowed out  from a duct with an effective flow section mf  during a calculation step Dt are

DG = mf  r W Dt,    I* = DG  Cp  Tc.

The calculation of gas exchange is carry out with a step of 1 crank angle deg.

Boundary conditions in front of turbine

At calculation of parameters of gas in an exhaust manifold the boundary conditions of the turbine are applied. Equations for mass and enthalpy of gas portion flowed out into a turbine are

 I*t = DGt   Cp   T*r ;                   (2)

where: P*r, T*r are stagnation pressure and temperature in inlet of turbine;
P
2  is turbine discharge pressure;
F
t  is flow section of turbine nozzles;
m  is coefficient (for the radial turbine m = 0.42, for axial one m = 0.346);
A  is empirical factor.

To obtain required value of average pressure in front of the turbine P*r it is necessary to update value of a factor A by iterations. Previously, the average turbine inlet pressure must be set directly in a list of input data or must be calculated from an equation of balance of the turbine and compressor power .

Pulse converter simulation

For calculation of mixing of flows from two manifolds in the pulse converter the equations of an ejector are used. The pressure in zone of flows mixing Pt is specified by iterations on each calculation step. Pressure Pr1*(j) and temperature Tr1*(j) in the “first” inlet of the pulse converter are specified by step by step decision of system of conservation equations for exhaust manifold. This equations system is decided together with other equations systems for the cylinder and intake manifold. The parameters in the “second” inlet of the pulse converter Pr2*(j) and Tr2*(j) are not calculate. They are specified by shift of time of the computed results of the "first" inlet. The value of shift is Dj = 360 / icyl, where icyl is a number of cylinders connected with one exhaust manifold. The velocity of gas in the mixing zone can be specified by the Bernoulli's equation for an incompressible liquid :

 where: is mean gas density.

The calculations in view of a compressibility provide practically identical results, but require the much greater the computer run time.
Resultant flow velocity and
flow rate after mixing is

Wt = (W1 + W2) / 2 ;      Gt = r Ft Wt

where:  Ft is flow section area of turbine inlet.
The way of calculation of stagnation pressure in mixing zone depends on the pulse converter design. If the losses on sudden expansion take place in the pulse converter before a turbine the pressure is

Pt* = Pt + r (W12 + W22 - Wt2) / 2 .

 Fig.1 If the pulse converter is designed in a scroll duct of a radial turbine (Fig.1) , the losses of sudden expansion are absent. In this case the stagnation pressure is Pt* = Pt + r Wt2 / 2 .

Stagnation temperature in the mixing zone is

Tt* = (Tr1* W1 + Tr2* W) / (W1 + W).

Mass of gas portion flowed out into a turbine are specified by boundary condition equation is

If çGt' - Gt ç> 0.001  Gt', the calculation of the pulse converter should be repeated with other value of Pt down to installation of mass balance.

At calculation of an exhaust manifold connected with the pulse converter the boundary conditions (2) are substituted on (3).

DGt = W1 r Dt Ft / 2 ;          It* = DGt Cp Tr1*.         (3)

Peculiarities of gas exchange simulation in the cylinder of the two-stroke engine.

The basic difficulty at the calculation of working process of the two-stroke engine is simulation of scavenging. In this period in the cylinder there is a complex interaction of two gas flows: a cold fresh charge and hot burnt gases. In mathematical model the parameters of gas during a scavenging are determined separately for both zones. At simulation, a combination of hypotheses of zones interaction  is used:
At calculation, thermal interaction between the zones is taken into account, and also assumption about instant distribution of pressure inside the cylinder is used.
At the beginning and up to the middle of a scavenging, - a hypothesis about " layer replacement " is used, i.e. the cylinder is considered to be divided into two zones by a membrane which is opaque for gas. There are zones of a fresh charge and burnt gases. In both zones the values of temperature and concentration of gases are calculated and all the parameters of gases are specified by decision of systems of equations of weight balance, energy balance and state, written down for each zone. The pressures in both zones are equal. The heat exchange between the zones is taken into account. Naturally, it is supposed, that the gas from inlet ports gets into the zone of fresh charge, and the burnt gases stream into exhaust ports (as indicated by the arrows in Fig. 2 ). At the end of the scavenging the calculation is switched over, either to a hypothesis about "complete mixing" of zones (mainly for uniflow scavenging), or to a hypothesis about "short closing" (for the loopback scavenging).

Uniflow scavenging

Loopback scavenging

 Fig. 2.

At "complete mixing", the parameters of gas in the cylinder are again accepted homogeneous, and they are calculated from summation. At "short closing" - assumption is introduced that the gas from a zone of fresh charge is directed at once to the exhaust port and the remaining burnt gases remain in the cylinder up to the end of gas exchange. This gas will get mixed up with a fresh charge already after closing of inlet and exhaust ports.

Peculiarities of gas exchange simulation in the cylinder of the four-stroke engine.

During a scavenging of the cylinder of the four-stroke engine an assumptions about "complete mixing" and instant distribution of pressure are used. The whole volume of the cylinder is a uniform thermodynamic system in which parameters of gas are determined.

Peculiarities of gas exchange simulation in petrol engines.

At calculation of gas exchange in the petrol engine, design features of its fuel supply system are taken into account:
- Carburetor system;
- System of injection into an inlet manifold;
- System of injection into the inlet port (on the valve).

Examples of  gas exchange simulation

Gas exchange phenomena in the four-stroke 6 cylinder diesel D6
(D/S=150/180 mm, rpm=1500, BMEP=9 bar)

 Notations: a - Pressure in the cylinder; b - Pressure in the exhaust manifold; c - Pressure in the inlet manifold; d - Flow section of exhaust port; e - Flow section of the inlet port; Gas velocity in the ports: f-exhaust; g - inlet

Gas exchange phenomena in the two-stroke 3 cylinder diesel 3TDF with uniflow scavenging
(D/S=120 / 2x120 mm, rpm=2600, BMEP=14 bar)

 Diagram of diesel
 Notations: a - cylinder pressure; b - exhaust manifold pressure; c - inlet manifold pressure; d - flow section area of inlet ports; e - gas flow rate through inlet ports; f - gas flow rate through exhaust ports;; g - flow section area of exhaust ports..

 Calculation of parameters of the truck diesel KamAZ 7405 at the several operating regimes. Verification of the calculated data compared to experimental ones: integral parameters, curves of heat release, curves of pressure during combustion and during gas exchange.