First Place Solution in Spring 2024 Simulation Racing Series
Written by Mark Menaker, on behalf of his team from University High School.
GitHub: https://github.com/MightyMark3/Uni1_ROAR_Spring24
Table of Contents
Introduction
This solution was mostly based on Mark’s last solution (at https://roar.berkeley.edu/first-place-solution-in-fall-2023-simulation-racing-series/), which in turn was based on the second place solution in Summer 2023 (https://roar.berkeley.edu/second-place-solution-in-summer-2023-simulation-racing-series/).
For details on the general workings of the solution, please see those reports.
Modifications from Fall 2023 Winning Solution
The winning solution from Fall 2023 divided the track into 10 equal-length sections for timing
purposes, but sometimes, when the car needed to be slower only in certain areas, the friction
coefficient (which was a rough estimate to begin with) was lowered in the corresponding
sections. However, this was inefficient, as it was still possible to be fast in the rest of the
sections that were detuned, and certain areas of the track may have been able to handle more
speed, but were limited by the friction coefficient that would work for the whole section.
To address this, we divided the track into 13 sections by plotting the waypoints in desmos and
then finding areas where the geometry of the track appeared constant. For instance, we would
separate a sharp turn and a wide turn so the friction coefficient in one would not make the car
too slow in the other. We ended up with these boundaries as the ends of each section, starting
from section 0, which ended at point 198, and ending with section 12, which ended at point
2770:
self.section_indeces = [198, 438, 547, 691, 803, 884, 1287, 1508, 1854, 1968, 2264, 2592,
2770]
The friction coefficients were then tuned by raising them until the car crashed, and when a
successful one was found, it was tested multiple times to ensure consistency.
Racing Lines
This was the first time we generated new waypoints to create a smoother line. We were interested in this because around the waypoint at index 1965, there was a spot where two curves in the original waypoints would not line up correctly, often causing the car to veer right and crash. Removing or replacing a few points did not work, so we eventually created 227 new
waypoints that followed an Euler spiral using Python in Google Colab, and got it to work using trial and error. This saved about 0.5 seconds per lap in the section. However, due to the time-consuming nature of this task, we only attempted it in one other spot, at the end of the lap.
In the future, I would like to automate this process so it can be applied to the rest of the track.
Conclusion
A big thank you to Dr. Allen Yang, Mr. Huo Chao Kuan, and your team of experts for all the effort
put into running the competition! As ROAR Ambassador, I have enjoyed the opportunity to bring
ROAR to my school. Finally, I would like to thank my enthusiastic teammates: Ajay Sathish
Preetha, Aryan Mukherjee, Radin Khosraviani, and James Zhang!