Tilting rotorcraft control method based on neural network fitting null space
By using a neural network to fit zero space method in the tilt rotorcraft control system, combined with the FD and QP methods, the problems of low stability of the control system and saturation of the actuator in the prior art are solved, and higher control accuracy and robustness are achieved.
Patent Information
- Application Number
- CN202510213596.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-26
- Publication Date
- 2025-05-30
AI Technical Summary
The existing tilt rotor aircraft control technology has problems such as high structural weight, low control system stability, and inability to deal with actuator saturation, especially when it is difficult to maintain a stable attitude during high-speed flight and high-frequency operation.
The control method based on neural network fitting zero space is adopted, combined with the FD method and the QP method, and the FD algorithm is run at high frequency and the QP algorithm is run at low frequency for compensation. The part of the convex optimization problem is fitted with a simple neural network to improve control accuracy and robustness.
It achieves higher control accuracy and robustness, avoids the problems of drones diverging and out of control at the singularity, and can use the actuator tension more evenly and rationally, reducing the risk of actuator saturation.
Smart Images

Figure CN120065734A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of tilt-rotor aircraft control, and in particular to a tilt-rotor aircraft control method based on neural network fitting null space. Background Art
[0002] A tilt-rotor aircraft is a new type of aircraft that has both the vertical takeoff and landing and hovering functions of a helicopter and the high-speed flight ability of a fixed-wing aircraft. The tilt-rotor aircraft has the technical characteristics of high speed and long range, as well as good economy, and has become the main development direction of military and civilian rotorcraft.
[0003] At present, most of the existing tilt-rotor aircraft use the tilt servo method to achieve control. The tilt servo method has the following disadvantages:
[0004] (1) It has additional structural weight. If there are more rotors, multiple tilt servos are also required, resulting in high costs. (2) The rotor needs to be tilted by the servo, and at the same time, the overall structure needs to maintain a certain stiffness, which requires high structural strength and a high structural redundancy.
[0005] (3) The power supply voltage of the tilt servo is often different from that of the motor, and an additional power supply module is required for power supply, resulting in redundancy.
[0006] (4) The motor thrust axis needs to be as close as possible to the tilt axis. Otherwise, a very large torque servo is required to counteract the torque generated by the motor, which imposes additional restrictions on the layout design of the rotorcraft. (5) The tilt servo resists the resistance and gyroscopic torque to tilt the high-speed rotating motor, which will generate an anti-torque. Such an anti-torque increases the difficulty and burden of the control system.
[0007] (6) The tilt angle is limited by the tilt servo stroke, which limits its flexibility and also increases the constraint conditions in the controller.
[0008] In addition, in the prior art during the control process, the pseudo-inverse method is usually used to solve the control allocation matrix. Such a method is prone to divergence at singularities and has low control stability. And it cannot handle any input constraints, such as actuator saturation problems. Summary of the Invention
[0009] Aiming at the deficiencies of the prior art, the present invention provides a tilt-rotor aircraft control method based on neural network fitting null space. The present invention proposes a control method with higher accuracy and stronger robustness against actuator saturation. The present invention combines the advantages of the FD method and the QP method, runs the FD algorithm at a high frequency for solution while running the QP algorithm at a lower frequency for compensation, and fits the part of the convex optimization problem solution with a simple neural network.
[0010] The technical solution of the present invention is as follows: A control method for a tilt-rotor aircraft based on neural network fitting of the null space, comprising the following steps:
[0011] S1), establish the dynamic model of the tilt-rotor aircraft actuator;
[0012] S2), establish the translational and rotational dynamic models of the entire tilt-rotor aircraft;
[0013] S3), design the upper controller in a hierarchical control manner;
[0014] S4), construct a control allocation strategy based on a simple neural network and the null space, combine the advantages of the FD method and the QP method, while solving the FD algorithm at high frequency, run the QP algorithm at a lower frequency for compensation, and fit the part of the convex optimization problem solution with a simple neural network.
[0015] Preferably, in step S1), the actuator includes four thruster groups, each thruster group includes two thrusters, and each can be tilted independently. Therefore, the dynamic model of the i-th arm is expressed as:
[0016]
[0017] Wherein, represents the first derivative of ; is the attitude of the i-th arm in the world coordinate system ; is the attitude of the i-th arm in the stationary coordinate system ; ω i is the angular velocity of the i-th arm in the rotating coordinate system , ω i = [0, ω i , 0]; ∧ represents converting a vector into its corresponding skew-symmetric matrix; is the skew-symmetric matrix of the angular velocity ω i ; R wB is the rotation matrix from the body coordinate system to the world coordinate system ; represents the rotation matrix from the i-th stationary coordinate system to the body coordinate system; J a is the moment of inertia of the arm rotating around the joint; τ i is the torque generated by the two rotors acting on the i-th arm;
[0018] The thrust f of the i-th arm in the stationary coordinate system i a is expressed as:
[0019]
[0020] where f i B is the thrust of the i-th arm in the body coordinate system; T represents the transpose operation;
[0021] Therefore, the control efficiency model of the i-th arm is expressed as:
[0022]
[0023] where t i1 and t i2 are the thrusts generated by the two rotors of the i-th arm respectively; l represents the distance from the center of the cantilever to the center of the rotor.
[0024] Preferably, in step S2), the translational dynamics model of the whole tilt-rotor aircraft is expressed as:
[0025]
[0026] where represents the second derivative of the position of the origin O of the body coordinate system B in the world coordinate system to be P; R ∈ SO(3) is the attitude of the body coordinate system relative to the world coordinate system , SO(3) represents the rotation group; g = [0, 0, -g] T is the gravitational acceleration in the world coordinate system ; m is the total mass of the tilt-rotor aircraft; F B is the three-axis desired thrust of the virtual control input.
[0027] Preferably, in step S2), the rotational dynamics model of the tilt-rotor aircraft is expressed as:
[0028]
[0029] where represents the moment of inertia of the whole tilt-rotor aircraft; M B is the three-axis torque; represents the first derivative of the attitude R; represents the skew-symmetric matrix corresponding to ω, ∧ is an operator indicating finding the corresponding skew-symmetric matrix of the following matrix; represents the first derivative of ω; ω = [ω x , ω y , ω z T represents the angular velocity in the body coordinate system ;
[0030] For each robotic arm, the position of the center of its rotating joint is expressed as:
[0031]
[0032] where r i represents the position of the center of the i-th robotic arm's rotating joint; L represents the length of the robotic arm; h represents the distance from the origin of the stationary coordinate system to the center of gravity of the tiltrotor aircraft in the vertical direction;
[0033] Therefore, by using the thrust f i B of the i-th robotic arm in the body coordinate system i and its position r B of the center of its rotating joint to represent the three-axis desired thrust F B and the three-axis moment M
[0034]
[0035] Preferably, in step S3), a hierarchical control method is adopted to design the upper controller, which specifically includes the following steps:
[0036] S31) Design the position and attitude controller
[0037] By taking the defined virtual position input and virtual attitude input [u P , u A as the new control inputs, where:
[0038]
[0039] where F B , M B are the three-axis desired thrust and three-axis moment respectively; m is the total mass of the tiltrotor aircraft; is a positive definite inertia matrix; g = [0, 0, -g] T is the gravitational acceleration in the world coordinate system; ω = [ω x , ω y , ω z T represents the angular velocity in the body coordinate system; R T is the transpose matrix of the attitude R; u P is the defined virtual position input; u A is the defined virtual attitude input;
[0040] Substituting the above into the translational and rotational dynamics model of the tiltrotor aircraft, we get:
[0041]
[0042] S32), through feedback linearization, simplify the tilt-rotor aircraft control system into a cascade integral system, and design a PID controller, i.e.:
[0043]
[0044] where K P represents the positive definite diagonal gain matrix of the position loop; K R is the positive definite diagonal gain matrix of the attitude loop; P d , R d respectively represent the desired position and desired attitude automatically generated by the remote controller; v d , v respectively represent the desired speed and speed; P, R respectively represent the position and attitude of the tilt-rotor aircraft; respectively represent the PID parameters of the speed loop; ω d , ω respectively represent the desired angular velocity and angular velocity; respectively represent the PID parameters of the angular velocity loop;
[0045] S33), substitute [u P , u A back into equation (8) to calculate the three-axis desired thrust F B and the three-axis moment M B , and further map them to the thrust f i B ; Expand the control efficiency equation into matrix form:
[0046]
[0047] where is the control efficiency matrix; I 3×3 represents the 3×3 identity matrix; represents the skew-symmetric matrix of the position of the center of the i-th arm rotating joint;
[0048] S34), since the thruster group of the octocopter platform can only rotate around the arm, the generated thrust must be perpendicular to the arm. Therefore, reduce the dimension of the control efficiency matrix Q through the dimensionality reduction matrix E; that is:
[0049]
[0050] where is the control effectiveness matrix after dimensionality reduction;
[0051] Therefore, the control efficiency matrix Q can be solved as:
[0052]
[0053] where f BIt represents the representation of the thrust generated by the arm on the tilt-rotor aircraft in the body coordinate system; It represents f B 's normalized vector;
[0054] S35), according to the in Equation (2), so as to convert f B into the thrust f of the arm in the stationary coordinate system a , and then according to f a and the current attitude R in the world coordinate system; calculate the desired attitude in the world coordinate system; by using the Rodriguez rotation formula to calculate the rotation of the rotatable frame relative to the static frame, that is:
[0055]
[0056] In the formula, represents the rotation matrix from the dynamic coordinate system to the static coordinate system; represents a i 's skew-symmetric matrix; represents the tilt angle of the i-th group of thruster groups; b i =||a i ||; c i =[0,0,1]; is the normalized vector of f i r ; f i r represents the representation of the pulling force generated by the arm on the whole tilt-rotor aircraft in the stationary coordinate system;
[0057] S36), convert to the world coordinate system, that is:
[0058]
[0059] In the formula, R represents the attitude of the body coordinate system relative to the world coordinate system ; represents the rotation matrix from the stationary coordinate system to the body coordinate system; represents the rotation matrix from the rotating coordinate system to the world coordinate system;
[0060] S37), take the calculated and ||f i a || as inputs and send them to the sub-controller of the thruster group to calculate the desired tilt angular velocity; that is:
[0061]
[0062] In the formula, R iDenote the attitude measured by the sub - controller of the $i$-th thruster group; $K$ i is the positive definite diagonal gain matrix of the sub - controller of the $i$-th thruster group; Denote the expected angular velocities of the three axes respectively; $\vee$ represents the inverse operation of $\wedge$;
[0063] Use the expected angular velocity of the $y$-axis Calculate the expected tilt angle That is:
[0064]
[0065] In the formula; are the PID parameters respectively; is the pitch angular velocity of the $y$-axis measured by the sub - controller of the $i$-th thruster group;
[0066] Substitute the expected tilt angle Back - substitute into the control efficiency model of the arm in Equation (3) to calculate the thrust of each rotor within the thruster group:
[0067]
[0068] In the formula, $t$ i1 and $t$ i2 are the thrusts generated by the two rotors of the $i$-th arm respectively; $l$ represents the distance from the center of the cantilever to the center of the rotor; is the expected tilt angle; $f$ i B is the thrust of the $i$-th arm in the body coordinate system;
[0069] Convert the calculated thrust into the actual throttle signal through the thrust - throttle mapping relationship.
[0070] Preferably, in step S4), it specifically includes the following steps:
[0071] S41), Construct the FD method and the QP problem;
[0072] S42), Construct the null - space problem;
[0073] S43), Use the neural network to fit the entire control allocation strategy;
[0074] Through offline calculation, obtain the output $Z$ corresponding to each expected control input $t$ d , $F(\alpha$ 0 , $T$ 0 ), and based on this data set, use a simple neural network to fit the entire null - space - based control allocation process into a matrix mapping from to .
[0075] Preferably, in step S41), constructing the FD method and the QP problem specifically includes the following steps:
[0076] S411), assume there is a three-axis desired thrust F B Rewrite it as F:
[0077] F = [F s1 F c1 …F s4 F c4 T ;
[0078] wherein, F si = sinα i f i B ; F ci = cosα i f i B ; α i represents the tilt angle of the i-th thruster group;
[0079] S412), rewrite the thrust f generated by the thrusters on the whole tiltrotor aircraft as B Rewrite it as Then there is:
[0080]
[0081] In the formula, t d represents the desired control input; J p represents the parameter matrix; J R represents the parameter matrix; is the control efficiency matrix after dimension reduction;
[0082] wherein,
[0083] S413), use the null space matrix to calculate F, that is:
[0084]
[0085] In the formula, represents the pseudo-inverse matrix of the control efficiency matrix; N M represents the null space matrix of the control efficiency matrix M after dimension reduction; Z represents an arbitrary vector;
[0086] When Z is an arbitrary vector, are all solutions of F; when solving by using the least squares method, Z = [0,0] T ; Therefore:
[0087]
[0088] Where, T i * represents the thrust generated by the i-th thruster group on the airframe;
[0089] S414) Assume that the actuator input is X = [T *T , α T . T , at the operating point [T *T , α T , T perform a first-order Taylor expansion to obtain:
[0090]
[0091] where, is the expression of the mapping relationship; α represents the tilt angle of the thruster group; s represents the relaxation factor;
[0092] Each calculated X is used as the new operating point for the next calculation;
[0093] S415) Construct the control allocation problem as a function, and limit the actuator by adding an inequality constraint to the quadratic programming problem; after calculating the increment ΔX, the actuator input can be obtained; where, the constructed function is:
[0094] J(ΔX, s) = ΔX T KΔX + s T Ds; (23)
[0095] In the formula, J represents the prefix of the mapping function; ΔX represents the increment; s represents the relaxation factor; K represents the parameter matrix; D represents the parameter matrix;
[0096] The said inequality constraint is:
[0097] X min - X 0 ≤ ΔX ≤ X max - X 0 ; (24 - 1)
[0098] ΔX min ≤ ΔX ≤ ΔX max ; (24 - 2)
[0099] In the formula, X min , X max are respectively the minimum and maximum values of the actual output range that the actuator can give; X 0 is the initial value of X; ΔX min , ΔX max are respectively X min - X 0 and X max - X 0;
[0100] Finally, the input of the actuator is: X = X 0 + ΔX.
[0101] Preferably, in step S42), a null space problem is constructed, which specifically includes the following steps:
[0102] S421), Combine the FD method and the QP method using the characteristics of the null space matrix, and expand F into an equality constraint, that is:
[0103]
[0104] Among them,
[0105] In the formula, Δα represents the angle increment; ΔT * represents the thrust increment;
[0106] S422), Regard Z as a variable to construct a new QP problem, and its objective function is:
[0107] J(ΔX, s, Z) = ΔX T KΔX + s T Ds + Z T UZ; (26)
[0108] In the formula, Z T represents the transpose of Z; Z represents an arbitrary vector; U represents a parameter matrix;
[0109] S423), Construct the equality constraint and inequality constraint of the objective function of the new QP problem, that is: Equality constraint:
[0110]
[0111] Inequality constraint:
[0112] X min -X 0 ≤ ΔX ≤ X max -X 0 ; (24 - 1)
[0113] S424), Organize steps S422) and S423) into the standard QP problem form, that is:
[0114] Objective function:
[0115]
[0116] In the formula;
[0117] S425) Solve step S24) to obtain ΔX;
[0118] Let Z * only related to the null space matrix N M which can be solved and added as a compensation term Due to the characteristics of the null space matrix, when Z * is any value, it is a solution of F. Therefore, while solving at high frequency, calculate Z at low frequency * and add it as a compensation term.
[0119] The beneficial effects of the present invention are as follows:
[0120] 1. The present invention can keep the UAV in a stable attitude and avoid the problem of divergence and out-of-control of the UAV.
[0121] 2. The present invention can utilize the actuator pull more evenly and reasonably, avoiding the problem of truncation caused by excessive pull in a group reaching saturation and finally leading to divergence.
[0122] 3. By combining the advantages of the FD method and the QP method, the present invention runs the QP algorithm for compensation at a lower frequency while running the FD algorithm to solve at high frequency, and fits the part of the convex optimization problem solution with a simple neural network. BRIEF DESCRIPTION OF THE DRAWINGS
[0123] Figure 1 is a schematic flowchart of the method of the present invention;
[0124] Figure 2 is a schematic diagram of the coordinate system of the tilt-rotor aircraft established in the embodiment of the present invention;
[0125] Figure 3 is a schematic diagram of the simulation result in the matlab simscape platform in the embodiment of the present invention Figure 1 ;
[0126] Figure 4 is a schematic diagram of the simulation result in the matlab simscape platform in the embodiment of the present invention Figure 2 ; DETAILED DESCRIPTION OF THE INVENTION
[0127] The following further describes the specific embodiments of the present invention with reference to the drawings:
[0128] This embodiment provides a tilt-rotor aircraft control method based on neural network fitting of the null space, as Figure 2 shown; this embodiment establishes the coordinate system of the tilt-rotor aircraft, where the world coordinate system adopts the NED coordinate system, and the body coordinate system Denoted by the letter B, x i y i z i is the joint rotation coordinate system is the static coordinate system The joint rotation coordinate system tilts with the cantilever, and the static coordinate system keeps its direction unchanged. As Figure 1 shown, the method specifically includes the following steps:
[0129] S1), establish the dynamic model of the actuator of the tiltrotor aircraft;
[0130] In this embodiment, the actuator includes four thruster groups, and each thruster group includes two thrusters, both of which can be tilted independently. Therefore, the dynamic model of the i-th arm is expressed as:
[0131]
[0132] wherein, denotes the first derivative of with respect to; is the attitude of the i-th arm in the world coordinate system ; is the attitude of the i-th arm in the static coordinate system ; ω i is the angular velocity of the i-th arm in the rotating coordinate system , ω i =[0, ω i , 0]; ∧ means converting the vector into its corresponding skew-symmetric matrix; is the skew-symmetric matrix of the angular velocity ω i ; R wB is the rotation matrix from the body coordinate system to the world coordinate system ; represents the rotation matrix from the i-th static coordinate system to the body coordinate system; J a is the moment of inertia of the arm rotating around the joint; τ i is the torque generated by the two rotors acting on the i-th arm;
[0133] The thrust f of the i-th arm in the static coordinate system i a is expressed as:
[0134]
[0135] In the formula, f i BThe thrust of the i-th arm in the body coordinate system; T represents the transpose operation;
[0136] Therefore, the control efficiency model of the i-th arm is expressed as:
[0137]
[0138] In the formula, t i1 and t i2 are the thrusts generated by the two rotors of the i-th arm respectively; l represents the distance from the center of the cantilever to the center of the rotor.
[0139] S2) Establish the translational and rotational dynamics models of the whole tilt-rotor aircraft;
[0140] In this embodiment, let the origin O of the body coordinate system B be located at P = [x, y, z] in the world coordinate system ; The translational dynamics model of the whole tilt-rotor aircraft is expressed as: T ; In the formula,
[0141]
[0142] represents the second derivative of the position of the origin O of the body coordinate system at P in the world coordinate system B ; R is the attitude of the body coordinate system relative to the world coordinate system ; g = [0, 0, -g] is the gravitational acceleration in the world coordinate system T ; m is the total mass of the tilt-rotor aircraft; F is the three-axis expected thrust of the virtual control input. B
[0143] In this embodiment, the rotational dynamics model of the tilt-rotor aircraft is expressed as:
[0144]
[0145] In the formula, represents the moment of inertia of the whole tilt-rotor aircraft; M B is the three-axis moment; represents the first derivative of the attitude R; represents the skew-symmetric matrix corresponding to ω, and ∧ is an operator indicating to find the corresponding skew-symmetric matrix of the following matrix; The tilt-rotor aircraft represents the first derivative of ω; ω = [ω x , ω y , ω z T Indicates the angular velocity in the body coordinate system ;
[0146] For each arm, the position of the center of its rotating joint is expressed as:
[0147]
[0148] In the formula, r i represents the position of the center of the rotating joint of the i-th arm; L represents the arm length; h represents the distance from the origin of the stationary coordinate system to the center of gravity of the whole tilt-rotor aircraft in the vertical direction;
[0149] Therefore, by using the thrust f i B of the i-th arm in the body coordinate system i and the position r B of its rotating joint center to represent the three-axis desired thrust F B and the three-axis moment M
[0150]
[0151] S3), Design the upper controller in a hierarchical control manner; specifically, it includes the following steps:
[0152] S31), Design the position and attitude controller
[0153] By taking the defined virtual position input and virtual attitude input [u P , u A as the new control inputs, where:
[0154]
[0155] In the formula, F B , M B are the three-axis desired thrust and three-axis moment respectively; m is the total mass of the tilt-rotor aircraft; is the positive definite inertia matrix; g = [0, 0, -g] T is the gravitational acceleration in the world coordinate system; ω = [ω x , ω y , ω z T represents the angular velocity in the body coordinate system; R T is the transpose matrix of the attitude R; u P is the defined virtual position input; u A is the defined virtual attitude input;
[0156] Substitute the above into the translational and rotational dynamics models of the tilt-rotor aircraft in equations (4) and (5), and we get:
[0157]
[0158] S32), through feedback linearization, simplify the tilt-rotor aircraft control system into a cascade integral system and design a PID controller, that is:
[0159]
[0160] In the formula, K P represents the positive definite diagonal gain matrix of the position loop; K R is the positive definite diagonal gain matrix of the attitude loop; P d , R d respectively represent the desired position and desired attitude automatically generated by the remote controller; v d , v respectively represent the desired speed and speed; P, R respectively represent the current position and attitude of the tilt-rotor aircraft; respectively represent the PID parameters of the speed loop; ω d , ω respectively represent the desired angular velocity and angular velocity; respectively represent the PID parameters of the angular velocity loop;
[0161] S33), substitute [u P , u A in Equation (10) back into Equation (8) to calculate the three-axis desired thrust F B and the three-axis moment M B , and further map them to the thrust f i B ; Expand the control efficiency equation into matrix form:
[0162]
[0163] Among them, is the control efficiency matrix; I 3×3 represents a 3×3 identity matrix; represents the skew-symmetric matrix of the position of the center of the i-th arm rotating joint;
[0164] S34), since the thruster group of the octocopter platform can only rotate around the arm, the generated thrust must be perpendicular to the arm. Therefore, reduce the dimension of the control effectiveness matrix Q through the reduction matrix E; that is:
[0165]
[0166] In the formula, is the control effectiveness matrix after dimension reduction;
[0167] Therefore, the control efficiency matrix can be solved as:
[0168]
[0169] In the formula, f B represents the thrust generated by the arm on the whole tilt-rotor aircraft in the body coordinate system; represents the normalized vector of f B ;
[0170] S35), according to the in formula (2), the obtained f B is converted into the thrust f a of the arm in the static coordinate system, and then according to f a and the current attitude R in the world coordinate system; calculate the desired attitude in the world coordinate system; in this embodiment, the rotation of the rotatable frame relative to the static frame is calculated by using the Rodriguez rotation formula, that is:
[0171]
[0172] In the formula, represents the rotation matrix from the rotating coordinate system to the static coordinate system; represents the i skew-symmetric matrix of a; represents the tilt angle of the i-th group; b i = ||a i ||; c i = [0, 0, 1]; is the normalized vector of f i r ; f i r represents the tensile force generated by the arm on the whole tilt-rotor aircraft in the static coordinate system;
[0173] S36), convert to the world coordinate system, that is:
[0174]
[0175] In the formula, R represents the attitude of the body coordinate system relative to the world coordinate system ; represents the rotation matrix from the static coordinate system to the body coordinate system; represents the rotation matrix from the rotating coordinate system to the world coordinate system;
[0176] S37), take the calculated and ||f i a || as inputs and send them to the sub-controller of the thruster group to calculate the desired tilt angular velocity; that is:
[0177]
[0178] wherein, R i represents the attitude measured by the sub - controller of the i - th thruster group; K i is the positive definite diagonal gain matrix of the sub - controller of the i - th thruster group; respectively represent the expected angular velocities of the three axes; ∨ represents the inverse operation of ∧;
[0179] Using the on the y - axis to calculate the expected tilt angle That is:
[0180]
[0181] wherein; are the PID parameters respectively; is the pitch angular velocity of the y - axis measured by the sub - controller of the i - th thruster group;
[0182] Substitute the expected tilt angle back into the control efficiency model of the arm in Equation (3) to calculate the thrust of each rotor within the thruster group:
[0183]
[0184] wherein, t i1 and t i2 are the thrusts generated by the two rotors of the i - th arm respectively; l represents the distance from the center of the cantilever to the center of the rotor; is the expected tilt angle; f i B is the thrust of the i - th arm in the body coordinate system;
[0185] Convert the calculated thrust into the actual throttle signal through the thrust - throttle mapping relationship.
[0186] S4) Construct a control allocation strategy based on a simple neural network and the null space, combine the advantages of the FD method and the QP method, run the QP algorithm at a lower frequency for compensation while running the FD algorithm for solution at a high frequency, and fit the part of the convex optimization problem solution with a simple neural network, specifically including the following steps:
[0187] S41) Construct the FD method and the QP problem; specifically including the following steps:
[0188] S411) Assume that there is a three - axis expected thrust F B Rewrite it as F:
[0189] F = [F s1 F c1 …F s4 F c4 T ;
[0190] Among them, F si = sinα i f i B ; F ci = cosα i f i B ; α i represents the tilt angle of the i-th thruster group;
[0191] S412), rewrite the thrust f generated by the thruster on the whole tilt-rotor aircraft B as Then there is:
[0192]
[0193] In the formula, t d represents the desired control input; J p represents the parameter matrix; J R represents the parameter matrix; is the control efficiency matrix after dimension reduction;
[0194] Among them,
[0195] S413), calculate F using the null space matrix, that is:
[0196]
[0197] In the formula, represents the pseudo-inverse matrix of the control efficiency matrix; N m represents the null space matrix of the control efficiency matrix M after dimension reduction; Z represents an arbitrary vector; is the control efficiency matrix after dimension reduction;
[0198] For the tilt-rotor aircraft of this embodiment, its control efficiency matrix after dimension reduction and is a row full-rank matrix, so its null space matrix can be obtained as So Due to the characteristics of the null space matrix, when Z is an arbitrary vector, are all solutions of F; when solving by using the least squares method, Z = [0, 0] T ; Therefore:
[0199]
[0200] In the formula, T i * represents the thrust generated by the i-th thruster group on the tilt-rotor aircraft body;
[0201] S414), let the input of the actuator be \(X = [T *T ,α T T , at the operating point \([T *T ,α T T perform a first-order Taylor expansion to obtain:
[0202]
[0203] where, is the expression of the mapping relationship; α represents the tilt angle of the thruster group; s represents the relaxation factor;
[0204] Each calculated \(X\) is used as the new operating point for the next calculation;
[0205] S415), construct the control allocation problem as a function and implement the amplitude limiting of the actuator by adding an inequality constraint to the quadratic programming problem; after calculating the increment \(\Delta X\), the actuator input can be obtained; where, the constructed function is:
[0206] \(J(\Delta X,s)=\Delta X T P\Delta X + s T Rs\); (23)
[0207] In the formula, \(J\) represents the prefix of the mapping function; \(\Delta X\) represents the increment; s represents the relaxation factor; \(K\) represents the parameter matrix; \(D\) represents the parameter matrix;
[0208] The said inequality constraint is:
[0209] \(X min -X 0 \leq\Delta X\leq X max -X 0 ; (24 - 1)
[0210] \(\Delta X min \leq\Delta X\leq\Delta X max ; (24 - 2)
[0211] In the formula, \(X min \), \(X max \) are respectively the minimum and maximum values of the actual output range that the actuator can give; \(X 0 \) is the initial value of \(X\); \(\Delta X min \), \(\Delta X max \) are respectively \(X min -X 0 \) and \(X max -X 0 ;
[0212] Finally, the actuator input obtained is: \(X = X 0 +\Delta X\).
[0213] S42), Construct the null space problem; specifically including the following steps:
[0214] S421), Combine the FD method and the QP method using the null space matrix property, and expand F into an equality constraint, that is:
[0215]
[0216] Where,
[0217] In the formula, Δα represents the angle increment; ΔT * represents the thrust increment;
[0218] S422), Construct a new QP problem by regarding Z as a variable, and its objective function is:
[0219] J(ΔX, s, Z) = ΔX T PΔX + s T Rs + Z T UZ; (26)
[0220] In the formula, Z T represents the transpose of Z; Z represents an arbitrary vector; U represents a parameter matrix; P represents the current position of the tiltrotor aircraft;
[0221] S423), Construct the equality constraint and inequality constraint of the objective function of the new QP problem, that is:
[0222] Equality constraint:
[0223]
[0224] Inequality constraint:
[0225] X min -X 0 ≤ ΔX ≤ X max -X 0 ; (24 - 1)
[0226] S424), Organize steps S422) and S423) into the standard QP problem form, that is:
[0227] Objective function:
[0228]
[0229]
[0230] In the formula;
[0231] S425), solving step S24) can obtain ΔX;
[0232] Let Z * only related to the null space matrix N M and can be solved and added as a compensation term Due to the characteristics of the null space matrix, when Z * is any value, it is a solution of F. Therefore, while solving at high frequency, calculate Z * at low frequency and add it as a compensation term.
[0233] S43), adopt the entire control allocation strategy of the neural network for fitting;
[0234] By offline calculating the output Z corresponding to each input t d , F(α 0 , T 0 ), and based on this data set, fit the entire null space-based control allocation process into a matrix mapping from to through a simple neural network.
[0235] In this embodiment, the neural network has 2 hidden layers, and the number of nodes in each layer is 48.
[0236] This embodiment conducts a simulation experiment on the matlab simscape platform. As Figure 3 shown, by comparing the attitude maintenance at the singularity, it can be found that the conventional method UAV diverges and leads to out-of-control, but the UAV of this embodiment maintains attitude stability; as Figure 4 shown, by observing the pulling force of the power group, it can be found that this embodiment can utilize the pulling force of the actuator more evenly and reasonably, while the general method will cause one group of pulling forces to be too large and reach saturation, resulting in truncation and ultimately divergence.
[0237] The above embodiments and the descriptions in the specification only illustrate the principles and the best embodiments of the present invention. Without departing from the spirit and scope of the present invention, the present invention will have various changes and improvements, and these changes and improvements all fall within the scope of the present invention claimed.
Claims
1. A tiltrotor control method based on neural network fitting null space, characterized in that: The steps include: S1), establishing a dynamic model of the actuator of the tiltrotor aircraft; S2) Establishing the translational and rotational dynamics model of the tiltrotor aircraft; S3) Design the upper controller by adopting hierarchical control method; S4) Construct a control allocation strategy based on a simple neural network and null space, combining the advantages of the FD method and the QP method, running the FD algorithm at a high frequency while running the QP algorithm at a lower frequency for compensation, and fitting the part of the convex optimization problem solved with a simple neural network.
2. A tiltrotor control method based on neural network fitting null space according to claim 1, characterized in that: In step S1), the actuator of the tiltrotor aircraft includes four propeller groups, each of which includes two propellers, and can be tilted independently. Therefore, the dynamic model of the i-th arm is expressed as: in, Express Find the first derivative; is the position of the i-th arm in the world coordinate system The posture in is the position of the i-th arm in the stationary coordinate system The posture in i is the i-th arm in the rotating coordinate system The angular velocity in i =[0,ω i ,0]; ∧ means converting the vector into its corresponding skew-symmetric matrix; is the angular velocity ω i is a skew-symmetric matrix; R wB The body coordinate system To world coordinate system The rotation matrix of represents the rotation matrix from the i-th stationary coordinate system to the body coordinate system; J a is the moment of inertia of the arm rotating around the joint; τ i is the torque generated by the two rotors acting on the i-th arm; The thrust f of the i-th arm in the stationary coordinate system i a It is expressed as: In the formula, f i B is the thrust of the i-th arm in the body coordinate system; T represents the transposition operation; Therefore, the control efficiency model of the i-th arm is expressed as: Where, t i1 and t i2 are the thrusts generated by the two rotors of the i-th arm; l represents the distance from the center of the arm to the center of the rotor.
3. A tiltrotor control method based on neural network fitting null space according to claim 2, characterized in that: In step S2), the translational dynamics model of the tiltrotor aircraft is expressed as: In the formula, Represents the body coordinate system Origin O B In the world coordinate system The current position of the tiltrotor is P, and the second derivative is obtained; R∈SO(3) is the body coordinate system Relative to the world coordinate system The posture of SO(3) is the rotation group; g = [0,0,-g] T The world coordinate system The gravitational acceleration in the figure; m is the total mass of the tiltrotor; F B It is the three-axis desired thrust input for virtual control.
4. The tiltrotor control method based on neural network fitting null space according to claim 3, characterized in that: In step S2), the rotational dynamics model of the tiltrotor aircraft is expressed as: In the formula, Represents the moment of inertia of the tiltrotor aircraft; M B is the triaxial moment; It means to find the first-order derivative of the posture R; represents the antisymmetric matrix corresponding to ω, ∧ is an operator, which means to find the corresponding antisymmetric matrix of the following matrix; It means to find the first-order derivative of ω; ω=[ω x ,ω y ,ω z ] T Represents the body coordinate system Angular velocity in For each arm, the position of the rotation joint center is expressed as: In the formula, r i represents the position of the center of rotation joint of the i-th arm; L represents the length of the arm; h represents the distance from the origin of the stationary coordinate system to the center of gravity of the tiltrotor in the vertical direction; Therefore, by using the thrust f of the i-th arm in the body coordinate system i B and the position of the center of its revolute joint r i To express the expected thrust F of the three axes B and the three-axis moment M B ,Right now:
5. The tiltrotor control method based on neural network fitting null space according to claim 4, characterized in that: In step S3), the upper controller is designed by adopting a hierarchical control method, which specifically includes the following steps: S31) Design position and attitude controller By defining the virtual position input and virtual posture input [u P ,u A ] as the new control input, where: In the formula, F B 、M B are the expected thrust and torque of three axes respectively; m is the total mass of the tiltrotor; is the positive definite inertia matrix; g = [0,0,-g] T is the gravitational acceleration in the world coordinate system; ω=[ω x ,ω y ,ω z ] T Represents the angular velocity in the body coordinate system; R T is the transposed matrix of the current attitude R of the tiltrotor; u P Input quantity for the defined virtual position; u A Input quantity for the defined virtual pose; Substituting the above into the translational and rotational dynamics model of the tiltrotor aircraft, we obtain: In the formula, Represents the body coordinate system Origin O B In the world coordinate system The current position of the tiltrotor aircraft is P, and the second derivative is obtained; Represents the body coordinate system Relative to the world coordinate system Take the derivative of the current posture R.
6. A tiltrotor control method based on neural network fitting null space according to claim 5, characterized in that: Step S3) also includes the following steps: S32), through feedback linearization, the tilt-rotor aircraft control system is simplified to a cascade integral system, and a PID controller is designed, namely: In the formula, K P represents the positive definite diagonal gain matrix of the position loop; K R is the positive definite diagonal gain matrix of the attitude loop; p d , R d They represent the expected position and expected posture automatically generated by the remote controller; v d , v represent the desired speed and current speed respectively; P, R represent the current position and attitude of the tiltrotor aircraft respectively; Respectively represent the PID parameters of the speed loop; ω d , ω represent the expected angular velocity and the current angular velocity respectively; They represent the PID parameters of the angular velocity loop respectively; S33), replace [u P ,u A ] Substitute it back into formula (8) to calculate the expected thrust F of the three axes B and the three-axis moment M B , and further mapped to thrust f i B ; Expand the control efficiency equation into matrix form: in, is the control efficiency matrix; I 3×3 Represents the 3*3 identity matrix; The antisymmetric matrix representing the position of the center of rotation joint of the i-th arm; S34), since the propeller group of the eight-rotor platform can only rotate around the arm, the thrust generated must be perpendicular to the arm. Therefore, the dimension of the control efficiency matrix Q is reduced by the dimension reduction matrix E; that is: In the formula, is the control effectiveness matrix after dimension reduction; Therefore, the control efficiency matrix Q can be solved as: In the formula, f B It represents the thrust generated by the arm on the tilt-rotor aircraft in the body coordinate system; represents f B The normalized vector of ; S35), according to formula (2) Thus, f B Converted into the thrust f of the arm in the stationary coordinate system a , then according to f a and the current pose R in the world coordinate system; calculate the desired pose in the world coordinate system; calculate the rotation of the rotatable frame relative to the static frame by using the Rodriguez rotation formula, that is: In the formula, Represents the rotation from the dynamic coordinate system to the static coordinate system; Indicates a i The antisymmetric matrix of ; represents the tilt angle of the i-th thruster group; b i =||a i ||;c i = [0,0,1]; f i r The normalized vector of i r It represents the pulling force generated by the arm on the tiltrotor aircraft in the stationary coordinate system; S36) Convert to the world coordinate system, that is: In the formula, R represents the body coordinate system Relative to the world coordinate system Current posture; Represents the rotation matrix from the stationary coordinate system to the body coordinate system; Represents the rotation matrix from the rotated coordinate system to the world coordinate system.
7. The tiltrotor control method based on neural network fitting null space according to claim 6, characterized in that: Step S3) also includes the following steps: S37), the calculated and is fed as input to the thruster group subcontroller to calculate the desired bank angular velocity; that is: In the formula, R i represents the attitude measured by the sub-controller of the i-th thruster group; K i is the positive definite diagonal gain matrix of the ith thruster group sub-controller; They represent the desired angular velocities of the three axes respectively; ∨ represents the inverse operation of ∧; Use the desired angular velocity on the y-axis Calculate the expected tilt angle Right now: Where: They are PID parameters respectively; is the y-axis pitch angular velocity measured by the sub-controller of the i-th thruster group; The desired tilt angle Substituting back into the control efficiency model of the arm in equation (3), the thrust of each rotor in the thruster group is calculated: In the formula, t i1 and t i2 are the thrusts generated by the two rotors of the i-th arm; l represents the distance from the center of the cantilever to the center of the rotor; is the desired tilt angle; f i i is the thrust of the i-th arm in the body coordinate system; The calculated thrust is converted into an actual throttle signal through the thrust-throttle mapping relationship.
8. The tiltrotor control method based on neural network fitting null space according to claim 7, characterized in that: Step S4) specifically includes the following steps: S41), construct FD method and QP problem; S42), constructing the null space problem; S43), using the neural network to fit the entire control allocation strategy; By offline calculating each desired control input t d , the output Z corresponding to F(α0,T0), and based on this data set, the entire control allocation process based on the null space is fitted into a simple neural network from arrive Matrix mapping.
9. The tiltrotor control method based on neural network fitting null space according to claim 8, characterized in that: In step S41), the FD method and the QP problem are constructed, which specifically includes the following steps: S411) Set the three-axis expected thrust F B Rewritten as F: F=[F s1 F c1 …F s4 F c4 ] T ; Among them, F si = sinα i f i B ; F ci =cosα i f i B ; α i represents the tilt angle of the i-th thruster group; S412), the thrust generated by the propeller on the tilt-rotor aircraft B Rewrite as Then we have: Where, t d represents the desired control input; J p represents the parameter matrix; J R represents the parameter matrix; is the control efficiency matrix after dimension reduction; in, S413), use the null space matrix to calculate F, that is: In the formula, represents the pseudo-inverse matrix of the control efficiency matrix; N M represents the null space matrix of the control efficiency matrix M after dimensionality reduction; Z represents an arbitrary vector; When Z is an arbitrary vector, are all solutions to F; when using the least squares method, Z = [0,0] T ;therefore: In the formula, represents the thrust generated by the i-th thruster group on the aircraft body; S414) Set the actuator input as X = [T *T ,α T ] T , at the working point [T *T ,α T ] T Performing a first-order Taylor expansion, we obtain: in, is the expression of the mapping relationship; α represents the tilt angle of the thruster group; s represents the relaxation factor; The X calculated each time is used as the new working point for the next calculation; S415), constructing the control allocation problem into a function, and implementing the limiting of the actuator by adding an inequality constraint to the quadratic programming problem; after calculating the increment ΔX, the actuator input can be obtained; wherein the constructed function is: J(ΔX,s)=ΔX T KΔX+s T Ds; (23) Where, J represents the prefix of the mapping function; ΔX represents the increment; s represents the relaxation factor; K represents the parameter matrix; D represents the parameter matrix; The inequality constraints are: X min -X0≤ΔX≤X max -X0;(24-1) ΔX min ≤ΔX≤ΔX max ;(24-2) Where, X min , X max are the minimum and maximum values of the actual output range that the actuator can provide; X0 is the initial value of X; ΔX min , ΔX max X min -X0 and X max -X0; Finally, the actuator input is: X=X0+ΔX.
10. The tiltrotor control method based on neural network fitting null space according to claim 9, characterized in that: In step S42), constructing the null space problem specifically includes the following steps: S421), using the null space matrix characteristics to combine the FD method with the QP method, and expand F into an equality constraint, that is: in, Where Δα represents the angle increment; ΔT * represents the thrust increment; S422), consider Z as a variable to construct a new QP problem, whose objective function is: J(ΔX,s,Z)=ΔX T KΔX+s T Ds+Z T UZ; (26) In the formula, Z T represents the transpose of Z; Z represents an arbitrary vector; U represents a parameter matrix; S423), construct the equality constraint and inequality constraint of the objective function of the new QP problem, that is: equality constraint: Inequality constraints: X min -X0≤ΔX≤X max -X0;(24-1) S424), steps S422) and S423) are organized into a standard QP problem form, namely: Objective function: Where; S425), solve step S24) to obtain ΔX; set up Z * Only with the null space matrix N M It can be solved and added as a compensation term Due to the null space matrix characteristics, Z * When is any value, are all solutions to F, so they can be solved with high frequency At the same time, the low frequency calculation Z * Added as compensation.