Enhanced Active Safety Through Integrated Autonomous Drifting and Direct Yaw Moment Control via Nonlinear Model Predictive Control

The introduction of active safety systems and advanced driver assistance systems has enhanced the control authority over the vehicle dynamics through specialized actuators, enabling, for instance, independent wheel torque control. During emergency situations, these systems step in to aid the driver by limiting vehicle response to a stable and controllable range of low longitudinal tire slips and slip angles. This approach makes vehicle behavior predictable and manageable for the average human driver; however, it is conservative in case of driving automation. In fact, past research has shown that exceeding the operational boundaries of conventional active safety systems enables trajectories that are otherwise unattainable. This paper presents a nonlinear model predictive controller (NMPC) for path tracking (PT), which integrates steering, front-to-total longitudinal tire force distribution, and direct yaw moment actuation, and can operate beyond the limit of handling, e.g., to induce drift, if this is beneficial to PT. Simulation results of emergency conditions in an intersection scenario highlight that the proposed solution provides significant safety improvements, when compared to the concurrent operation of PT algorithms and the current generation of vehicle stability controllers.


Enhanced Active Safety Through Integrated Autonomous Drifting and Direct Yaw Moment Control via Nonlinear Model Predictive Control
Pietro Stano , Davide Tavernini , Umberto Montanaro , Manuela Tufo , Giovanni Fiengo , Luigi Novella, and Aldo Sorniotti , Member, IEEE Abstract-The introduction of active safety systems and advanced driver assistance systems has enhanced the control authority over the vehicle dynamics through specialized actuators, enabling, for instance, independent wheel torque control.During emergency situations, these systems step in to aid the driver by limiting vehicle response to a stable and controllable range of low longitudinal tire slips and slip angles.This approach makes vehicle behavior predictable and manageable for the average human driver; however, it is conservative in case of driving automation.In fact, past research has shown that exceeding the operational boundaries of conventional active safety systems enables trajectories that are otherwise unattainable.This paper presents a nonlinear model predictive controller (NMPC) for path tracking (PT), which integrates steering, front-to-total longitudinal tire force distribution, and direct yaw moment actuation, and can operate beyond the limit of handling, e.g., to induce drift, if this is beneficial to PT. Simulation results of emergency conditions in an intersection scenario highlight that the proposed solution provides significant safety improvements, when compared to the concurrent operation of PT algorithms and the current generation of vehicle stability controllers.

I. LITERATURE REVIEW
I N 2018, the global road death toll amounted to 1.35 million per year, with road traffic injuries being the leading cause of fatalities for people aged from 5 to 29 years old, according to the World Health Organization [1].In 2017, ∼10% of road accidents on the U.S. roads had fatal outcomes, and 94% of car crashes were estimated to be provoked by human errors, while vehicle component failure or degradation, environmental factors, and other unknown reasons were each responsible only for 2% of crashes [2].In this context, automated vehicles (AVs) have the potential to drastically reduce the number of road accidents and casualties, by replacing humans with sophisticated control systems.This perspective has led several governments and organizations to set the ambitious target of reaching zero road fatalities by 2050 [3].
Over the last few decades, significant advancements in vehicle safety have been achieved thanks to the introduction of active safety systems and advanced driver assistance systems (ADAS), such as anti-lock braking systems (ABS), vehicle stability controllers (VSC), and lane keeping assist systems.State-of-the-art VSCs intervene during emergency maneuvering by restricting the response of the vehicle within a stable regime of low wheel slip and vehicle sideslip angle, i.e., operating conditions that are predictable and easily controllable by the average human driver.However, this proposition is conservative in the context of automated vehicles, which could become more effective in avoiding accidents when operating outside the envelope enforced by current chassis controllers.For example, the implementation of path tracking (PT) controllers capable of imitating race driving techniques (e.g., trail-braking, pendulum turning, hand brake cornering, and power oversteer) could bring enhanced maneuverability, and enable trajectories that cannot be achieved through the slip angle limitations of conventional VSCs [4], [5].Nevertheless, it is expected that the first generation of automated vehicles will be characterized by PT control implemented through steering angle actuation, and conventional VSCs [6], [7], [8].The recent survey in [9] provides an overview of PT controllers for autonomous racing, a few of them capable of inducing drifting; however, they do not directly target active safety enhancements.Model predictive control (MPC) is well-suited for PT at the limit of handling [10], see the autonomous drifting examples in [11], [12], [13], [14], [15], [16], [17], [18], [19].In these MPCs, the lateral dynamics control through the steering angle is combined with different forms of longitudinal dynamics control.References [20] and [21] use a hierarchical architecture, including: i) a high-level controller, based on the combination of proportional integral derivative (PID) control and nonlinear maps or neural networks, which generate steady-state equilibrium states and feedforward inputs; and ii) a low-level MPC that corrects the inputs from i) to drive the vehicle towards the steady-state drift equilibrium.In [22], the control approach consists of: i) a pure-pursuit (PP) algorithm for steering control; and ii) a nonlinear MPC (NMPC) for controlling the rear wheel speed.To decrease the computational effort, i) and ii) are then replaced with two deep neural networks, which are trained from data generated with the combined PP NMPC architecture during drifting maneuvers.
With respect to (w.r.t.) autonomous drifting implementations not based on MPC, reference [23] uses a high-level fuzzyintegral sliding mode controller, and a low-level constrained optimization for control allocation (CA).In [24] and [25], desirable lateral error and sideslip angle are imposed, resulting in reference course and yaw rates.From these, the target steering angle and thrust angle are generated through an inverted nonlinear vehicle model.The thrust angle is mapped to obtain the desired wheel speed, which is converted into a drivetrain torque by a feedback controller.A similar approach is presented in [26], where the target steering angle and wheel speeds are obtained via inverted dynamics, starting from reference longitudinal and lateral positions and yaw angle that prevent potential road accidents through vehicle drifting.The wheel speeds are then converted into a drivetrain torque by a controller combining feedforward and feedback contributions.In [27] and [28], the steering and torque inputs are selected through a switching strategy using either a rule-based open-loop controller, or a linear quadratic regulator.Reference [29] proposes an adaptive drift control method enabling agile collision avoidance in the event of braking system failure.The algorithm computes the front and rear steering angles as well as the front longitudinal force through a reinforcement learning strategy.However, the absence of a reference trajectory does not allow to classify this implementation as a PT controller, which poses it outside the scope of this study.
In summary, the available drifting PT controllers are based on desired sideslip angle and yaw rate profiles for the intended drifting maneuver, in addition to the reference trajectory, and are not designed to generate drifting only when required to track a challenging trajectory.

II. NOVEL CONTRIBUTIONS
This paper targets the gap identified in Section I, with the following novel contributions: r PT controllers that determine whether, when and how to perform drifting, to facilitate trajectory tracking in extreme conditions, without following preset reference state profiles to purposely induce large sideslip angles.
r Demonstration of the benefits of autonomous drifting in a realistic emergency scenario, i.e., an impending crash at a regular (i.e., 4-way) road intersection.Fig. 1 provides an example of relevant scenario, where two vehicles are about to collide at an intersection.This situation is fairly common, with ∼40% of accidents reported by the U.K. Department of Transport happening at intersections [30].The ego vehicle is the blue one, which is equipped with an automated driving system.In Fig. 1(a) the ego vehicle attempts to avoid the accident by turning and braking.The intervention of a conventional VSC prevents high sideslip angles and excessive levels of understeer or oversteer, but cannot provide collision avoidance.However, the only way for the ego vehicle to avoid the collision could be to perform a maneuver that significantly reduces the turning radius, see Fig. 1(b), by mimicking a specialized driving technique, e.g., trail-braking.
In this study, the identified research question is addressed by a novel PT implementation for emergency conditions, i.e., the so-called advanced NMPC, referred to as NMPC adv in the remainder, which concurrently controls the front steering Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.angle, braking force distribution, and DYM, without sideslip angle constraints.Its performance is compared with those of: i) NMPC emg , a simplified version of NMPC adv , which excludes the DYM contribution, but can still generate trail-braking in emergency conditions through the variation of the front-to-total braking force distribution and the total braking force; and ii) the baseline NMPC, indicated as NMPC bas , which only actuates the front steering angle and the overall longitudinal force, similarly to the controllers presented in [31], [32], [33].In addition, an external conventional rule-based VSC prevents significant longitudinal and lateral tire slip.For fairness of comparison, the three controllers include the same prediction model.
The remainder is organized as follows: Section III describes the simulation environment; Section IV deals with the proposed NMPC formulations; Section V discusses the CA algorithms that are implemented externally to the NMPCs; Section VI presents the testing scenarios and performance indicators; Section VII analyzes the simulation results; finally, the main conclusions are summarized in Section VIII.

III. SIMULATION FRAMEWORK
The simulation environment consists of the following functional blocks, reported in Fig. 2: r The reference trajectory generator, which outputs: i) the road curvature of the reference path along the prediction horizon (note that the path planning layer is beyond the scope of this research); ii) the reference speed profile along the prediction horizon; and iii) a Boolean function, f act .Normal driving conditions correspond to f act = 0, and the vehicle operates with NMPC bas , in conjunction with a conventional ABS/VSC.Emergency conditions correspond to f act = 1, and the PT controller is switched to NMPC emg or NMPC adv if these options are available, while the ABS/VSC intervention thresholds are relaxed, to allow high longitudinal slip ratios and sideslip angles.The transition between the two f act values can be managed through the time-to-collision [34], [35], which is a well-known indicator of the likelihood of crashes.
r The PT layer, which is the core of this study, and includes three alternative formulations: i) NMPC adv , with the following control inputs: ξ, the time derivative of the front steering angle; ζ, the longitudinal tire force rate on the front axle; p b , the front-to-total longitudinal force distribution ratio in braking; and , the DYM rate; ii) NMPC emg , which, w.r.t.NMPC adv , excludes control; and iii) NMPC bas , which, w.r.t.NMPC emg , excludes p b control.
r The control allocation layer, which computes the individual reference wheel torque levels, T w,ij , where the subscripts i = f, r indicate the front or rear axles, and j = l, r the left or right vehicle sides.
r A VSC including a rule-based direct yaw moment con- troller, and the PID-based ABS from [36], which outputs the reference electric motor and individual brake torque levels, T el,i and T b,ij .
r The IPG CarMaker model of an all-wheel-drive electric vehicle with one on-board powertrain per axle, connected to the wheels through a single-speed transmission and a mechanical differential.The vehicle, see its main parameters in Table I, served as a demonstrator for the European Horizon 2020 EVC1000 project [37], and is equipped with a brake-by-wire system that allows individual braking torque control.The CarMaker model was experimentally validated in quasi-steady-state and transient conditions, see the skidpad test results in Fig. 3, and the steering test results in Fig. 4. The very good match between simulations and

TABLE I MAIN CASE STUDY VEHICLE PARAMETERS
experiments makes the high-fidelity model a reliable tool for control system assessment.

A. Internal Model
Within the proposed NMPCs, the prediction is based on a nonlinear dynamic single track (ST) model, in a curvilinear reference system, see its schematic in Fig. 5.The internal (or prediction) model strikes a balance between simplicity and accuracy in predicting vehicle operation in limit handling conditions [38].The states are the longitudinal velocity component v x , lateral velocity component v y , and yaw rate ψ.The dynamics are described by the following longitudinal, lateral and yaw moment balance equations: Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.
where m is the vehicle mass; I z is the yaw mass moment of inertia; l f and l r are the front and rear semi-wheelbases; and F x,i and F y,i are the longitudinal and lateral tire forces.The aerodynamic drag force, F drag , is calculated as: where ρ air is the air density; C d is the aerodynamic drag coefficient; and A car is the frontal area of the vehicle.The rolling resistance force, F r , is expressed as: with f 0 and f 2 being the rolling resistance coefficients; and g the gravitational acceleration.F x,r is expressed through a continuous nonlinear function, which depends on the front-to-total longitudinal tire force distribution coefficients in traction and braking, p t and p b : where c 1 is a constant tunable parameter.The direct yaw moment, M z , is generated through the friction brakes, and the corresponding longitudinal tire force contribution, F x,M z , is calculated as: where b is the track width.M z and F x,M z account for the differential braking effect, without the computational load associated with more complex formulations, such as a double track model [39].The vehicle position w.r.t. the reference path is described in a curvilinear coordinate system, in terms of: i) distance along the path, s; ii) lateral position error, e y , i.e., the distance of the center of gravity (CG) from the reference path; and iii) heading angle error, e ψ , i.e., the body frame orientation w.r.t. the reference path.s, e y , and e ψ are system states, whose dynamics are described by: where ρ ref is the reference road curvature, which is a function of s.Tire behavior has to be accurately accounted for in the highly nonlinear conditions typical of limit handling.The lateral tire forces in pure lateral slip conditions, F y 0 ,i, , are calculated through a simplified version of the Pacejka magic formula: where F z,i is the vertical axle load; and μ y 0 ,i is the lateral load coefficient, which is given by: In ( 8), μ y is the lateral tire-road friction coefficient, and α i is the slip angle, which, under reasonable assumptions, is expressed as: D y,i is a linear function of F z,i : By neglecting the suspension dynamics in the longitudinal load transfer model, F z,i is calculated as: where F stat z,f and F stat z,r are the static load contributions; F z,x is the longitudinal load transfer; a x,meas is the measured longitudinal acceleration, i.e., F z,x is assumed constant along the prediction horizon to reduce the computational load; and h g is the center of gravity height.
The model considers the coupling effect between longitudinal and lateral axle forces through a friction ellipse approximation: where μ x is the longitudinal tire-road friction coefficient; and F x,tot,i is the total longitudinal axle force, consisting of two contributions, i.e., a symmetric component and a DYM-related contribution.In the ST model, the latter is assumed to be distributed between the front and rear axles according to the respective vertical loads.To avoid negative radicands in (12), the algorithm implementation imposes a saturation of the lateral axle force: Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply. where is the primary function; c 2 and c 3 are constant values to approximate the shape of the friction ellipse, according to a trade-off between accuracy and computational load; and the sat parameter (set to 0.05 in the remainder) is a constant saturation level.
The lack of consideration of the wheel dynamics in the prediction model enables a significant increase of the numerical discretization time, e.g., from 1 ms to 25 ms, of the internal model within the NMPC algorithm.During the implementation phase, it was verified that NMPC adv with a prediction model discretized at 25 ms -rather than 1 ms -is characterized by a maximum 2.2% decay of the considered performance indicators, while providing a >8-fold reduction of the controller execution time, i.e., the time required to compute the control inputs, for the same sampling time and prediction horizon of the algorithm.This design choice makes the controller real-time implementable, see the following Section IV-E.
Figs. 3 and 4 confirm that also the internal model -despite being based on a completely independent formulation from the CarMaker model for control system assessment -is well aligned with the experimental measurements.

B. Nonlinear Optimal Control Problem
At each time step j c , the MPC algorithm computes an optimal control input sequence that minimizes the cost function J, accounting for the prediction of the system dynamics over a finite horizon H p , while considering system constraints [40].The discrete form of the nonlinear optimal control problem (NOCP) is: x 0 = x in (14a) where J consists of a terminal cost, J term., which aims to minimize the error at the end of the prediction horizon H p , and a stage cost, corresponding to J stage1 + J stage2 , which aims to optimize the response along H p ; N p is the number of steps of H p , i.e., H p = N p T s , with T s being the controller implementation time; N c is the number of steps of the control horizon H c , i.e., H c = N c T s ; the subscript k indicates the discretization step; z is the vector of the predicted system outputs, while z ref is the corresponding reference vector; ε is the slack variable, which is used to impose the soft constraints; P x , Q x , and R u are positive diagonal weighting matrices, which, in the tuning phase, were scheduled as a function of the estimated tire-road friction level at j c ; R ε is the weight of the slack variable; x is the state vector; is the decision variable vector, with u k being the control input vector; x in is the initial value of the state vector; f is the discretized vector field describing the internal model; g out is the function expressing the system outputs; u min and u max , and x min and x max are the bounds on u and x; and h ic is the inequality constraint function.
To simplify the design and ensure favorable numerical conditions, the NOPC is scaled and non-dimensionalized, i.e., its dependent (states, control inputs, and external parameters) and independent variables (time) are replaced with scaled quantities, where the scaling factors i ch are defined as the maximum values of the respective variable: and ĩk indicates a generic dimensionless variable.In the remainder, the subscript k is omitted from the individual variables for simplicity of notation, unless when it is especially meaningful.

C. States, Control Inputs and Online Data
In NMPC adv , the prediction model described by ( 1)-( 13), and discretized and re-arranged according to the nonlinear statespace formulation in (14(b)), has the following state vector x: δ, F x,f and M z are states, since their time derivatives are equal to the respective control inputs ξ, ζ, and : Hence, the control input vector is: For given F x,f , the effect of p b is to vary the rear braking force, e.g., to emulate hand brake cornering in emergency conditions.The output vector, z, includes the PT error variables, and the states associated with the control inputs: with the reference values being: Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.
The reference longitudinal speed, v x,ref , is assumed to be known a priori, and variable along H p .The online data vector is: where a x,meas , μ x = k μ μ y (with k μ being the fixed conversion factor to obtain the corresponding μ y value), and f act are constant along H p , while ρ ref and the maximum and minimum DYM values (M z,max and M z,min , see Section V-C) can vary with k.
As NMPC emg does not include DYM control, its state, control input and online data vectors are re-arranged as: NMPC bas also assumes constant braking force distribution, and thus, while x and w are the same as for NMPC emg , u becomes:

D. Actuation Constraints
For all proposed NMPCs, hard constraints are set on the steering angle and front longitudinal tire force and their variation rates, as well as on the rear longitudinal tire force: where μ id is an ideal friction coefficient that marginally overestimates the real one used in the CarMaker model, not to have underbraking, while the slip ratios are limited by the conventional ABS, if required; and F x,M z is only present in NMPC adv .NMPC adv and NMPC emg also include a hard constraint on p b : Finally, in NMPC adv , a soft constraint limits the DYM, while a hard constraint is imposed on its rate: where M z,min,k and M z,max,k are computed by the CA algorithm, based on the prediction of the control inputs at the previous time step, see Section V-C.In general, the constraints on the control input rates allow to account for actuator dynamics, and enhance control smoothness.

E. Real-Time Implementation of the NMPC Algorithms
The proposed NMPC algorithms were implemented implicitly, i.e., online, through the ACADO toolkit, which provides a powerful interface for NMPC development [41].The controller sampling time is set to 50 ms, and the prediction horizon consists of 20 steps, corresponding to H p = 1 s.The prediction model is discretized at 25 ms.The selected solver is QPOASES 3, running with 5 iterations.All controllers were set to run in real-time on the dSPACE MicroAutoBox III unit in Fig. 6, with a quad-core 1.4 GHz ARM processor, and 64 Mb flash memory.Despite the highly nonlinear nature of its internal model, NMPC adv , which represents the most complex variant among the proposed NMPCs, has achieved a computational time, T a , significantly below the controller sampling time T s , i.e., the maximum computational time is T a,max =10.3 ms < 50 ms = T s .This successful demonstration highlights the effective real-time implementability of the proposed control logic, despite its computational complexity.

V. CONTROL ALLOCATION ALGORITHM
The CA algorithms determine the wheel torque distribution that better approximates the longitudinal tire force and -where applicable -DYM demands computed by the NMPCs, while considering the individual tire-road friction limits defined in Section V-A.

A. Longitudinal Tire Force and Torque Limits
The maximum and minimum values of the individual wheel torque (T w,ij,max and T w,ij,min ) and longitudinal tire force (F x,ij,max and F x,ij,min ) are computed based on the available tire-road friction and the lateral tire force F y,ij,k , through a friction ellipse approximation: Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.
= r w F x,ij,max,k where the subscript k indicates the variables that are considered to be changing along the prediction horizon; r w is the wheel radius; and F z,ij,k is the vertical load on each corner, which is calculated as: where the static contributions (F stat z,ij ) and the longitudinal load transfer are half of those considered in the ST prediction model in (11); and the lateral load transfers are computed through the following static formulations: where a y,est,k is the estimated lateral acceleration profile; h r,i is the roll center height; and K ϕ,i is the axle roll stiffness.The distance h between center of gravity and roll axis is given by: In (27), the F y,ij,k profiles are approximated based on a y,est,k and F z,ij,k , according to: a y,est,k changes during H p .Since at the instant j c the lateral acceleration is available as an on-board sensor measurement (a y,meas ), while in the following steps along H p it must be estimated based on the path ahead, in the implementation a y,est,k is computed as the weighted sum of a y,meas , and a second contribution based on the reference curvature and estimated longitudinal vehicle speed (v x,est,k ) profiles: where v x,meas is the current longitudinal speed; and the weight w 1 linearly increases along H p , to prioritize the measurement at the beginning of H p , and the prediction at the end of H p .

B. Control Allocation for NMPC bas and NMPC emg
NMPC bas and NMPC emg have the same CA algorithm, given the absence of an M z output from both.The algorithm symmetrically distributes the longitudinal tire forces in traction and braking, according to the respective distribution coefficients p t and p b , while including a saturation based on the tire-road friction level in (33).
The resulting T w,ij can then be modified by the conventional VSC embedded in the simulation framework, see Fig. 2.

C. Control Allocation for NMPC adv
Computation of feasible region: Given the presence of a reference M z , in limit handling the CA of NMPC adv needs to strive a trade-off between the total longitudinal force, F x , and DYM, M z , according to an approach similar to the one in [42].
In braking conditions, which are typical of emergency maneuvering, since the brake actuators are always oversized w.r.t. the available tire-road friction level, the minimum longitudinal forces (F x,j,min ) that can be generated on the left and right vehicle sides can be computed from F x,ij,min,k in (27): F x,j,min = F x,f j,min + F x,rj,min (34) where the subscript 'k' has been omitted for simplicity of notation.The region of feasible operation in the M z (F x ) plot is a rectangle with vertices P h (F x,h , M z,h ), with h = 1,..,4, corresponding to the following coordinates, see Fig. 7, referring Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.
to a left turn scenario: In Fig. 7, P 1 corresponds to the absence of braking force and DYM; P 2 and P 4 correspond to the maximum and minimum DYMs (M z,max and M z,min ), achieved through the brake actuation on the relevant vehicle side only, up to the tire friction limit; and P 3 corresponds to the actuation of the braking forces up to the friction limit on both vehicle sides.For a left turn, the DYM value corresponding to P 2 has usually smaller magnitude than the one corresponding to P 4 , because of the effect of the lateral load transfer, under the assumption of symmetric friction level within the axle.For the same reason, P 3 is associated with a negative M z,F x,min .
In the controller implementation, to prevent the risk of safety-critical under-actuation, the DYM boundaries are adjusted through a relaxation term M z,rel , by which the values of M z,max and M z,min are respectively increased and decreased, to obtain the relaxed vertices P 2 and P 4 , from which also P 3 can be derived.Such a relaxation approach permits not to over-constrain vehicle performance, but concurrently ensures that the algorithm does not produce unrealistic demands.
In traction, the total maximum longitudinal tire force at the vehicle level, F x,max , is the minimum between the maximum traction force that can be delivered by the two powertrains -each one corresponding to a maximum traction force F x,i,max,pwt at the axle level -and the maximum longitudinal tire friction force: Similarly to conventional VSC algorithms, which apply a DYM nearly exclusively in braking [42], in traction conditions NMPC adv is allowed to generate only a very moderate yaw moment, equal to M z,rel , to provide continuity of the feasible M z region as a function of F x .During traction, the direct yaw moment is generated through the concurrent application of a traction torque, resulting into symmetric longitudinal force contributions on the two tires of the same axle, and a braking torque, whose maximum value is −2M z,rel /b.
Hence, in Fig. 7, the polygon vertices in traction are: , −M z,rel P 7 (F x,max , 0) As a result, the overall feasible vehicle operating region is given by the area of the polygon P 2 P 3 P 4 P 5 P 6 P 7 P 8 P 9 , whose boundaries are described by linear equations that vary along H p .
A priori control input limitation: By using the prediction of the total longitudinal force, F x = F x,f + F x,r − F x,M z , from the previous time step j c −1 along H p , the CA algorithm outputs the M z,max,k and M z,min,k profiles, which are provided as online data to NMPC adv , to set the DYM constraints in (26).This approach does not compromise the computational efficiency of the online solution of the optimal control problem, and is justified by the small sampling time and usually negligible variation of the main variables for consecutive time steps.
A posteriori control input saturation: NMPC adv outputs F x , which is computed from the control inputs, and the reference DYM, M z .The desired control input corresponds to a point of coordinates (F x ; M z ) in Fig. 7.At each step of H p , if (F x ; M z ) is inside the feasible area in Fig. 7, which is the case of point A, no modification is applied.Vice versa, if the point is outside the area, two conditions can occur: r If sign(M z ) = sign( ψ), which corresponds to a destabi- lizing DYM, the algorithm tends not to vary F x where possible, and calculates a corresponding feasible DYM, M z,sat , i.e., point B in Fig. 7 translates into B 1 .
r If sign(M z ) = sign( ψ), which corresponds to a stabilizing DYM, the CA prioritizes M z , which is kept unaltered if possible, and modifies F x , which becomes F x,sat , i.e., point C translates into C 1 .Wheel torque control allocation: For the computation of the individual wheel torque levels, the symmetric longitudinal force contribution from NMPC adv is distributed according to p t and p b , while the direct yaw moment contribution is allocated to one or two wheels on the same side according to the following chain rule: rr f r fr rr (36) where the notations '1 st ' and '2 nd ' denote the priority level of the wheel, i.e., the brakes are actuated on the '1 st ' corner until its longitudinal force is saturated, after which the '2 nd ' corner on the same side is actuated.For example, in a left turn braking scenario with sign(M z ) = sign( ψ), the reference wheel torque levels are given by ( 37), shown at the bottom of the next page, where T w,il,L1−3 indicate intermediate variable torque levels to reduce notation complexity.From (37), if the left rear wheel reaches saturation because of p b , the M z contribution is entirely allocated to the left front corner.If the saturation is caused by M z , the DYM term allocated to the left front wheel is adjusted by adding the contribution that cannot be generated by the left rear corner, until the saturation level T w,f l,min is reached also on the front corner.T w,f r and T w,rr are computed through (33).The same method is applied to traction conditions and the other three cases in ( 36)- (37).

A. Considered Scenarios
The case study maneuver is an emergency scenario at a road intersection, with an impending crash between vehicles, i.e., an automated ego vehicle that aims to steer left, and a column of vehicles traveling at constant speed in straight line, see Fig. 8(a).
The scenario is simulated for two tire-road friction factors, i.e., μ = 1 and μ = 0.55.The reference path curvature and speed profiles, ρ ref and v x,ref , are generated through look-up tables, as functions of s. ρ ref and v x,ref change along the preview time H prev = N prev T s , which is considered to be equal to the prediction horizon H p , with N prev being the number of preview points.
The considered reference paths and speed profiles for the two friction levels are depicted in Fig. 8(b), and are inspired by the trail-braking maneuvers in [4] and [43], with very aggressive trajectories and speed/acceleration profiles to purposely bring vehicle response beyond the limit of handling.Given the focus on the innovative PT function for emergency conditions, and to prevent interactions with the path planning layer, which could compromise the objectivity of the PT algorithm assessment, the reference profiles do not vary throughout the maneuver (i.e., absence of path re-planning).For μ = 1, four reference trajectories, T1-T4, are considered for PT assessment, see Fig. 8(b).T1 follows the center line of the road out of the corner, which minimizes the risk of collision with upcoming traffic.T2 involves a U-shape to approach the left side of the roadway, while T3 and T4 have smaller curvature radii, respectively following the lane center line or its inner side at the exit of the turn.For μ = 0.55, T1-T3 and the speed profile are selected to resemble the shape of those for high-friction conditions, with appropriate re-parametrization accounting for the lower μ level.However, the most aggressive reference trajectory, i.e., T4, is deliberately avoided for μ = 0.55, as it is unrealistic for the specific tire-road friction condition.

B. Key Performance Indicators
The following set of key performance indicators (KPIs) is used to evaluate control system performance: RM S e y = 1 where T 1 and T 2 are the times at which the vehicle reaches the initial and final points of the maneuver, s 1 and s 2 in Fig. 8(b).
r v x,min and RM S e vx , i.e., the minimum longitudinal vehi- cle speed and the root mean square value of the longitudinal speed error along the maneuver: ) and (T w,rl < T w,rl,min ) and (T w,f l,L2 ≥ T w,f l,min ) Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.

TABLE II MAIN NMPCADV PARAMETERS.
Fig. 9. Block diagram of the benchmarking PT architecture inspired by [44], consisting of a FF+FB steering controller and a PI speed tracking controller.
Remark: In general, the significant tracking errors visible in the results in the following Section VII are caused by the extreme nature of T1-T4, involving vehicle operation well beyond its lateral acceleration capabilities.During the study, it was also verified that, for operation within the limit of handling, the considered controllers involve a typical PT error of the order of magnitude of a few cm.Similar considerations apply to the speed tracking error.

C. Benchmarking Controller
The performance of the proposed PT controllers has been compared with that of the well-known feedforward and feedback (FF+FB) steering controller in [44], which has been developed and assessed for applications at the limit of handling.The feedback contribution is given by a proportional setup accounting for the heading angle error and the lateral error, including consideration of a look-ahead distance.
The tracking of the reference speed profile is achieved through a proportional integral (PI) controller.The wheel torque distribution is based on the same algorithm presented in Section V-B for NMPC bas , whose outputs can be modified by the conventional VSC.Fig. 9 shows the overall architecture of the benchmarking control structure, referred to as FF+FB in the remainder.

VII. SIMULATION RESULTS
The main controller parameters for NMPC adv are listed in Table II.The sampling time T s , discretization time T disc , and number of prediction horizon steps N p are the same across all NMPC formulations.The weighting matrices Q x and R u have

TABLE III KPIS FOR THE CONTROLLER CONFIGURATIONS THAT MANAGE TO PREVENT
THE COLLISION WITH THE ONCOMING VEHICLES been appropriately modified by removing the terms linked to the DYM contribution in the emergency formulation NMPC emg , as well as the term related to the braking force distribution in the baseline formulation NMPC bas .

A. High-Friction Simulations Along T1
Fig. 10 shows the trajectories for T1, with the vehicle positions being captured at constant time intervals for the different control solutions.The notation 'ABS' refers to the case of straight line emergency braking of the ego vehicle, with activation of the anti-lock braking system.The lateral and speed tracking error profiles as well as the vehicle sideslip angle and yaw rate responses are displayed in Fig. 11.Fig. 12 compares the steering angle, the total front and rear longitudinal tire forces, and the direct yaw moments from the CA algorithm, together with those actually generated by the longitudinal tire forces.
The ABS braking case avoids the impact, see Fig. 10 and the safety distance, d sf,ABS = 0.569 m, in Table III, but leaves the vehicle stranded in the middle of the road, with a 90 deg heading angle error w.r.t. the traffic direction, thus increasing the risk of a crash with approaching vehicles.With FF+FB and NMPC bas , the VSC applies asymmetric braking torque levels, e.g., see the left braking torque reduction to generate a stabilizing direct yaw moment, thus preventing |β| values in excess of 5 deg.Without the pre-emptive information on the road curvature ahead, FF+FB tends to generate an initial significant braking action, followed by a substantial steering input.On the contrary, NMPC bas takes a more aggressive cornering approach, and 'cuts' the curve.Nevertheless, in both cases, the car cannot track the reference path, and collides with the oncoming vehicles, at the longitudinal speeds of 32 km/h and 30 km/h respectively, see the crosses in Fig. 11.
Interestingly, drifting enables low radius cornering, see Fig. 10.This is the case for NMPC emg and NMPC adv , where the relaxation of the conventional VSC thresholds, and the control of the available actuators with the only purpose of trajectory tracking (without a sideslip reference profile) bring: i) collision avoidance; ii) safe heading angle response w.r.t. the ABS braking case; and iii) high |β|, with peaks respectively exceeding 27 and 20 deg, see Fig. 11, which is not an objective by itself, but a means to better track the reference trajectory.The addition of M z control leads to: i) a more agile corner entry phase, corresponding to larger heading angle magnitude, followed by a stabilization; ii) an e y,max reduction by >1.1 m (see Table III) for NMPC adv w.r.t.NMPC emg ; and iii) improved v x,ref tracking, with a v x,min increase from 22.4 to 24.7 km/h.In NMPC adv , the sideslip angle is restricted to lower magnitudes than in NMPC emg in the central part of the maneuver, after which M z is no longer required, and the vehicle is brought back to normal operation.Although the NMPC emg formulation does not imply any reference direct yaw moment, a non-zero M z profile is visible in Fig. 12, both at the CA output and at the tire level.This is caused by the lateral load transfer effect, which significantly limits the maximum applicable braking torque levels on the inner corners, as the respective tires tend to lock.
In NMPC adv , the actual direct yaw moment closely tracks the one predicted by the CA, except for the central part of the maneuver, during which the operational boundaries in Fig. 7 cannot be generated, due to the tire friction limits.Fig. 13 provides an insight into the NMPC adv operation, by reporting the region of feasible M z as a function of the total longitudinal force F x , for three equally spaced steps along the prediction horizon, starting from a time t j c corresponding to the corner entry, where the lateral load transfer is limited, due to the relatively low lateral acceleration a y = 3.2 m/s 2 .In the last prediction step, i.e., at t j c+Np , the predicted a y reaches ∼9 m/s 2 , corresponding to high lateral load transfers.As a result, the left (i.e., inner) wheels are unloaded, which significantly reduces the maximum possible destabilizing direct yaw moment through the actuation of the friction brakes.
Although the high lateral load transfer facilitates the application of a stabilizing yaw moment (i.e., preventing turning) and increases the asymmetry of the feasible region, the consideration of the tire friction ellipse (coupling between longitudinal and lateral tire forces) within the CA algorithm still brings a Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.

B. High-Friction Simulations Along T2-T4
For assessing controller robustness and verifying the generality of the trends in Section VII-A, Fig. 14 depicts the resulting trajectories for T2-T4, with the reference speed profile in Fig. 8(b).NMPC bas fails to avoid the impact with the proceeding vehicles, regardless of the considered trajectory, while NMPC emg and NMPC adv always manage to prevent the crash.Moreover, NMPC adv consistently delivers better tracking performance than NMPC emg , which becomes increasingly apparent with the reference trajectories associated with the highest curvature values (T3 and T4).The benefits of NMPC adv w.r.t.NMPC emg also cover the other vehicle performance aspects, such as the minimum longitudinal speed during the test, see Table III.For T3 and T4, w.r.t. the straight line ABS braking case in Fig. 10, NMPC adv also provides a d sf increase (e.g., amounting to 0.785 m along T4, see Table III), with negligible difference between the two trajectories.

C. Low-Friction Simulations
The low-friction simulations are carried out for the reference paths and speed profile in Fig. 8(b), see the results in Figs.15-17, referring to T1.In the controller tuning for low-μ conditions, the heading angle error has been marginally penalized w.r.t. the high-friction case, to improve the vehicle behavior at the corner exit.
The general trends are similar to those observed in highfriction conditions.For FF+FB and NMPC bas , the VSC intervention limits |β| to values below 2 deg, see Fig. 16, which are typical of VSC operation in low-friction scenarios [7].This causes the vehicle to significantly understeer, and fail to avoid the impact, which occurs at v x = 18 km/h and v x = 20 km/h,   slide outside the turn trajectory, and thus cannot avoid colliding with the proceeding vehicles, while traveling at a longitudinal speed of ∼12 km/h.The inclusion of the DYM contribution, which purposely destabilizes the vehicle at the beginning of the maneuver, enables NMPC adv to prevent the impact and achieve similar d sf (see Table III) to straight line ABS braking.
For T2 and T3, the relative performance of the different configurations is generally similar to the T1 case, see the KPIs in Table III.However, in T3 NMPC emg is able to avoid the collision, and NMPC adv also guarantees a ∼0.4 m d sf increase w.r.t. the straight line ABS maneuver.

D. Robustness Analyses
The target is to verify controller robustness w.r.t.model uncertainties and disturbances.The first analysis was conducted via Monte Carlo simulations to evaluate NMPC adv in several challenging scenarios.To generate the Monte Carlo test cases, six critical parameters are varied only in the CarMaker model for control system assessment along T2 in high-friction conditions, whilst they are kept constant and equal to their nominal value in the internal model of NMPC adv .The selected parameters are: i) an additional mass, m add , w.r.t. the nominal vehicle mass, together with the corresponding plausible variation of yaw mass moment of inertia; ii) the tire-road friction factor, μ; iii) the scaling factor of the longitudinal shape factor in the Pacejka model, W C x , which mainly affects the longitudinal slip stiffness of the tires; iv) the scaling factor of the lateral shape factor, W C y , which mainly modifies tire cornering stiffness; v) the scaling factor of tire relaxation, W σ ; and vi) a scaling factor on the lateral vehicle velocity, W v y , emulating a sideslip angle estimation error.The Monte Carlo analysis consists of 500 test scenarios, defined by a combination of parameter values randomly drawn from the respective normal probability distribution, see Fig. 18.The NMPC adv performance is evaluated through the concept of collision rate, defined as the percentage of scenarios where a collision is detected, i.e., in which d sf is negative.As a term of comparison, the same analysis is carried out with the benchmarking FF+FB controller.
The safety distance distribution in Fig. 19 highlights that, regardless of the randomly selected parameter combinations, FF+FB has a 100% collision rate.
All the FF+FB tests are located in the red region of the plot, with d sf < −15 cm, corresponding to high-severity impacts.This results in an average safety distance μd sf = −1.405m, Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.and a corresponding standard deviation σd sf = 0.307 m, see Table IV.In contrast, NMPC adv shows significant robustness, with a collision rate of ∼20%.Among the cases corresponding to an accident, 29 result in low-severity impacts, with −0.15 m ≤ d sf ≤ 0 m (orange part of the plot).
The second robustness analysis involves the assessment of the controllers with a second vehicle, simulated in CarMaker, characterized by significantly reduced vehicle mass (m = 1463 kg) and yaw mass moment of inertia, and different tire and suspension parametrizations w.r.t. the case study vehicle of the previous simulations.Such vehicle was artificially generated through plausible downsizing of the parameters of the experimental demonstrator in Table I.The trend in the results in Fig. 20, referring to T1 in high tire-road friction conditions, is consistent with that in Fig. 10, and highlights the collision avoidance benefits of the proposed formulations, regardless of the specific vehicle.

E. Demonstrating the Benefits of Operating At Non-Imposed High Sideslip Angles
The target is to demonstrate the advantage of operating at nonimposed high sideslip angles.To address this point, a new control strategy, the so-called NMPC adv −β ref , has been introduced, which is based on NMPC adv , but incorporates the tracking of a reference sideslip angle profile.The NOCP formulation in (14) has been modified by introducing an additional term in both the output and reference output vectors, specifically focused on tracking the reference sideslip angle: where β is computed in the prediction model as β = atan(v y /v x ).
To generate the reference sideslip angle, β ref , ramp steer maneuvers were conducted offline, at different vehicle speeds.During postprocessing, the kinematic sideslip angle in quasisteady-state cornering, β kin,SS , is obtained from [45]: where ρ is the effective curvature during each instant of the ramp steer.The corresponding quasi-steady-state dynamic sideslip angle contribution, β dyn,SS , is calculated as [46]: where β SS is the actual sideslip angle, varying with time, from the high-fidelity model during the quasi-steady-state cornering conditions of the ramp steer maneuver.when necessary, and the tracking of otherwise unachievable trajectories, which enhances the collision avoidance capability.
r The NMPC formulation concurrently controlling all the available actuators, NMPC adv , prevents road accidents in all scenarios, and brings the vehicle to a desirable heading angle condition at the end of each test, differently from the actuation of straight line ABS braking, which avoids the primary impact, but then leaves the ego vehicle stranded in the middle of the road.
r The emergency NMPC formulation (NMPC emg ) with- out direct yaw moment control, but including the option of high-slip maneuvering through longitudinal tire force distribution to emulate the hand brake effect, prevents the collision in the four high-friction scenarios and in one low-friction case, with degraded key performance indicators (KPIs) w.r.t.NMPC adv .Nevertheless, in all tests NMPC emg provides significantly better KPIs than NMPC bas and FF+FB.r NMPC adv is robust and flexible in handling uncertainties related to tire-road friction conditions and tire parameters, as well as disturbances related to sideslip angle estimation errors, with consistently superior performance w.r.t.FF+FB.Also, NMPC adv is easily adaptable to very different vehicles in terms of inertial, suspension, and tire properties.
r NMPC adv performs drifting only when necessary to follow a reference path, showcasing superior collision avoidance capability w.r.t. the considered benchmarking NMPC adv −β ref implementations for controlled drifting, which -consistently with the available literature -track an imposed sideslip angle profile.

Fig. 1 .
Fig. 1.Emergency maneuvering of an automated ego vehicle (in blue) in a road junction scenario: (a) combined steering and braking intervention, while keeping the vehicle within the operational domain of conventional stability controllers; and (b) automated driving control including forms of expert driving actuation, to achieve vehicle operation beyond the limit of handling with lower trajectory radii for accident prevention.

Fig. 3 .
Fig. 3. Steering wheel angle δ w , sideslip angle β, and yaw rate ψ, as a function of the lateral acceleration a y , during a 40 m radius skidpad maneuver.Exp.: experimental results; Sim.: high-fidelity CarMaker model simulation results; Int.: internal model results.

Fig. 4 .
Fig. 4. Time profiles of δ w , ψ, β, and a y , during a transient steering maneuver at a vehicle speed of approx.100 km/h.Exp: experimental results; Sim.: high-fidelity CarMaker model simulation results; Int.: internal model results.

Fig. 5 .
Fig. 5. Single track model schematic and sign conventions of the main variables.

Fig. 7 .
Fig. 7. Feasible vehicle operating region during a left corner, in terms of total longitudinal tire force F x and direct yaw moment M z .

r
d sf , which is the safety distance between the controlled vehicle and the oncoming vehicles, see Fig. 8(a), computed as the minimum gap maintained between the controlled vehicle and the obstacles represented by the oncoming vehicles, throughout the test.r e y,max and RM S e y , i.e., the maximum and root mean square values of the lateral error: e y,max = max(e y )

Fig. 13 .
Fig. 13.Variation of the operational boundaries for three time instants along H p .

Fig. 18 .
Fig. 18.Parameters values distribution for the Monte Carlo analysis.

Fig. 19 .
Fig. 19.Safety distance distribution resulting from the Monte Carlo analysis.

Fig. 20 .
Fig. 20.Comparison of the resulting trajectories along T1, for μ = 1, for a different case study vehicle.

Fig. 21 .
Fig. 21.Maps of the quasi-steady-state kinematic and dynamic sideslip angle contributions, obtained from ramp steer tests for μ = 1.

Fig. 22 .rr
Fig. 22.Comparison of the NMPC adv formulations along T1 for μ = 1: (a) Resulting trajectories; and (b) e y , v x , β and ψ profiles (the colors of the line are consistent with those in subplot a).

vehicles, autonomous drifting, active safety, control allocation, nonlinear model predictive control.
x scaling factor of the longitudinal shape factor in the Pacejka model.

TABLE IV RESULTS
OF THE MONTE CARLO ANALYSIS