Nicholas Byrum · ME 1600

Vehicle Performance Analysis in Python

PythonNumPyMatplotlibExcel I/OVehicle DynamicsCurve Fitting
Free-body diagram of a vehicle on an incline
The free-body model of the vehicle on a grade — the basis for the static and dynamic axle-load calculations.

Goal

Develop a modular Python program to analyze vehicle performance at wide-open throttle by modeling engine output, drivetrain behavior, road load, acceleration, and axle loads across multiple gear ratios using experimental dynamometer data.

Challenges

The main challenge was connecting multiple mechanical systems—engine torque curves, transmission and final drive ratios, aerodynamic drag, rolling resistance, and axle load transfer—into one working computational model. Another challenge was building a program that could reliably import and validate Excel data, fit real dynamometer data, handle out-of-range engine speeds, and organize repeated analyses into clear outputs.

Solution & Results

I developed a modular Python program that imports vehicle parameters, gear ratios, and dynamometer data from Excel files, validates the inputs, and performs wide-open-throttle vehicle performance calculations across all gears.

Python code: menu-driven car selection and Excel workbook loading
Menu-driven car selection and Excel loading, with input validation.
Python code: importing gear ratios, parameters, and dyno data and computing speed and power
Pulling gear ratios, parameters, and dyno data, then computing engine speed and power per gear.

Using polynomial curve fitting of experimental dyno data, the program estimated engine torque, engine speed, traction force, road load, power output, acceleration, and static and dynamic axle loads.

Python code: horsepower, axle-load transfer, and acceleration equations plus plotting
Core equations — horsepower, axle-load transfer, and acceleration.
Dynamometer plot: measured torque and horsepower vs engine speed with fitted curves
Fitted dynamometer data — torque and horsepower vs engine speed.
Three plots: front axle load vs wheel radius, acceleration vs weight, and rpm vs speed across gears
Performance sweeps across gears: axle load vs wheel radius, acceleration vs weight, and rpm vs speed.

Results were exported into multi-sheet Excel files for repeated analyses, with out-of-range engine speeds automatically flagged. I also created dynamometer graphs for the Corvette, Honda Civic, Mustang, and Impala to compare torque and power behavior across different vehicles.

This project strengthened my experience in vehicle dynamics, numerical modeling, data validation, and translating mechanical engineering theory into a practical computational tool.