Car model/computational error caused when gear changes
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hi all,
I'm creating a model of a car with automatic gear changes when certain speeds are met, and is driven by a desired speed using the longitudinal driver block. This is done using a chart to output the gear with the car speed (vspd) feeding into the input.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/345150/image.png)
For some reason when second gear is reached there is a spike increase in acceleration from ~2m/s2 to ~13*10^6m/s2 for a very brief amount of time. This causes a large increase in speed over a very small interval, therefore the car cycles through the gears extremely quickly. I can only imagine this is some kind of computational or solver error but can't find anything on the forums.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/345153/image.png)
The model and required mat files are attached.
Thanks in advance!
0 Kommentare
Antworten (0)
Siehe auch
Kategorien
Mehr zu Gears finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!