0D Single-Zone Model of a 4-Stroke SI Engine
A zero-dimensional, single-zone model of a spark-ignition engine in MATLAB, packaged as an interactive app. It computes piston kinematics, heat release, in-cylinder pressure and temperature, and indicated and brake performance, using a Toyota 1NZ-FE as the baseline.
- MATLAB
- App Designer
- Thermodynamics
- Wiebe
- Woschni
- Lotus Engine Simulation

- IMEP
- 12.53 bar
- Thermal efficiency
- 33.3 %
- Brake power per cylinder
- 10 kW
- Brake torque per cylinder
- 32 N·m
Baseline operating point: Toyota 1NZ-FE at 3000 RPM.
Overview
The model treats the combustion chamber as one uniform body of gas with a changing volume and a heat input. It solves the first law of thermodynamics over the closed-valve part of the cycle, from intake valve closing to exhaust valve opening.
Piston motion comes from the slider-crank geometry, heat release from a Wiebe function, wall heat loss from the Woschni correlation, and brake performance from an empirical friction model. I wrapped it all in a MATLAB App Designer app, so the parameters can be changed and each result viewed in its own tab.
- 01
Physics-based sub-models
Slider-crank geometry, Wiebe combustion, Woschni heat transfer and an empirical friction model.
- 02
Interactive app
Engine geometry, operating point, combustion and heat transfer inputs can be edited, and every result has its own tab.
- 03
Real engine baseline
A Toyota 1NZ-FE, a 1.5 L inline-4 gasoline engine, is the reference case.
How the model works
- 01
Geometry
The slider-crank gives the cylinder volume and the piston velocity at every crank angle.
- 02
Initial state
Pressure and temperature at intake valve closing come from the intake conditions, and the ideal gas law gives the trapped mass.
- 03
Heat release and loss
A Wiebe function releases the fuel energy while the Woschni correlation removes heat through the walls.
- 04
Integrate
Explicit Euler steps march the pressure and temperature forward. IMEP comes from integrating P dV, and friction takes it down to brake values.
Baseline setup
- Engine
- Toyota 1NZ-FE, 1.497 L inline-4
- Bore and stroke
- 75.0 mm and 84.7 mm
- Compression ratio
- 10.5
- Valve timing
- IVC at 200°, EVO at 500° crank angle
- Combustion
- Wiebe, start 350°, 40° duration
- Heat transfer
- Woschni, wall at 400 K
- Integration
- Explicit Euler, 0.5° step
More results at 3000 RPM
- Indicated work
- 468.9 J per cylinder
- FMEP
- 1.80 bar
- BMEP
- 10.73 bar
- Piston speed
- 8.47 m/s mean, 13.90 m/s peak
- Trapped mass
- 0.47 g per cylinder
Limits and next steps
- 01
Uncalibrated baseline
The Woschni coefficient was set to 130 to tune the heat rejection, and has not been calibrated against measured data.
- 02
Closed valves only
The cycle is solved between IVC and EVO, so gas exchange is not modeled. A 1D gas-exchange model would capture volumetric efficiency changes.
- 03
Dynamometer data
Measured engine data would let the heat transfer coefficient be calibrated precisely.