Skip to content

Apply aerodynamic drag opposite relative airflow - #16

Merged
rhorvath02 merged 2 commits into
mainfrom
fix/aero-force-direction
Aug 7, 2026
Merged

Apply aerodynamic drag opposite relative airflow#16
rhorvath02 merged 2 commits into
mainfrom
fix/aero-force-direction

Conversation

@rhorvath02

@rhorvath02 rhorvath02 commented Aug 6, 2026

Copy link
Copy Markdown
Member

Finding

CFDAeroMap always applied drag along negative body X. That is wrong for reverse travel, a following wind faster than the vehicle, or crosswind: drag must oppose the vehicle-relative airflow vector.

Fix

Normalize the body-frame relative-air velocity and apply the positive tabulated drag magnitude opposite that direction. Downforce and calibrated moments remain on their existing body axes; documentation calls out that large flow angles still extrapolate forward-flow CFD tables.

Validation

  • Reverse travel and following-wind cases both produced +13 N body-X drag.
  • A 45-degree crosswind case produced 26 N drag with components {-18.3848, +18.3848} N and retained -260 N body-Z downforce.
  • Drag power was negative for reverse travel, following wind, and crosswind; zero relative airflow produced exactly zero force.
  • The directional aero model matched all 147/147 initialization-baseline values.
  • Current-main VehicleSim matched all 1018/1018 initialization-baseline values.
  • A full VehicleSim run initialized without homotopy, terminated normally on the QSS plateau at 6.098631 s, retained only finite outputs, and kept minimum tire load positive at 182.83 N.
  • Ruff, Modelica lint, Python tests, and the full OpenModelica translation sweep passed locally.

@rhorvath02
rhorvath02 force-pushed the fix/aero-force-direction branch from d9878fb to 528d2c7 Compare August 6, 2026 01:08
@rhorvath02
rhorvath02 merged commit abf6c3f into main Aug 7, 2026
2 checks passed
@rhorvath02
rhorvath02 deleted the fix/aero-force-direction branch August 7, 2026 04:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant