Hello everybody, welcome to my first blog post for BeamNG! My aim with this post is to introduce a project I am undertaking, applying a unique approach to testing and tuning the tire models in the game. I’m a mechanical engineer by education, and I’m being encouraged to get as technical as I want for these posts, so get ready for heavy reading!
One of the things that gives BeamNG so much potential as a vehicle simulator is that it takes a bottom-up approach to simulation. Instead of defining a car body or tire as a basic object in the game and applying some physics equations, it creates these complicated structures from networks of nodes and beams. This bottom-up approach to simulation is incredibly versatile, but it means that the subtle nature of vehicle handling is dependent on not just the core physics but also the physical tire and vehicle models created within it. To date the dev team has made improvements to the vehicle handling through a test and tune method, where improvements to physics and models are made based on driving tests. However, to truly validate the handing and find new areas to improve, one needs the ability to test individual aspects of the physics and vehicles more objectively, and compare tests to real life data. This is what I have been working towards.
My first project has been to create a tire testing machine within the game. This machine takes the tire and wheel from any of the vehicles and drives it along the ground at controlled speeds, loads, and angles. The design parallels those that tire researchers use to test real tires. In operation, the tire tester can continuously log force data from the wheel axle. One can also modify any tire or friction model parameter and see the change in tire behavior graphed in real time, independent of factors like the vehicle’s suspension geometry or chassis rigidity. With this data logged, I can then create plots that compare empirical results; in-game vs. real life, or, old tire model vs. new tire model.
My first use of this machine was to characterize the hubWheel, which is the now deprecated tire model that has been replaced in version 0.3.7.5. I spent many hours logging data, coming up with plotted curves to show some of the most important tire behaviors. I am now using it to perform tests on the new pressureWheel, using the old hubWheel data as a benchmark. Here is a short video showing the testing machine in motion:
Thank you CarlosAir for sharing your lua skills, creating more advanced controls and data logging abilities for the Tire Tester.
Before we go any further, I’d like to do a basic definition of some terms used to describe tires. If you are already familiar you can skip this part.
Slip Angle - The angle between the direction the tire faces and the direction it travels. As a tire rolls forward, elements of the tread in the contact patch can be imagined to flex and “walk” over each other, allowing the tire to also move sideways, without actually sliding. This happens when the wheel is steered in an attempt to turn. Turn hard enough, and the slip angle will increase as the tire contact patch starts to slide.
Slip Ratio – Similar to slip angle, this is a relation between the speed of the tire compared to the ground. A locked up tire skidding on the ground is a slip ratio of -1, whereas a tire spinning twice as fast as the ground has a slip ratio of +1. Parts of the tire tread can compress and expand as they touch and leave the ground, allowing the tire to travel a bit faster or slower than the ground without sliding. Apply too much power or brake and the slip ratio grows as the tire begins to slide.
Normal Force – The gravitational force holding the tire against the ground.
Lateral Force – Defined as the force developed along the wheel axis. Essentially, this is the cornering force developed when turning.
Longitudinal Force – Defined as the force developed parallel to the tire tread, perpendicular to the axle. Essentially, this is the acceleration or deceleration force caused by throttle or brake.
Cornering Stiffness – A tire’s size, construction, and air pressure determine how much slip angle is developed for a given amount of lateral force. A stiffer, wider tire, with more pressure, tends to have a greater cornering stiffness, causing less lateral movement and a more direct feeling to the steering.
Slip Stiffness – Similar to cornering stiffness, but acting longitudinally. More slip stiffness means more direct response to power or brake.
Ok, those were not very rigorous definitions, mainly just meant to give an intuitive sense. There are plenty of great resources on the internet if these were too brief. On to the tests!
Lateral (Cornering) Force Vs. Slip Angle
This is the most common test performed on tires. Data sets from this type of test are often provided to vehicle manufacturers and race teams. The shape of the curve determines the behavior of the tire (and vehicle) when performing a pure cornering manoeuvre (no throttle or brake). To do this test, I choose a speed for the machine to travel, and cycle the tire through each increment of angle from 0 to 40 degrees, recording the data as I go.
Longitudinal (Traction) Force Vs. Slip Ratio
This test determines how the tire responds to brake and engine torque loads. My tire tester has an engine that creates gobs of torque, and the gear ratios are carefully chosen to represent fixed percentages of the forward speed. All I have to do is set the data to log, start the machine moving forward and cycle up and down through the gears.
Combined Lateral and Longitudinal Forces
One of the most important aspects of a tire simulation is not just how the tire performs in the above two tests, but how the tire works with a combination of the two. After all, people usually drive using combinations of gas, brake, and steering. To accomplish this test, I set the wheel to a given slip angle and then run the transmission through the gears. Then pick the next slip angle and do the same. This test takes much longer than the other tests, but the results are very telling.
Normal Load Sensitivity
In high school physics class you might have been taught the basic friction formula, and been told that the friction coefficient is some constant independent of normal force. This is quite far from true on real tires. A tire develops proportionally less peak lateral force as its normal force increases. For example, a tire that can deliver a peak grip of 1g on a car weighing 2000lb may only be able to deliver 0.8g on a 4000lb car. Higher normal forces also deform the tire more, leading to lower cornering stiffness. This behavior is the primary reason it is important to manage weight transfer in a car! This test is pretty simple; I just change the node weight of the test carriage to see the effect on any of the above tests.
Speed sensitivity is a tricky one. Very little is said about speed sensitivity in papers and textbooks, and tires are rarely tested at high speed because the tire gets heated/destroyed too quickly. It is generally assumed for basic simulations that tires are not speed sensitive. I can run any above test at any speed within reason (things get a little shaky beyond 350km/h!) Particularly this type of test is good for finding any dips in response from the tire due to resonances, an important step in the final tweaking of the tire parameters.
With these tests I have formed a decent picture of what needs to improve in BeamNG’s tire model. In the next blog I will be using the tests and terms explained here to compare the hubWheel with the new and improved pressureWheel! For now, here is a surface plot of the old Ibishu Covet hubWheel to show as an example. I leave it as an exercise for you to infer what you can!