Hello, I have defined a C2 continuous path using piecewise functions, and I want to estimate the time a car takes to go from the beginning to the end. There are many things left out, such as weight transfer. Here is the "pseudocode" of what I tried:(adsbygoogle = window.adsbygoogle || []).push({});

deltaT is set to 0.1 seconds

input: beginning, end, deltaT

t=0

v=0

a="some acceleration i choose"

position= beginning

while "end of path not reached" do

travelleddistance=[tex]v\Delta t+0.5a\Delta t^{2}[/tex]end do

position="new position on the path, given the travelled distance"

t=[tex]t+\Delta t[/tex]

[tex]v=\min \left(\sqrt{\frac{curveradius\cdot \mu_{s}\left(mass\cdot g+downforce)}{mass}},v+a\Delta t,\left(\textrm{maxspeed given power of car, bounded by air drag}\right)\right)[/tex]

[tex]a=\min\left ( \sqrt{\textrm{formula derived from tractioncircle}},\frac{Power of car}{v\cdot mass} \right )[/tex]

output: t

A few questions:

this basic algorithm assumes the car can always decelerates from speed v to the next maximum speed, for any delta T. Any ideas on how to take deceleration limits into account?

**Physics Forums | Science Articles, Homework Help, Discussion**

Dismiss Notice

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Estimating traversal time of car on a path

Can you offer guidance or do you also need help?

Draft saved
Draft deleted

**Physics Forums | Science Articles, Homework Help, Discussion**