Source-linked AI summary

A Comparative Study of Nonlinear MPC and Differential-Flatness-Based Control for Quadrotor Agile Flight

Sihao Sun, Angel Romero, Philipp Foehn, Elia Kaufmann, Davide Scaramuzza

arXiv:2109.01365v6cs.RO

TL;DR

Agile quadrotor trajectory tracking must handle nonlinear dynamics, aerodynamic effects, and actuation limits. This paper compares NMPC and DFBC in simulation and real-world flights, finding that NMPC performs better on dynamically infeasible trajectories while requiring substantially more computation.

  • Problem

    Accurate quadrotor trajectory tracking in cluttered environments remains challenging because agile flights combine nonlinear dynamics, aerodynamic effects, and actuation limits.

  • Method

    The paper systematically compares NMPC and DFBC through simulation and real-world experiments evaluating tracking accuracy, robustness, computational efficiency, and INDI inner-loop control.

  • Results

    NMPC outperforms DFBC by 48% in position accuracy and 62% in heading accuracy when reference trajectories are dynamically infeasible.

  • Takeaways & Limitations

    Both controllers achieve similar accuracy on dynamically feasible aggressive trajectories with INDI, while NMPC is preferable for dynamically infeasible references.

  • Takeaways & Limitations

    NMPC requires substantially more computation and may suffer numerical convergence failures under large disturbances or model errors.

Abstract

from arXiv · show

Accurate trajectory tracking control for quadrotors is essential for safe navigation in cluttered environments. However, this is challenging in agile flights due to nonlinear dynamics, complex aerodynamic effects, and actuation constraints. In this article, we empirically compare two state-of-the-art control frameworks: the nonlinear-model-predictive controller (NMPC) and the differential-flatness-based controller (DFBC), by tracking a wide variety of agile trajectories at speeds up to 20 m/s (i.e.,72 km/h). The comparisons are performed in both simulation and real-world environments to systematically evaluate both methods from the aspect of tracking accuracy, robustness, and computational efficiency. We show the superiority of NMPC in tracking dynamically infeasible trajectories, at the cost of higher computation time and risk of numerical convergence issues. For both methods, we also quantitatively study the effect of adding an inner-loop controller using the incremental nonlinear dynamic inversion (INDI) method, and the effect of adding an aerodynamic drag model. Our real-world experiments, performed in one of the world's largest motion capture systems, demonstrate more than 78% tracking error reduction of both NMPC and DFBC, indicating the necessity of using an inner-loop controller and aerodynamic drag model for agile trajectory tracking.

MULTIMEDIA MATERIAL

The paper compares NMPC and DFBC for agile quadrotor tracking in simulation and real-world flights, including dynamically feasible and infeasible trajectories up to 20 m/s and 5g. It evaluates accuracy, robustness, computational efficiency, INDI inner-loop control, and aerodynamic effects.

  • B. Contribution: The study compares predictive NMPC and non-predictive DFBC for agile trajectories, including dynamically infeasible cases where rotor-thrust limits are violated.The comparison covers simulations and real-world experiments under nonlinear dynamics, aerodynamic effects, model mismatch, latency, and disturbances.
  • B. Contribution: NMPC excels on dynamically infeasible trajectories but is more computationally demanding and more prone to numerical convergence issues under large disturbances.These trade-offs motivate comparing when each controller is preferable.
  • B. Contribution: More than 78% position tracking error reduction is obtained for both NMPC and DFBC with an INDI inner-loop controller.The study also reports that a well-selected inner loop is more crucial than simply adding aerodynamic effects.
  • A. Non-predictive Quadrotor Trajectory Tracking Control: Differential-flatness-based control derives reference attitude, angular rate, and acceleration from a time-parameterized 3D path, while feedback addresses mismatch and disturbances.Prior DFBC results included 6.6 centimeters position tracking error at 12.9 m/s and 2.1g accelerations.

B. Model Predictive Control for Quadrotor Trajectory Tracking

The paper frames NMPC as a predictive controller that solves constrained nonlinear optimization using a full quadrotor model, while contrasting its computational demands with non-predictive alternatives and modeling rotor-generated forces and torques.

  • B. Model Predictive Control for Quadrotor Trajectory Tracking: NMPC generates commands by solving a constrained finite-horizon optimal control problem in receding-horizon fashion.The cost uses multiple future reference points, and the discretized states and inputs form a nonlinear optimization problem.
  • B. Model Predictive Control for Quadrotor Trajectory Tracking: NMPC can exploit actuator constraints and nonlinear dynamics more directly than simplified linear or cascaded controllers.Cascaded designs may issue commands that are too conservative for agile flight or too aggressive for stability.
  • B. Model Predictive Control for Quadrotor Trajectory Tracking: The NMPC formulation uses a full nonlinear quadrotor model, current state estimation, reference states and inputs, motor-thrust bounds, and angular-velocity constraints.Single-rotor thrusts serve as control inputs, while G2 and G3 terms are omitted in the optimization model.
  • B. Model Predictive Control for Quadrotor Trajectory Tracking: NMPC remains substantially more computationally demanding than DFBC and may suffer numerical convergence issues when computational resources are insufficient.This motivates comparing predictive and non-predictive methods under practical platform constraints.
  • 1) Quadrotor Rigid-Body Model:: The rigid-body model represents translational and rotational motion, rotor thrust and torques, inertia, angular velocity, and torque-model uncertainty.Rotor acceleration and gyroscopic torque terms are usually neglected for controller design but are revisited for INDI angular-acceleration control.

2) Aerodynamic Drag Model:

The aerodynamic drag model captures major high-speed drag effects using body-frame velocity and parameters identified from flight data, aiming to improve tracking without excessive computation.

  • 2) Aerodynamic Drag Model:: High-speed quadrotor flight produces significant aerodynamic drag that must be modeled to improve tracking accuracy while limiting computational overhead.The paper uses a model previously shown to capture major drag effects effectively.
  • 2) Aerodynamic Drag Model:: The drag model uses body-frame velocity components and positive parameters k_d,x,y,z and k_h identified from flight data.Body-frame velocity is obtained by projecting inertial velocity through R(q)^T under a zero-wind assumption.

IV. METHODOLOGIES

The study compares NMPC and DFBC, enhancing both to account for nonlinear dynamics, aerodynamic effects, actuator limits, and rotational uncertainties. NMPC uses receding-horizon optimization, while DFBC maps flat-output derivatives to feed-forward attitude quantities.

  • Controller Comparison: Both controllers are augmented with INDI to convert rotor-thrust commands into rotor-speed commands and improve robustness to rotational model uncertainties and disturbances.This provides a common inner-loop enhancement for the comparison.
  • Nonlinear Model Predictive Controller: NMPC solves a constrained finite-time optimal control problem over discretized states and inputs in a receding-horizon fashion.The objective compares predicted states with multiple reference states across the horizon.
  • Nonlinear Model Predictive Controller: The NMPC formulation uses rotor thrusts as inputs, nonlinear quadrotor dynamics, thrust bounds, and angular-velocity constraints.Reference states and inputs come from a trajectory planner, while the current state initializes the optimization.
  • Nonlinear Model Predictive Controller: NMPC solves the full nonlinear quadrotor model rather than using a cascaded structure or linear assumptions.The implementation uses sequential quadratic programming in a real-time iteration scheme.
  • Differential-Flatness-Based Controller: DFBC exploits differential flatness to map position and heading trajectories to angular rates and angular accelerations used as feed-forward terms.The flat outputs are positions ξ and heading ψ.
  • Differential-Flatness-Based Controller: The improved DFBC replaces the geometric attitude controller with tilt-prioritized control and adds quadratic-programming-based control allocation for input constraints.These modifications are intended to address dynamically infeasible trajectories fairly relative to NMPC.

2) Reference Angular Velocity and Acceleration:

DFBC derives reference angular velocity and acceleration from differential-flatness relationships and higher-order trajectory derivatives. Current attitude, angular velocity, and thrust are used so jerk tracking remains possible despite deviations from reference quantities.

  • Reference Angular Velocity and Acceleration: Differential flatness supplies reference angular velocity and acceleration for attitude control, enabling tracking of position jerk and snap.Jerk and snap are the third- and fourth-order derivatives of position ξ.
  • Reference Angular Velocity and Acceleration: Reference angular velocity is obtained using differentiated translational dynamics with an assumed constant external aerodynamic force.The derivation then uses the reference jerk.
  • Reference Angular Velocity and Acceleration: Reference angular acceleration is derived by differentiating the thrust-direction relationship and using the reference snap.The resulting expression provides the desired angular acceleration.
  • Reference Angular Velocity and Acceleration: The controller uses current attitude, angular velocity, and collective thrust rather than their references, allowing jerk tracking despite deviations in those quantities.The reference jerk remains the trajectory quantity being followed.
  • Reference Angular Velocity and Acceleration: Because collective-thrust derivatives cannot be directly measured, the method approximates them using reference jerk.The thrust and its derivatives enter the angular-rate derivation.

3) Tilt-Prioritized Attitude Control:

The DFBC attitude controller prioritizes thrust orientation over heading and uses constrained control allocation to manage actuator saturation. High pitch-and-roll weighting protects control authority when requested trajectories exceed available motor capability.

  • Tilt-Prioritized Attitude Control: Tilt-prioritized control separates reduced-attitude errors from yaw error because heading control is substantially less effective and can cause motor saturation.Thrust orientation is independent of heading, allowing tilt to receive priority.
  • Tilt-Prioritized Attitude Control: The DFBC control diagram combines differential-flatness-based control with an INDI inner-loop controller.The diagram represents the controller architecture used for the DFBC pathway.
  • Tilt-Prioritized Attitude Control: A relatively high reduced-attitude gain compared with the yaw gain improves position tracking while preventing input saturations.The attitude law uses separate gains for reduced-attitude and yaw control.
  • Tilt-Prioritized Attitude Control: The feed-forward angular-acceleration term is theoretically motivated, but removing it had almost no effect in real-world experiments.This is an empirical qualification of the attitude-control design.
  • Quadratic-Programming-Based Control Allocation: The direct-inversion allocation can cause loss of control when input limits are ignored.Excessive collective thrust can saturate all motors and disable attitude control.
  • Quadratic-Programming-Based Control Allocation: Quadratic-programming allocation uses a positive-definite diagonal weight matrix whose entries weight thrust, pitch, roll, and yaw channels.Higher pitch-and-roll weights help prevent loss of control when saturation is unavoidable.

C. Incremental Nonlinear Dynamic Inversion

INDI is used as a shared inner-loop controller for NMPC and DFBC to address unmodeled rotational dynamics. It relies on sensor measurements and algebraic conversion to improve robustness while avoiding typical cascaded-control delay.

  • INDI Inner Loop: Unmodeled rotational dynamics contain a term that can be detrimental to overall control performance when omitted.Directly converting thrust commands to rotor speeds does not account for this term.
  • INDI Inner Loop: INDI uses instantaneous sensor measurements instead of an explicit model, providing robustness to model uncertainties and external disturbances.The method is selected as the inner loop for both NMPC and DFBC.
  • INDI Inner Loop: The proposed NMPC–INDI hybrid explicitly considers the quadrotor’s real input limits while improving robustness against rotational model uncertainties.INDI is used for both controllers to support a fair comparison.
  • INDI Inner Loop: The INDI formulation captures unmodeled rotational effects through filtered angular-acceleration measurements.Low-pass-filtered body rates and rotor speeds are synchronized using the same cutoff frequency.
  • INDI Inner Loop: The controller numerically solves for rotor-speed commands, without requiring the motor time constant in the presented formulation.The rotor-speed command is the only unknown in the relevant equation.
  • INDI Inner Loop: INDI converts high-level single-rotor thrust commands into rotor-speed commands through algebraic equations, avoiding typical cascaded-control delay.The same conversion principle is applied to both control frameworks.

V. IMPLEMENTATION DETAILS

The study implements both controllers in the Agilicious flight stack and evaluates them across simulated and real-world trajectories, including dynamically infeasible cases identified from thrust limits.

  • Implementation: Both controllers run in the open-source Agilicious flight stack, with shared quadrotor parameters used in simulation and real-world experiments.The implementation is in C++ and includes external ACADO and qpOASES libraries.
  • Simulation setup: Simulation runs flight software at 300 Hz, limits NMPC to 100 Hz, and propagates quadrotor dynamics at 500 Hz with a fourth-order Runge–Kutta integrator.Motor commands pass through a low-pass filter with a 30 ms time constant.
  • Experimental setup: The real-world system uses a 30 × 30 × 8 m3 VICON arena and runs flight software at 300 Hz on an NVIDIA Jetson TX2.State estimates fuse VICON and IMU measurements through an extended Kalman filter.
  • Reference trajectories: The trajectory suite contains 144 references spanning maximum accelerations of 10–60 m/s2, maximum velocities of 5–20 m/s, and ellipticities of 1, 2, and 5.The references include horizontal and vertical elliptical trajectories.
  • Reference trajectories: Of the generated references, 76 are feasible and 68 are infeasible because tracking them requires thrust exceeding the tested quadrotor’s maximum.Feasibility is determined using a modified NMPC without thrust limits.

B. Evaluation Criteria

Evaluation compares NMPC and DFBC using position and heading RMSE, crash rate, and robustness under model mismatch, disturbances, and estimation latency. Feasible and infeasible trajectories are assessed separately.

  • Evaluation criteria: Position and heading RMSE measure tracking precision, while crash rate measures robustness when the position constraint is violated.The study selects b = [5, 5, 5]T meters for the spatial constraint.
  • Feasible trajectories: Both methods track all 76 feasible trajectories without crashes under perfect model knowledge and state estimates.Their controller parameters are tuned to achieve similar position tracking error in this condition.
  • Feasible trajectories: 2.0 deg versus 5.8 deg: NMPC achieves lower average heading RMSE than DFBC on feasible trajectories, while position RMSE is similar.The comparison uses trajectories categorized by maximum acceleration.
  • Infeasible trajectories: 48% lower position RMSE and 62% lower heading RMSE: NMPC outperforms DFBC on 68 dynamically infeasible trajectories, especially at higher accelerations.The reported position values are 0.40 m versus 0.77 m, and heading values are 12.7 deg versus 33.4 deg.
  • Robustness study: Adding INDI improves robustness to rotational model uncertainties and disturbances, but NMPC has higher translational crash rates under uncertainty and disturbance.For a 30% mass increase, NMPC fails to converge in over 10% of flights and crashes; INDI does not improve translational disturbance rejection.
  • Robustness study: 68.0% versus 6.7%: at increasing system latency, NMPC has a much higher crash rate than DFBC.NMPC slightly outperforms DFBC when latency is below 30 ms.
  • Robustness study: NMPC is more sensitive to gain selection when estimation latency exceeds 30 ms, although reducing gains alleviates latency effects.At latency below 30 ms, the methods have identical average position RMSE in the stated ideal comparison.

F. Effect of Controller Parameters

The parameter studies show that tracking accuracy improves with stronger position or feedback gains only within a stability-constrained range, while allocation weights must prioritize tilt control for infeasible trajectories.

  • 1) Nonlinear MPC: Position tracking is most strongly affected by NMPC’s position weight Qξ; increasing it reduces position error until the controller destabilizes.The study attributes the destabilization to actuator dynamics introducing system delay.
  • 1) Nonlinear MPC: Increasing NMPC’s yaw weight Qq,z improves heading tracking while having little effect on position tracking.The parameter study normalizes both axes relative to a baseline setup.
  • 2) Differential Flatness Based Control: DFBC gains are designed so the position error behaves as a second-order system parameterized by damping ratio and natural frequency.Attitude gains are similarly designed using reduced-attitude and yaw natural frequencies.
  • 2) Differential Flatness Based Control: Higher DFBC closed-loop natural frequency produces less tracking error, but high gains become vulnerable to delay-induced instability.Tracking errors and time constants are normalized by the baseline gains.
  • 2) Differential Flatness Based Control: A well-tuned allocation weight matrix W prioritizes tilt over collective thrust and yaw, supporting lower crash rates on dynamically infeasible trajectories.An identical W makes QP allocation equivalent to direct inversion.

VII. REAL-WORLD EXPERIMENTS

Real-world experiments compare NMPC and DFBC, with and without INDI and aerodynamic drag modeling, across agile trajectories including dynamically infeasible references. NMPC is more computationally expensive but more accurate on infeasible flights.

  • Experimental design: The real-world evaluation covers aggressive trajectories from loops to FPV racing tracks, including matched 3D paths with different velocities and accelerations.The tested paths include Loop, Oscillate, Hairpin, Slant-loop, Vertical-loop, Split-S, Lemniscate, and Racing-trajectory.
  • Aerodynamic drag and INDI: Neglecting aerodynamic drag increases position tracking error by 144% for NMPC and 122% for DFBC.These comparisons are reported in the study of average position and heading RMSE.
  • Aerodynamic drag and INDI: Without INDI, NMPC position and heading RMSE increase by more than 364% and 115%, while DFBC increases by more than 705% and 492%.DFBC without INDI cannot successfully track some trajectories without crashing.
  • Controller comparison: Both INDI-augmented NMPC and DFBC significantly outperform the previously used NMPC with a PID low-level controller on a time-optimal gate trajectory.The comparison uses an offline-generated time-optimal trajectory.
  • Infeasible trajectories: NMPC achieves significantly higher tracking accuracy than DFBC on three real-world dynamically infeasible trajectories, consistent with simulation results.These trajectories exceed the tested quadrotor’s maximum thrust.
  • Infeasible trajectories: For the thrust-limited Loop C trajectory, both controllers shortcut inside the reference, while NMPC produces a more regular loop than DFBC.The reference requires collective thrust beyond the tested quadrotor’s maximum.
  • Computational efficiency: 2.7 ms versus 0.020 ms: NMPC takes substantially longer than DFBC to generate one control command, although both run onboard at frequencies of at least 100 Hz.DFBC is generally faster than 0.025 ms, while NMPC takes around 3 ms in the cited trajectory test.

VIII. DISCUSSION

NMPC and DFBC with INDI achieve similar accuracy on dynamically feasible aggressive trajectories, while NMPC performs better on dynamically infeasible references but requires substantially more computation and may face convergence issues.

  • NMPC and DFBC with INDI show similar tracking accuracy when reference trajectories are dynamically feasible.
  • At speeds up to 20 m/s, NMPC and DFBC with INDI outperform state-of-the-art NMPC with a PID inner loop on Race Track C.
  • 48% and 62%: NMPC outperforms DFBC in position and heading accuracy, respectively, on dynamically infeasible trajectories.NMPC uses future predictions and single-rotor constraints, whereas DFBC considers only one reference point.
  • 2.7 ms versus 0.020 ms: nonlinear NMPC requires around 100 times more solving time than DFBC on the tested hardware.The computational gap can make NMPC impractical for miniature aerial vehicles with limited computational budgets.
  • NMPC tracks dynamically infeasible trajectories more effectively, but its nonlinear optimization can suffer numerical convergence issues under disturbances and model mismatch.The paper reports a 10% higher crash rate for NMPC when the real mass is 30% higher than the model.
  • The study systematically compares NMPC and DFBC across tracking accuracy, robustness, computational efficiency, INDI augmentation, and aerodynamic-drag modeling.The aerodynamic drag model is found less influential than the inner-loop controller.
Loading 2109.01365v6…