Research on distributed model predictive control of heterogeneous vehicle platoon under unidirectional topology (Matlab code implementation)

Welcome to this blog

Advantages of bloggers:Blog content should be as thoughtful and logical as possible for the convenience of readers.

Motto:He who travels a hundred miles is half as good as ninety.

The directory of this article is as follows:

Table of Contents

1 Overview

2 Operation results

3 References

4 Matlab code, data, articles


1 Overview

This paper proposes a distributed model predictive control (DMPC) algorithm for heterogeneous vehicle queues with unidirectional topology and a priori unknown expected set points. The vehicles (or nodes) in the squad are dynamically decoupled but constrained by the space geometry. Relying only on the information of neighboring nodes, each node is assigned a local open-loop optimal control problem, where the cost function is designed by penalizing the error between the predicted trajectory and the hypothesized trajectory. In conjunction with this penalty, an equality-based terminal constraint is proposed to ensure stability, which forces the terminal state of each node within the prediction range to be equal to the average of its neighboring states. By using the sum of local cost functions as Lyapunov candidates, it is shown that the asymptotic stability of this DMPC can be achieved by explicit sufficient conditions on the weights of the cost functions. Passenger car simulation demonstrates the effectiveness of the proposed DMPC.

In recent years, platooning of autonomous vehicles has received considerable attention [1]-[7]. This attention is mainly due to its potential to significantly benefit road transport, including improving traffic efficiency, enhancing road safety and reducing fuel consumption [1], [2]. The main goal of squad control is to ensure that all vehicles in the group move at the same speed while maintaining a pre-specified distance between any consecutive followers [5]-[7].

The earliest practices on platoon control date back to the PATH program of the 1980s, which introduced many well-known topics in sensors and actuators, control architecture, decentralized control, and string stability [5]. Since then, many other issues regarding platoon control have been discussed, such as the choice of spacing strategy [6], [7], the impact of communication topology [8]–[10], and the impact of dynamic heterogeneity [11 ], [12]. In recent years, some advanced platoon control laws have been proposed under the framework of multi-agent consensus control [13]-[17]. Most of them employ linear dynamics and linear controllers to facilitate theoretical integrity and do not consider input constraints and model nonlinearities. Some notable exceptions are [14] and [17], where the communication topology is assumed to be restricted in scope. However, input constraints and model nonlinearities do exist in a more accurate problem formulation due to actuator saturation and some significant nonlinearities involved in powertrain systems, such as engines, drivetrains, and air resistance [18], [19] middle. Furthermore, with the rapid deployment of vehicle-to-vehicle communications such as DSRC and VANET [20], various types of communication topologies are emerging, for example, dual-predecessor (TPF) type and multi-PF type [21], [22]. Given the diversity of topologies, new challenges for platoon control naturally arise, especially when the various topologies are considered in a systematic and integrated manner.

This paper proposes an innovative formation control scheme based on the model predictive control (MPC) framework, taking into account nonlinear dynamics and topological diversity. Traditionally, MPC is used for single-agent systems, where control inputs are obtained by numerically optimizing a finite-level optimal control problem, where both nonlinearities and constraints can be handled explicitly [23]. This technology has been accepted by many industrial applications, such as thermal energy control [24], collision avoidance [18], vehicle stability [25] and energy management [26]. Most of these MPCs are implemented in a centralized manner, where all control inputs are calculated by assuming that all states are known [18], [24]–[26]. When considering practical platooning systems involving multiple vehicles, a centralized implementation is inappropriate due to the limitations of collecting all vehicle information and the challenge of computing large-scale optimization problems. In this paper, we propose a distributed MPC (DMPC) synthesis method for heterogeneous fleets, which assigns a local optimal control problem to each vehicle relying only on the information of its neighboring vehicles.

Recently, several DMPC schemes for dynamically coupled or decoupled multi-agent systems have been proposed [27]–[30]. Asymptotic stability is usually established by using consistency constraints, e.g. the mismatch between the newly calculated optimal trajectory and the previously calculated optimal trajectory must be bounded [27], [28]. A recent comprehensive review on DMPC can be found in [31]. However, most existing DMPC algorithms only focus on system stability with a common set point, assuming that all agents know the required equilibrium information a priori. For a tank platoon, such a common set point corresponds to the leader’s status. However, it is unrealistic to assume that all followers can communicate with the leader, meaning that not all followers know the required set points in the platoon. This paper aims to solve the control problem of vehicle queues with a priori unknown expected set points under the DMPC framework. Most existing MPC work in this area relies on the problem formulation of adaptive cruise control (ACC) [32], [33], where only two vehicles are involved in the problem formulation. There are some extensions to ACC cooperation cases involving multiple vehicles [14], [34]. However, this treatment in [14] and [34] also directly brings two consecutive vehicles into the problem formulation, and they are only suitable for limited types of communication topologies, namely PF type and leader-following (PLF) type.

This paper proposes a DMPC algorithm for heterogeneous platoons with unidirectional topology and a priori unknown expected set points. The contribution of this paper is reflected in two aspects: 1) The proposed DMPC algorithm does not require all nodes to know the required set points a priori, which is a significant difference compared with many previous studies. Improvements on [27]-[30] and 2) Our findings not only clearly highlight the importance of communication topology in stabilizing the entire platoon system, but also extend the results in [14] and [34] to accommodate any arbitrary unidirectional Topology. Specifically, a squad is viewed as a set of vehicles that are dynamically decoupled but interact with each other through spatial geometry and communication topology. Within a platoon, only followers who communicate directly with the leader know the desired set point. Under the proposed DMPC, each follower is assigned a local open-loop optimal control problem relying only on the information of neighboring vehicles, where the error between the predicted trajectory and the assumed trajectory is penalized. A terminal constraint based on the neighbor average is proposed to force the terminal state of each node to be equal to the state average of its neighboring nodes. We use the sum of local cost functions as Lyapunov candidates and show that under one-way topologies asymptotic stability can be achieved through explicit parametric conditions on the cost function weights.

2 Operation results

Part of the code:

%% vehicle seven
    tic
    Vehicle_Type = [Mass(7),R(7),g,f,Eta,Ca(7),Tao(7)]; % the vehicle parameters: Mass,R,g,f,Eta,Ca(i), Tao,
    X0 = [Postion(i-1,7),Velocity(i-1,7),Torque(i-1,7)]; % the vehicle variable in the last time
    Pd = zeros(Np + 1,1); Vd = zeros(Np + 1,1); % Total Np + 1 points, pay attention to the subscript, i-1 represents the state of the previous moment, i represents the current optimization solution required status
    Xdes = [Pd,Vd]; % Udes = Td; % Desired behavior of the first vehicle
    Xa = [Pa(:,7),Va(:,7)]; % own expected behavior, passed to the next car
    Xnfa = [Pa(:,6) - d, Va(:,6)]; % 1: It is the state of the previous moment
    Xnffa = [Pa(:,5) - 2*d, Va(:,5)];
    
    u0 = ua(:,7); % starting search point
    A = [];b = []; Aeq = []; beq = []; % No linear constraints
    lb = Torquebound(7,1)*ones(Np,1); ub = Torquebound(7,2)*ones(Np,1); % upper and lower bounds of control volume
    Pnp = (Xnfa(end,1) + Xnffa(end,1))/2; Vnp = (Xnfa(end,2) + Xnffa(end,2))/2; % terminal constraints
    Xend(i,7) = Pnp; Vend(i,7) = Vnp; Tnp = (Ca(7)*Vnp.^2 + Mass(7)*g*f)/Eta*R(7);
    % MPC optimization solution
    [u, Cost(i,7), Exitflg(i,7), output] = fmincon(@(u) Costfunction1( Np, Tim_step, X0 ,u, Vehicle_Type,Q3,Xdes,R3,F3,Xa,G3, Xnfa,Xnffa), ...
        u0, A, b, Aeq, beq, lb, ub, @(u) Nonlinearconstraints(Np, Tim_step, X0, u, Vehicle_Type,Pnp,Vnp,Tnp),options);
    
    % The vehicle takes one step forward
    U(i,7) = u(1);
    [Postion(i,7),Velocity(i,7),Torque(i,7)] = VehicleDynamic(U(i,7),Tim_step,Postion(i-1,7),Velocity(i-1,7 ),Torque(i-1,7),Mass(7),R(7),g,f,Eta,Ca(7),Tao(7));
    
    % What needs to be noted here is that the assumed state of the next stage predicts the state of Np itself at time t + 1.
    Temp = zeros(Np + 1,3);
    Temp(1,:) = [Postion(i,7),Velocity(i,7),Torque(i,7)];
    ua(1:Np-1,7) = u(2:Np);
    for j = 1:Np-1
        [Temp(j + 1,1),Temp(j + 1,2),Temp(j + 1,3)] = VehicleDynamic(ua(j,7),Tim_step,Temp(j,1),Temp(j ,2),Temp(j,3),Mass(7),R(7),g,f,Eta,Ca(7),Tao(7));
    end

    ua(Np,7) = (Ca(7)*Temp(Np,2).^2 + Mass(7)*g*f)/Eta*R(7);
    [Temp(Np + 1,1),Temp(Np + 1,2),Temp(Np + 1,3)] = VehicleDynamic(ua(Np,7),Tim_step,Temp(Np,1),Temp(Np ,2),Temp(Np,3),Mass(7),R(7),g,f,Eta,Ca(7),Tao(7));
    Pa_next(:,7) = Temp(:,1);
    Va_next(:,7) = Temp(:,2);

    toc

    
    %% Exchange data matrix with new one
    Pa = Pa_next;
    Va = Va_next;
       
end

3 References

Some content in the article is quoted from the Internet, and the source will be indicated or cited as a reference. It is inevitable that there will be some unfinished information. If there is anything inappropriate, please feel free to contact us to delete it.

4 Matlab code, data, articles