Hacker News new | ask | show | jobs
by coderenegade 1025 days ago
Numerical simulation of aircraft is pretty straightforward. The hard part is going from the inertial frame into the aircraft's frame of reference, and back again. Once that part is down, the main procedure is to find the gravity vector in the body frame, calculate thrust, lift and drag vectors in the body frame, calculate any torques, sum everything, and then convert back into the inertial frame to do the numerical integration step. From memory, torques are the hardest part, since you need to work with either the time derivative of the quaternion, or the time derivative of the rotation matrix. But if you stick to standard coordinate frame conventions, it's just applying a formula.

The only difference between fixed wing and multirotors is the different models for forces in the body frame. A fixed wing aircraft would use an aerodynamic model of whatever complexity you like, and a model for the prop. A multirotor would use multiple prop models, and a drag model for the body. Most models for these things are pretty well defined, but you can choose just about anything that "fits" so long as you can justify it. And you can use the same basic setup for any aircraft (and indeed any robot) with a bit of forethought. The data part is mostly specifying things like, say, damping coefficients that you would then want to measure.

The dynamics are not the difficult part of simulating aircraft for RL, it's actually the rest of the environment. E.g. navigation tasks require you to build a navigable environment around your physics model, and specify things like reward functions.