Contains the necessary functions to evaluate Magic Formula 5.2, 6.1 and 6.2 models from .tir files
Updated 12 Mar 2021

View License

MFeval (Magic Formula evaluation) has been created to provide a robust way to evaluate Magic Formul tyre models.
The toolbox contains the function with the same name (mfeval.m) used to evaluate tyre property files with the Magic Formula 5.2, 6.1 or 6.2 equations. A tyre property file (.tir) contains the magic formula parameters that define the tyre's force and moment characteristics.

Cite As

Marco Furlan (2024). MFeval (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2017b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!




Version Published Release Notes

readTIR can read files that are delimited with Line Feed (LF) or Carriage Return (CR) and Line Feed (LF)
Radius calculation for MF6.2 compatible with the C code compiler


◾ Warning in the Mx formulation if parameter sets QSX1 to QSX11 and QSX12 to QSX14 are non zero
◾ Fixed bug in the radius calculation using MF5.2
◾ Faster radius calculation for MF6.2 (secant method)
◾ Faster CPI Simulink model implementation


See in the comments


Fix small error on version number


See the comments sections or the release notes on the documentation for more information


MF-Tyre 5.2 equations have been implemented for backward compatibility


MF-Tyre 6.2 equations have been implemented. In 6.2 the loaded radius model is improved with camber dependencies. See the documentation for more information


Slip stiffness (Kxk) is now output number 30
In STI vertical damping forces only actuate if the tire is in contact with the road
In STI the Slip Angle calculation has been updated to use the transformation matrix


Road friction can be passed as input to STI and CPI interfaces
Unnecessary zero crossing detection have been disabled
Fx and Fy filters moved to reside inside Switch dynamics mode
In Mz calculation, Gyk_sub0 is now calculated after Fyo_sub0


Road position implemented in STI
Road velocity implemented in STI
Some MATLAB Function blocks have been replaced with inbuilt Simulink blocks
The switch case to select the dynamics mode in CPI is done upstream to avoid unnecessary calculations


◾ Simulink Library updated to work with variable solvers.
◾ Simulink memory blocks have been replaced with low pass filters with a pass band frequency of 15 Hz
◾ coefficientCheck inputs have been updated to be compatible with MFit


Simulink Library updated to be more robust and consistent (STI interface depends on CPI interface)
All Simulink blocks and demos are saved in MATLAB 2017b
Advance user guide completed: including a demo showing how to fit a model