Lower limb rehabilitation robot control method and system based on IT2-FC, medium and equipment
By constructing an IT2-FC-based interval type fuzzy controller, combined with feedback linearization and LQR methods, the control problems of lower limb rehabilitation robots under individual differences and external environment uncertainty are solved, and more efficient and accurate motion control is achieved, improving the robustness and personalization of the system.
Patent Information
- Application Number
- CN202510354648.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-25
- Publication Date
- 2025-07-11
AI Technical Summary
The existing lower limb rehabilitation robot control methods are difficult to adapt to the large individual differences between patients and uncertainties in the external environment, resulting in insufficient adaptability and low control accuracy, which makes it difficult to meet the needs of refined motion control.
Using IT2-FC-based control method, an interval type 2 fuzzy controller was constructed, and combined with feedback linearization and LQR method, an interval type 2 fuzzy controller for hip and knee joints was designed. Fuzzy reasoning and fuzzy were performed through the down-center of mass and center of gravity method to achieve accurate motion control of lower limb rehabilitation robots.
It improves the personalized capabilities of the lower limb rehabilitation robot, enhances anti-interference ability and control accuracy, reduces computing complexity and sensor requirements, reduces system costs, and ensures that the expected motion trajectory can still be tracked in real time under individual patient differences and external disturbances.
Smart Images

Figure CN120295114A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of robot control, and in particular to a lower limb rehabilitation robot control method, system, medium and device based on IT2-FC. Background Art
[0002] With the continuous development of robot technology, lower limb rehabilitation robots have received extensive attention in the field of service robots. In the prior art, lower limb rehabilitation robots usually adopt preset trajectory control or simple feedback control strategies. The specific control methods mainly include: impedance control, adaptive control, neural network control, and bioelectrical signal control.
[0003] However, the existing lower limb rehabilitation robot control methods also have many limitations. Impedance control can automatically adjust the assistance force according to the user's intention, but the parameter adjustment is complex, and different optimizations are required for different patients, making it difficult to apply in the case of large individual differences among patients. Neural network control requires a large amount of data as support, needs to be retrained for different patients, has a large amount of calculation, and weak generalization ability; bioelectrical signal control is controlled by the patient's physiological signals, with complex signal processing, is easily affected by noise and external interference, and has weak anti-interference ability. In summary, the existing lower limb rehabilitation robot control methods are difficult to flexibly cope with individual differences of users and resist the uncertainty of the external environment, resulting in insufficient adaptability and low control accuracy of lower limb rehabilitation robots during the rehabilitation training process, and it is difficult to meet the more refined motion control requirements. Summary of the Invention
[0004] To this end, the technical problem to be solved by the present invention is to overcome the deficiencies in the prior art and provide a lower limb rehabilitation robot control method, system, medium and device based on IT2-FC, which can be applicable to the situation of large individual differences among patients, improve the anti-interference ability, and enhance the control accuracy.
[0005] To solve the above technical problem, the present invention provides a lower limb rehabilitation robot control method based on IT2-FC, including:
[0006] Construct an interval type-2 fuzzy controller and construct a feedback linearized lower limb rehabilitation robot system model;
[0007] Use the LQR method to find the optimal state feedback matrix of the system, and formulate the domain of the input and output of the controller in combination with the optimal state feedback matrix and the input and output of the interval type-2 fuzzy controller;
[0008] Divide the domain of the input and output of the controller, and construct the triangular membership functions of the input and output of the hip joint interval type-2 fuzzy controller and the triangular membership functions of the input and output of the knee joint interval type-2 fuzzy controller;
[0009] Construct the interval type-2 fuzzy control rules according to the input and output triangular membership functions of the hip joint interval type-2 fuzzy controller and the input and output triangular membership functions of the knee joint interval type-2 fuzzy controller;
[0010] Use the centroid defuzzification method to defuzzify the type-2 output fuzzy set inferred from the interval type-2 fuzzy control rules to obtain the interval range of the type-1 membership function in the type-2 membership function;
[0011] Use the center of gravity method to defuzzify the interval range of the type-1 membership function to obtain the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller, and simulate the movement trajectories of the hip joint and the knee joint according to the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller.
[0012] Furthermore, when constructing the interval type-2 fuzzy controller, construct a feedback linearized lower limb rehabilitation robot system model, specifically:
[0013] Construct the dynamic equation of the lower limb rehabilitation robot:
[0014]
[0015] Among them, M(θ) is the inertia matrix, is the lower limb joint angle, θ1 is the hip joint angle, and θ2 is the knee joint angle; is the lower limb joint angular acceleration, is the hip joint angular acceleration, is the knee joint angular acceleration; is the centrifugal force and Coriolis force matrix, which is used to describe the radial inertial force caused by the system movement and the transverse inertial force generated by the system due to velocity coupling, and G(θ) is the gravity matrix; is the lower limb joint angular velocity, is the hip joint angular velocity, is the knee joint angular velocity; is the output torque matrix of the hip joint and knee joint motors, τ1 is the output torque of the hip joint motor, and τ2 is the output torque of the knee joint motor;
[0016] Deform the dynamic equation of the lower limb rehabilitation robot to obtain:
[0017]
[0018] Design the intermediate control variable W to transform the nonlinear dynamic equation into a linearized equation, and let:
[0019]
[0020] Design the input of the interval type-2 fuzzy controller as the angle error and the angular velocity error is the desired joint angle, θ 1d is the desired hip joint angle, θ 2d is the desired knee joint angle; e1 is the hip joint angle error, and e2 is the knee joint angle error; is the desired joint angular velocity, is the desired hip joint angular velocity, is the desired knee joint angular velocity; is the hip joint angular velocity error, is the knee joint angular velocity error;
[0021] The output of the designed interval type-2 fuzzy controller is the angular acceleration error is the hip joint angular acceleration error, is the knee joint angular acceleration error; from θ, θ d are both second-order differentiable, and the angular acceleration error can be obtained
[0022] Let the angular acceleration error be z, and we get:
[0023]
[0024] where, is the desired joint angular acceleration, is the desired hip joint angular acceleration, is the desired knee joint angular acceleration;
[0025] The state equation of the lower limb rehabilitation robot system with feedback linearization is constructed as:
[0026]
[0027] where, is the state vector, x1 is the hip joint angle error, x2 is the hip joint angular velocity error, x3 is the knee joint angle error, and x4 is the knee joint angular velocity error; is the derivative of the state vector with respect to time, are respectively the hip joint angular velocity error, hip joint angular acceleration error, knee joint angular velocity error, and knee joint angular acceleration error; is the input vector, z1 is the hip joint angular acceleration error, z2 is the knee joint angular acceleration error; A is the system matrix, and B is the input matrix.
[0028] Furthermore, the use of the LQR method to find the optimal state feedback matrix of the system includes:
[0029] Construct the state feedback control law as:
[0030] U(t) = -K lE(t), where U(t) is the input variable, and K l is the optimal state feedback matrix, E(t) is the state vector, e1 is the hip joint angle error, and e2 is the knee joint angle error, is the hip joint angular velocity error, is the knee joint angular velocity error, and T represents the transpose operation;
[0031] Construct the performance index as:
[0032]
[0033] where J is the performance index, t0 is the initial time, and t f is the final time, Q l is the weighting matrix for the state vector, R l is the weighting matrix for the input variable, and N x is the terminal state weight matrix;
[0034] When the performance index J is minimized, the corresponding K l is the optimal state feedback matrix.
[0035] Furthermore, formulating the domain of the controller input and output by combining the optimal state feedback matrix and the input and output of the interval type-2 fuzzy controller includes:
[0036] The domain of the controller input and output includes the domain of the hip joint angle error e1, the domain of the hip joint angular velocity error the domain of the hip joint angular acceleration error the domain of the knee joint angle error e2, the domain of the knee joint angular velocity error the domain of the knee joint angular acceleration error the domain;
[0037] Set the domain of the hip joint angle error e1 and the domain of the knee joint angle error e2. Considering that the input of the interval type-2 fuzzy controller is the angle error and the angular velocity error, from the formula state vector obtain the domain of the hip joint angular velocity error and the domain of the knee joint angular velocity error ;
[0038] From the formula acceleration state vector obtain the domain of the hip joint angular acceleration error and the domain of the knee joint angular acceleration error ;
[0039] Further, the universe of discourse of the input and output of the division controller is defined, and the input and output triangular membership functions of the hip joint interval type-2 fuzzy controller are constructed, including:
[0040] Set the input of the hip joint interval type-2 fuzzy controller as the hip joint angle error e1 and the hip joint angular velocity error Set the output of the hip joint interval type-2 fuzzy controller as the hip joint angular acceleration error
[0041] In the universe of discourse of the hip joint angle error e1, the hip joint angular velocity error of the universe of discourse, and the hip joint angular acceleration error of the universe of discourse, multiple fuzzy subsets are divided respectively,
[0042] The input and output triangular membership functions of the hip joint interval type-2 fuzzy controller are constructed as follows: For the universe of discourse of the hip joint angle error e1, the hip joint angular velocity error of the universe of discourse, and the hip joint angular acceleration error of the universe of discourse, triangular membership functions with the same number as the fuzzy subsets are constructed, so that the triangular membership functions correspond to the fuzzy subsets one by one; multiple triangular upper membership functions divide each universe of discourse into multiple parts, and the triangular lower membership functions are valued according to the height and the widths of the left and right bottom sides of the triangular upper membership functions; the area enclosed by the triangular upper membership function and the triangular lower membership function is the uncertain area, and it is stipulated that the value of the secondary membership function falling in the uncertain area is 1.
[0043] Further, the triangular upper membership function is:
[0044]
[0045] The triangular lower membership function is:
[0046]
[0047] where, c i (i = 1, 2,..., n) is the vertex of the membership function, n is the number of vertices, that is, the number of fuzzy subsets; Δ uL is the left bottom side width of the triangular upper membership function, Δ uR is the right bottom side width of the triangular upper membership function, Δ lL is the left bottom side width of the triangular lower membership function, Δ lR is the right bottom side width of the triangular lower membership function, and all bottom side widths are taken as ρ is the height coefficient, and the universe of discourse is (0, 1).
[0048] Further, the construction of the interval type-2 fuzzy control rules includes:
[0049] For the hip joint interval type-2 fuzzy controller, the hip joint angle error e1 and the hip joint angular velocity error The output hip joint angular acceleration error All have n fuzzy subsets, generating n×n fuzzy control rules; for the knee joint interval type-2 fuzzy controller, the knee joint angle error e2 and the knee joint angular velocity error The output knee joint angular acceleration error All have n fuzzy subsets, generating n×n fuzzy control rules;
[0050] In the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller, the form of the i-th rule is described by the fuzzy conditional statement as follows:
[0051]
[0052] Among them, A α , B β is the input interval type-2 fuzzy set, C αβ is the output interval type-2 fuzzy set, describing the fuzzy mapping relationship from the input space to the output space; e λ is the hip joint angle error or the knee joint angle error, λ = 1 represents the hip joint angle error, and λ = 2 represents the knee joint angle error; is the hip joint angular velocity error or the knee joint angular velocity error, λ = 1 represents the hip joint angular velocity error, and λ = 2 represents the knee joint angular velocity error; is the hip joint angular acceleration error or the knee joint angular acceleration error, λ = 1 represents the hip joint angular acceleration error, and λ = 2 represents the knee joint angular acceleration error.
[0053] Further, the use of the centroid defuzzification method to defuzzify the type-2 output fuzzy set inferred from the interval type-2 fuzzy control rules to obtain the interval range of the type-1 membership function in the type-2 membership function includes:
[0054] Set the input vector: Output vector X and Y represent the input space and the output space respectively, and the fuzzy mapping relationship from the input space to the output space is:
[0055]
[0056] Among them, A α ×B β is the input two-dimensional Cartesian product space, A α ×B β →C αβ represents the input space Aα ×B β is mapped to the output space C αβ ;
[0057] Interval type-2 fuzzy set is A α For the set, the constructed interval type-2 fuzzy set is:
[0058]
[0059] where, is the secondary membership function, and are respectively the upper membership function and the lower membership function of the input vector x belonging to the interval type-2 fuzzy set ;
[0060] Interval type-2 fuzzy set is B β For the set, the constructed interval type-2 fuzzy set is:
[0061]
[0062] where, is the secondary membership function, and are respectively the upper membership function and the lower membership function of the input vector x belonging to the interval type-2 fuzzy set ;
[0063] When the input vector is x'∈X and the i-th rule is activated, the output of the fuzzy mapping relation is:
[0064]
[0065] where, μ X(x') is the input membership when the input is x', μ X (y) represents the membership of the output variable y in the fuzzy set X, represents the membership of the input space A α ×B β mapped to the output space C αβ ;
[0066] Set the membership function of the output variable y∈Y of the interval type-2 fuzzy controller as:
[0067]
[0068] where, M is the number of fuzzy rules, μ C (y) is the output membership of the i-th rule, represents the output membership function under the i-th rule;
[0069] Centroid reduction formula Y C (x) is as follows:
[0070]
[0071] Where Y C (x) represents the output membership function μ C (y) discretized into N points y1, y2…, y N , y i is the i-th discrete point, is the membership degree at the i-th discrete point. In the formula, the integral sign represents traversing all discrete points and the values of the secondary membership degrees, is the secondary membership function of the i-th point in the interval type-2 fuzzy set , is the secondary membership function of the i-th point in the interval type-2 fuzzy set ;
[0072] The range of the type-1 membership function embedded in the type-2 membership function calculated by the centroid reduction formula is denoted as:
[0073] [y l (x), y r (x)],
[0074] Where y l (x) is the minimum value of the value range of the type-1 membership function, and y r (x) is the maximum value of the value range of the type-1 membership function.
[0075] Furthermore, the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller are specifically the clear values obtained by defuzzifying the interval type-2 fuzzy set using the centroid method. The final output is: y = [y l (x) + y r (x)] / 2;
[0076] The simulation of the movement trajectories of the hip joint and the knee joint according to the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller is specifically as follows: The final output results of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller are the hip joint angular acceleration error and the knee joint angular acceleration error. Combining the dynamic equation and the state equation of feedback linearization, the motor torques of the hip joint and the knee joint are obtained. Finally, through the dynamic equation, the hip joint angular acceleration and the knee joint angular acceleration are output. According to the hip joint angular acceleration, the hip joint angular velocity and the hip joint angle are obtained. According to the knee joint angular acceleration, the knee joint angular velocity and the knee joint angle are obtained, thereby simulating the movement trajectories of the hip joint and the knee joint.
[0077] The present invention also provides a lower limb rehabilitation robot control system based on IT2-FC, including:
[0078] A system model construction module for constructing an interval type-2 fuzzy controller and constructing a system model of a lower limb rehabilitation robot with feedback linearization;
[0079] A domain calculation module for using the LQR method to obtain the optimal state feedback matrix of the system, and formulating the domain of the controller input and output in combination with the optimal state feedback matrix and the input and output of the interval type-2 fuzzy controller;
[0080] A triangular membership function construction module for dividing the domain of the controller input and output, and constructing the input and output triangular membership functions of the hip joint interval type-2 fuzzy controller and the input and output triangular membership functions of the knee joint interval type-2 fuzzy controller;
[0081] An interval type-2 fuzzy control rule construction module for constructing interval type-2 fuzzy control rules according to the input and output triangular membership functions of the hip joint interval type-2 fuzzy controller and the input and output triangular membership functions of the knee joint interval type-2 fuzzy controller;
[0082] A fuzzy set defuzzification module for defuzzifying the type-2 output fuzzy set inferred by the interval type-2 fuzzy control rules using the centroid defuzzification method to obtain the interval range of the type-1 membership function in the type-2 membership function;
[0083] A trajectory simulation module for defuzzifying the interval range of the type-1 membership function using the centroid method to obtain the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller, and simulating the motion trajectories of the hip joint and the knee joint according to the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller.
[0084] The present invention also provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the lower limb rehabilitation robot control method based on IT2-FC is implemented.
[0085] The present invention also provides a lower limb rehabilitation robot control device based on IT2-FC, including a memory, a processor, and a computer program stored on the memory and executable on the processor, and when the processor executes the computer program, the lower limb rehabilitation robot control method based on IT2-FC is implemented.
[0086] The above technical solution of the present invention has the following beneficial effects compared with the prior art:
[0087] The present invention uses interval type-2 fuzzy control to control a lower limb rehabilitation robot, which can improve the personalization ability of the lower limb rehabilitation robot, so as to be applicable to the situation where there are large individual differences among patients. By combining feedback linearization with interval type-2 fuzzy control, the sensitivity of the system to parameter changes is reduced through linearization processing, and the robustness of the system is enhanced; at the same time, the complexity of nonlinear system calculation is reduced, and the computational burden is alleviated; the mathematical model of the controller can also be simplified, thereby simplifying the design of the controller. On this basis, the interval type-2 fuzzy controller is designed by combining the LQR method, ensuring that the lower limb rehabilitation robot can still adjust in real time and accurately track the expected motion trajectory when there are individual differences among patients, and having good robustness in the presence of external disturbances and parameter perturbations. Further strengthen the anti-interference ability and accuracy of the system, enable patients to receive more effective and stable treatment, reduce the requirements for sensors, and reduce the cost of the system. Description of the Drawings
[0088] In order to make the content of the present invention easier to be clearly understood, the following further details the present invention according to the specific embodiments of the present invention and in combination with the drawings, where:
[0089] Figure 1 It is a flowchart of the method in the preferred embodiment of the present invention.
[0090] Figure 2 It is a structural block diagram of the preferred embodiment of the present invention.
[0091] Figure 3 It is a lower limb rehabilitation robot system model constructed in the preferred embodiment of the present invention.
[0092] Figure 4 It is a membership function graph of the hip joint interval type-2 fuzzy controller constructed in the preferred embodiment of the present invention.
[0093] Figure 5 It is a membership function graph of the knee joint interval type-2 fuzzy controller constructed in the preferred embodiment of the present invention.
[0094] Figure 6 It is a fuzzy control rule surface graph of the hip joint interval type-2 fuzzy controller drawn in the preferred embodiment of the present invention.
[0095] Figure 7 It is a fuzzy control rule surface graph of the knee joint interval type-2 fuzzy controller drawn in the preferred embodiment of the present invention.
[0096] Figure 8 It is a curve graph of the hip joint and knee joint angle tracking error changes of the lower limb rehabilitation robot under the interval type-2 fuzzy control method in the simulation experiment.
[0097] Figure 9It is the trajectory tracking effect diagram of the lower limb rehabilitation robot system under interval type-2 fuzzy control in the simulation experiment.
[0098] Figure 10 It is the trajectory tracking effect diagram of the lower limb rehabilitation robot system under interval type-2 fuzzy control after the change of each physical quantity in the simulation experiment.
[0099] Figure 11 It is the trajectory tracking effect diagram of the lower limb rehabilitation robot system under external interference after the change of each physical quantity in the simulation experiment. Specific implementation manners
[0100] The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments, so that those skilled in the art can better understand the present invention and be able to implement it, but the embodiments given are not intended to limit the present invention.
[0101] Embodiment 1
[0102] Refer to Figure 1 、 Figure 2 As shown, the present invention discloses a control method for a lower limb rehabilitation robot based on IT2-FC, including the following steps:
[0103] S1: Construct an interval type-2 fuzzy controller (IT2-FC) and construct a feedback linearized lower limb rehabilitation robot system model. As Figure 3 As shown is the lower limb rehabilitation robot system model, where H and K represent the hip joint and the knee joint respectively. It is stipulated that the horizontal right represents the positive direction of the x-axis; the vertical downward represents the positive direction of the y-axis; the intersection point H of the two axes represents the coordinate origin, that is, the hip joint; l1 and l2 represent the lengths of the thigh link and the calf link respectively; O and P are the centroid positions of the two links respectively; d1 and d2 are the lengths from the centroid of the link to the hip joint and the knee joint respectively; θ1 and θ2 are the angles of the hip joint and the knee joint relative to the y-axis respectively. According to the forward kinematics and inverse kinematics, the dynamic equation of the lower limb rehabilitation robot system model is as shown in Equation (1.1), and the state equation of the lower limb rehabilitation robot system model is deduced using feedback linearization as shown in Equation (1.5).
[0104] S1-1: Construct the dynamic equation of the lower limb rehabilitation robot:
[0105]
[0106] Among them, M(θ) is the inertia matrix, is the lower limb joint angle, θ1 is the hip joint angle, and θ2 is the knee joint angle; is the lower limb joint angular acceleration, is the hip joint angular acceleration, is the angular acceleration of the knee joint; is the centrifugal force and Coriolis force matrix, used to describe the radial inertial force caused by the system motion and the lateral inertial force generated by the system due to velocity coupling, and G(θ) is the gravity matrix; is the angular velocity of the lower limb joint, is the angular velocity of the hip joint, is the angular velocity of the knee joint; is the output torque matrix of the hip joint and knee joint motors, τ1 is the output torque of the hip joint motor, and τ2 is the output torque of the knee joint motor.
[0107] S1-2: The present invention uses the LQR method to obtain the state feedback controller. The prerequisite for using the LQR method is that the system is a linear system. To linearize the system, the present invention uses the feedback linearization of the dynamics equation of the lower limb rehabilitation robot. The specific steps are as follows:
[0108] S1-2-1: Deform the dynamics equation of the lower limb rehabilitation robot to obtain:
[0109]
[0110] Design the intermediate control variable W to transform the nonlinear dynamics equation into a linearized equation. Let:
[0111]
[0112] S1-2-2: The input of the interval type-2 fuzzy controller designed by the present invention is the angle error and the angular velocity error is the desired joint angle, θ 1d is the desired hip joint angle, θ 2d is the desired knee joint angle; e1 is the hip joint angle error, and e2 is the knee joint angle error; is the desired joint angular velocity, is the desired hip joint angular velocity, is the desired knee joint angular velocity; is the hip joint angular velocity error, is the knee joint angular velocity error.
[0113] S1-2-3: The output of the interval type-2 fuzzy controller is designed as the angular acceleration error is the hip joint angular acceleration error, is the knee joint angular acceleration error; from θ, θ d are both second-order differentiable, and the angular acceleration error
[0114] Let the angular acceleration error be z, and obtain:
[0115]
[0116] Among them, is the desired joint angular acceleration, that is, the second derivative of θ d , is the desired hip joint angular acceleration, is the desired knee joint angular acceleration.
[0117] S1-2-4: The state equation for constructing the feedback linearized lower limb rehabilitation robot system is:
[0118]
[0119] Among them, is the state vector, x1 is the hip joint angle error, x2 is the hip joint angular velocity error, x3 is the knee joint angle error, and x4 is the knee joint angular velocity error; is the derivative of the state vector with respect to time, are respectively the hip joint angular velocity error, hip joint angular acceleration error, knee joint angular velocity error, and knee joint angular acceleration error; is the input vector, z1 is the hip joint angular acceleration error, z2 is the knee joint angular acceleration error; A is the system matrix, B is the input matrix, in this embodiment
[0120] S2: Use the LQR method to find the optimal state feedback matrix of the system.
[0121] S2-1: Construct the state feedback control law as:
[0122] U(t) = -K l E(t) (1.6), where U(t) is the input variable, K l is the optimal state feedback matrix, E(t) is the state vector, e1 is the hip joint angle error, e2 is the knee joint angle error, is the hip joint angular velocity error, is the knee joint angular velocity error, and T is the transpose operation.
[0123] S2-2: Construct the performance index as:
[0124]
[0125] Among them, J is the performance index, t0 is the initial time, t f is the final time, Q l is the weighting matrix for the state vector, R l is the weighting matrix for the input variable, N x is the terminal state weight matrix;
[0126] S2-3: When the performance index J is minimized, the corresponding K l is the optimal state feedback matrix.
[0127] In this embodiment, the weighting matrix is set as:
[0128]
[0129] Substituting into Equation (1.6), the optimal state feedback matrix can be obtained:
[0130]
[0131] S3: Combine the optimal state feedback matrix and the input and output of the interval type-2 fuzzy controller to formulate the universes of discourse of the controller input and output, so as to design an interval type-2 fuzzy controller to improve the control effect.
[0132] The universes of discourse of the controller input and output include the universe of discourse of the hip joint angle error e1, the universe of discourse of the hip joint angular velocity error of, the universe of discourse of the hip joint angular acceleration error of, the universe of discourse of the knee joint angle error e2, the universe of discourse of the knee joint angular velocity error of, the universe of discourse of the knee joint angular acceleration error of;
[0133] Set the universes of discourse of the hip joint angle error e1 and the knee joint angle error e2. The motion range of each joint angle is between -2π and 2π, leaving a margin for the boundaries of the input quantities of the fuzzy controller. Therefore, in this embodiment, the universes of discourse of the hip joint angle error e1 and the knee joint angle error e2 are selected as [-10, 10], with the unit of radian.
[0134] Combined with the inputs of the interval type-2 fuzzy controller being the angle error and the angular velocity error, from the formula state vector the universe of discourse of the hip joint angular velocity error of and the universe of discourse of the knee joint angular velocity error of are obtained; in this embodiment, that is, combined with:
[0135]
[0136] the universe of discourse of the hip joint angular velocity error is obtained as [-39.7, 39.7], and the universe of discourse of the knee joint angular velocity error is [-13.32, 13.32], with the unit of radian per second.
[0137] Then, from the formula acceleration state vector the universe of discourse of the hip joint angular acceleration error of and the universe of discourse of the knee joint angular acceleration error The domain of discourse; in this embodiment, it is combined with:
[0138]
[0139] to obtain the hip joint angular acceleration error The domain of discourse of is [-316.2, 316.2], and the knee joint angular acceleration error The domain of discourse of is [-316.2, 316.2], and the unit is radians per second squared.
[0140] S4: Divide the domain of discourse of the controller input and output, and construct the triangular membership functions of the input and output of the hip joint interval type-2 fuzzy controller and the triangular membership functions of the input and output of the knee joint interval type-2 fuzzy controller.
[0141] The present invention designs an interval type-2 fuzzy controller for each of the hip joint and the knee joint. The hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller have similar structures and parameters. The design idea of the interval type-2 fuzzy controller is demonstrated by designing the hip joint interval type-2 fuzzy controller, and the knee joint interval type-2 fuzzy controller is designed in the same way.
[0142] The membership function describes the degree to which the system input and output values belong to each fuzzy subset. The membership function of the interval type-2 fuzzy set is a fuzzy number between 0 and 1, and the larger the value, the higher the degree of conformity to the corresponding fuzzy subset. The membership function of the interval type-2 fuzzy controller takes a region in a certain interval. The upper bound of this region corresponds to the upper membership function, and the lower bound corresponds to the lower membership function.
[0143] The present invention adopts the triangular membership function to design the triangular membership function for the hip joint and knee joint interval type-2 fuzzy controllers.
[0144] S4-1: Set the input of the hip joint interval type-2 fuzzy controller as the hip joint angle error e1 and the hip joint angular velocity error Set the output of the hip joint interval type-2 fuzzy controller as the hip joint angular acceleration error Set the input of the knee joint interval type-2 fuzzy controller as the knee joint angle error e2 and the knee joint angular velocity error Set the output of the knee joint interval type-2 fuzzy controller as the knee joint angular acceleration error
[0145] S4-2: Divide multiple fuzzy subsets in the domain of discourse of the hip joint angle error e1, the domain of discourse of the hip joint angular velocity error and the domain of discourse of the hip joint angular acceleration error respectively, and divide multiple fuzzy subsets in the domain of discourse of the knee joint angle error e2, the domain of discourse of the knee joint angular velocity error The universe of discourse, knee joint angular acceleration error Divide multiple fuzzy subsets in each universe of discourse; in this embodiment, five fuzzy subsets are divided in each universe of discourse, and the description in language variables is "negative large" (NB), "negative small" (NS), "zero" (O), "positive small" (PS), "positive large" (PB). The fuzzy subset universes of discourse of hip joint angle error, hip joint angular acceleration error, hip joint angular acceleration, knee joint angle error, knee joint angular acceleration error, and knee joint angular acceleration are all: E = {NB, NS, O, PS, PB}.
[0146] S4-3: Construct the input and output triangular membership functions of the hip joint interval type-2 fuzzy controller as follows: For the universe of discourse of hip joint angle error e1, hip joint angular velocity error The universe of discourse, hip joint angular acceleration error For each universe of discourse, construct triangular membership functions with the same number as the fuzzy subsets, so that the triangular membership functions correspond one-to-one with the fuzzy subsets; multiple triangular upper membership functions divide each universe of discourse into multiple parts, and the triangular lower membership functions are valued according to the height and the widths of the left and right bases of the triangular upper membership functions; in this embodiment, five triangular membership functions are constructed, so that the five triangular membership functions correspond one-to-one with the five fuzzy subsets. The five triangular upper membership functions divide each universe of discourse into five parts. The height of the triangular lower membership function is 0.5 times the height of the triangular upper membership function, and the widths of the left and right bases of the triangular lower membership function are 0.5 times the widths of the left and right bases of the triangular upper membership function. The region enclosed by the triangular upper membership function and the triangular lower membership function is the uncertain region, and it is stipulated that the value of the secondary membership function falling in the uncertain region is 1.
[0147] The construction method of the input and output triangular membership functions of the knee joint interval type-2 fuzzy controller is the same as that of the input and output triangular membership functions of the hip joint interval type-2 fuzzy controller.
[0148] The triangular upper membership function is as follows:
[0149]
[0150] The triangular lower membership function is as follows:
[0151]
[0152] Among them, c i (i = 1, 2,..., n) is the vertex of the membership function, n is the number of vertices, that is, the number of fuzzy subsets. In this embodiment, i ranges from 1 to 5 corresponding to the vertices of the five fuzzy set membership functions from left to right in the figure; Δ uL Is the width of the left base of the triangular upper membership function, ΔuR is the right bottom width of the triangular upper membership function, Δ lL is the left bottom width of the triangular lower membership function, Δ lR is the right bottom width of the triangular lower membership function. All bottom widths are taken as 1 / 4 of the domain of the corresponding membership function. In this embodiment, it is 1 / 4; ρ is the height coefficient, and the domain is (0, 1). In the present invention, ρ = 0.5 is taken.
[0153] As Figure 4 shown is the membership function diagram of the interval type-2 fuzzy controller for the hip joint constructed in this embodiment. Figure 4 In (a) is the membership function of the hip joint angle error, Figure 4 in (b) is the membership function of the hip joint angular velocity error, Figure 4 in (c) is the membership function of the hip joint angular acceleration error.
[0154] As Figure 5 shown is the membership function diagram of the interval type-2 fuzzy controller for the knee joint constructed in this embodiment. Figure 5 In (a) is the membership function of the knee joint angle error, Figure 5 in (b) is the membership function of the knee joint angular velocity error, Figure 5 in (c) is the membership function of the knee joint angular acceleration error.
[0155] The type of the membership function is the triangular membership function. All membership function diagrams from left to right are the interval type-2 membership functions of the fuzzy sets {NB, NS, O, PS, PB}, and the shaded area is the uncertain area. Figure 4 And Figure 5 The numerical values of the membership functions shown in (c) are normalized so that the ordinate interval is [0, 1], and the actual output value is multiplied by the gain coefficient G. In the present invention, G = 1 is taken.
[0156] S5: According to the input and output triangular membership functions of the interval type-2 fuzzy controller for the hip joint and the input and output triangular membership functions of the interval type-2 fuzzy controller for the knee joint, construct the interval type-2 fuzzy control rules.
[0157] The interval type-2 fuzzy control rules are established according to the dynamic equations of the observed object and combined with practical experience and knowledge theory. In the present invention, the fuzzy logic is described using the fuzzy conditional statement of the IF-THEN rule. The structure of IF-THEN is: IF [premise condition] THEN [conclusion]. Among them, the premise condition describes the fuzzy state of the input variable, and the conclusion is the action that should be taken according to the premise condition or the fuzzy state of the output variable. The premise condition and the conclusion of the fuzzy rules of the present invention are both interval type-2 fuzzy sets, and the final inference is the composition of the interval type-2 fuzzy relations.
[0158] For the hip joint angle error e1 and hip joint angular velocity error input to the type-2 fuzzy controller for the hip joint interval The output hip joint angular acceleration error All have n fuzzy subsets, generating n×n fuzzy control rules; for the knee joint angle error e2 and knee joint angular velocity error input to the type-2 fuzzy controller for the knee joint interval The output knee joint angular acceleration error All have n fuzzy subsets, generating n×n fuzzy control rules;
[0159] In the type-2 fuzzy controller for the hip joint interval and the type-2 fuzzy controller for the knee joint interval, the form of the i-th rule is described by the fuzzy conditional statement as follows:
[0160]
[0161] Where, A α , B β are input interval type-2 fuzzy sets, C αβ is the output interval type-2 fuzzy set, describing the fuzzy mapping relationship from the input space to the output space; e λ is the hip joint angle error or knee joint angle error, λ = 1 represents the hip joint angle error, and λ = 2 represents the knee joint angle error; is the hip joint angular velocity error or knee joint angular velocity error, λ = 1 represents the hip joint angular velocity error, and λ = 2 represents the knee joint angular velocity error; is the hip joint angular acceleration error or knee joint angular acceleration error, λ = 1 represents the hip joint angular acceleration error, and λ = 2 represents the knee joint angular acceleration error.
[0162] In this embodiment, A α ∈{NB, NS, O, PS, PB}, B β ∈{NB, NS, O, PS, PB}, C αβ ∈{NB, NS, O, PS, PB}, corresponding to the input e1 or e2, or output of the fuzzy sets. When α, β in A α and B β are 1, 2, 3, 4, 5 respectively, the corresponding output fuzzy rules are NB, NS, O, PS, PB, and the specific corresponding fuzzy control rules of C αβ output are shown in Table 1.
[0163]
[0164] Table 1 Fuzzy control rule table of the type-2 fuzzy controller for the hip joint interval
[0165] S6: Use the centroid type-reduction method to reduce the type-2 output fuzzy set inferred by the interval type-2 fuzzy control rules, and obtain the interval range of the type-1 membership function in the type-2 membership function.
[0166] S6-1: Set the input vector: Output vector Let X and Y represent the input space and the output space respectively. The fuzzy mapping relationship from the input space to the output space is:
[0167]
[0168] where, A α ×B β is the input two-dimensional Cartesian product space, and A α ×B β →C αβ represents the mapping from the input space A α ×B β to the output space C αβ .
[0169] S6-2: The interval type-2 fuzzy set is a set of A α , and is expressed in the following form:
[0170]
[0171] where, is the secondary membership function, and J x ∈[0,1] is the interval of the secondary membership.
[0172] The interval type-2 fuzzy set constructed by the present invention is:
[0173]
[0174] where, is the secondary membership function, and are respectively the upper membership function and the lower membership function of the input vector x belonging to the interval type-2 fuzzy set ;
[0175] The interval type-2 fuzzy set is a set of B β , and is expressed in the following form:
[0176]
[0177] where, is the secondary membership function, and J x ∈[0,1] is the interval of the secondary membership.
[0178] The interval type-2 fuzzy set constructed by the present invention is as follows:
[0179]
[0180] Wherein, is the secondary membership function, and are respectively the upper membership function and the lower membership function of the input vector x belonging to the interval type-2 fuzzy set .
[0181] S6-3: When the input vector is x'∈X and the i-th rule is activated, the output of the fuzzy mapping relation formula
[0182] is: Wherein, μ X(x') is the input membership when the input is x', and μ X (y) represents the membership of the output variable y in the fuzzy set X, represents the membership of the input space A α ×B β mapped to the output space C αβ .
[0183] The output of the interval type-2 fuzzy inference is still an interval type-2 fuzzy set, and a type-1 fuzzy set is mapped by using a fuzzy defuzzifier for the interval type-2 fuzzy set.
[0184] S6-4: The centroid defuzzification method is adopted in the present invention to find the centroid of the union of the output interval type-2 fuzzy sets of all rules. The membership function of the output variable y∈Y of the interval type-2 fuzzy controller is set as:
[0185]
[0186] Wherein, M is the number of fuzzy rules, and μ C (y) is the output membership of the i-th rule, represents the output membership function under the i-th rule;
[0187] The centroid defuzzification formula Y C is as follows:
[0188]
[0189] Wherein, Y C (x) represents that the output membership function μ C (y) is discretized into N points y1, y2…, y N , and y i is the i-th discrete point, and θ iis the membership degree at the i-th discrete point, where the integral sign represents traversing all discrete points and the values of the secondary membership degrees. is the secondary membership degree function of the i-th point in the interval type-2 fuzzy set . is the secondary membership degree function of the i-th point in the interval type-2 fuzzy set .
[0190] The interval range of the type-1 membership degree function embedded in the type-2 membership degree function can be calculated by the centroid defuzzification formula (1.22), denoted as:
[0191] [y l (x), y r (x)] (1.24),
[0192] where y l (x) is the minimum value of the value range of the type-1 membership degree function, and y r (x) is the maximum value of the value range of the type-1 membership degree function.
[0193] S7: Use the centroid method to defuzzify the interval range of the type-1 membership degree function to obtain the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller, and complete the design of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller.
[0194] The outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller are specifically the crisp values obtained by defuzzifying the interval type-2 fuzzy set. The final output is:
[0195] y = [y l (x) + y r (x)] / 2 (1.25);
[0196] Through the centroid defuzzification algorithm Y C (x) and defuzzification, the output y of the fuzzy controller can be calculated. Combining all the fuzzy control rules listed in the fuzzy control rule table, the fuzzy control rule surface of the hip joint interval type-2 fuzzy controller drawn in this embodiment is as Figure 6 shown, and the fuzzy control rule surface of the knee joint interval type-2 fuzzy controller is as Figure 7 shown. The hip joint and knee joint interval type-2 fuzzy controllers only differ in the universe of discourse. Different universes of discourse will result in different universes of discourse of the membership degree functions and different shapes of the fuzzy control rule surfaces.
[0197] Figure 6 and Figure 7The interval type-2 fuzzy control rule surface is a three-dimensional graph of the non-linear relationship between the input variables and the output variable in an interval type-2 fuzzy control system. The two coordinate axes at the bottom are the two inputs of the fuzzy controller, and from left to right is the angular velocity error angle error e λ ; The vertical coordinate axis is the output angular acceleration error of the fuzzy controller The interval type-2 fuzzy control rule surface is the deterministic mapping rule after interval type-2 fuzzy control rules through fuzzy reasoning and defuzzification. The surface area is the entire range of all possible input conditions mapped to the corresponding output. The color of the grid in the figure represents the magnitude of the output value. For the upper half region of the grid, the lower the gray scale, the larger the output value, and the higher the gray scale, the smaller the output value; for the lower half region of the grid, the higher the gray scale, the larger the output value, and the lower the gray scale, the smaller the output value; for the gradient region from the middle of the grid to both upper and lower sides, it indicates that the output value is gradually increasing.
[0198] S8: Simulate the movement trajectories of the hip joint and the knee joint according to the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller.
[0199] The final output results of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller are the hip joint angular acceleration error and the knee joint angular acceleration error. Combine the dynamic equation and the state equation of feedback linearization to obtain the motor torques of the hip joint and the knee joint. Finally, output the hip joint angular acceleration and the knee joint angular acceleration through the dynamic equation. Obtain the hip joint angular velocity and the hip joint angle according to the hip joint angular acceleration, and obtain the knee joint angular velocity and the knee joint angle according to the knee joint angular acceleration, so as to simulate the movement trajectories of the hip joint and the knee joint.
[0200] Embodiment 2
[0201] The present invention also discloses a lower limb rehabilitation robot control system based on IT2-FC, including:
[0202] A system model construction module for constructing an interval type-2 fuzzy controller and constructing a system model of a lower limb rehabilitation robot with feedback linearization;
[0203] A domain calculation module for using the LQR method to obtain the optimal state feedback matrix of the system, and formulating the domain of the controller input and output in combination with the optimal state feedback matrix and the input and output of the interval type-2 fuzzy controller;
[0204] A triangular membership function construction module for dividing the domain of the controller input and output, and constructing the input and output triangular membership functions of the hip joint interval type-2 fuzzy controller and the input and output triangular membership functions of the knee joint interval type-2 fuzzy controller;
[0205] The interval type-2 fuzzy control rule construction module constructs interval type-2 fuzzy control rules according to the input and output triangular membership functions of the hip joint interval type-2 fuzzy controller and the input and output triangular membership functions of the knee joint interval type-2 fuzzy controller;
[0206] The fuzzy set defuzzification module is used to defuzzify the type-2 output fuzzy set inferred by the interval type-2 fuzzy control rules using the centroid defuzzification method to obtain the interval range of the type-1 membership functions in the type-2 membership functions;
[0207] The trajectory simulation module is used to defuzzify the interval range of the type-1 membership functions using the center of gravity method to obtain the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller, and simulate the movement trajectories of the hip joint and the knee joint according to the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller.
[0208] Embodiment 3
[0209] The present invention also discloses a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, it implements the IT2-FC-based lower limb rehabilitation robot control method in Embodiment 1.
[0210] Embodiment 4
[0211] The present invention also discloses a device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it implements the IT2-FC-based lower limb rehabilitation robot control method in Embodiment 1.
[0212] The present invention aims to solve the problems that the existing control methods for controlling lower limb rehabilitation robots have the disadvantages of poor stability, weak anti-interference ability, and weak personalization ability. In the face of problems such as individual differences in patients' lower limb length, lower limb diameter, and weight, by establishing interval type-2 fuzzy membership functions and control methods, the control system can encompass the model uncertainties existing in the controlled object, so as to ensure that the expected movement trajectory can still be tracked in real time when there are individual differences. In the face of being easily affected by collisions, vibrations, or other interferences during the rehabilitation training process, by establishing control rules using interval type-2 fuzzy logic, the system has robustness, thus having anti-interference ability.
[0213] Specifically, the beneficial effects of the present invention are as follows:
[0214] (1) The present invention uses interval type-2 fuzzy control to control the lower limb rehabilitation robot, which can improve the personalization ability of the lower limb rehabilitation robot, so as to be applicable to the situation where there are large individual differences among patients.
[0215] (2) The present invention combines feedback linearization with interval type-2 fuzzy control, reduces the sensitivity of the system to parameter changes through linearization processing, and enhances the robustness of the system; meanwhile, it reduces the computational complexity of the nonlinear system and alleviates the computational burden; it can also simplify the mathematical model of the controller, thereby simplifying the design of the controller.
[0216] (3) On this basis, the interval type-2 fuzzy controller is designed by combining with the LQR method to ensure that the lower limb rehabilitation robot can still adjust in real time and accurately track the expected motion trajectory when there are individual differences among patients, and has good robustness in the presence of external disturbances and parameter perturbations. Further strengthen the anti-interference ability and accuracy of the system, enable patients to receive more effective and stable treatment, reduce the requirements for sensors, and reduce the cost of the system.
[0217] To further prove the beneficial effects of the present invention, a simulation experiment is conducted on the method of the present invention in this embodiment. Values are assigned to each physical quantity of the dynamic model as shown in Table 2.
[0218] Physical symbol Symbol meaning Assignment <![CDATA[m1]]> Mass of the thigh connecting rod 0.5 kg <![CDATA[m2]]> Mass of the calf connecting rod 0.3 kg <![CDATA[l1]]> Length of the thigh connecting rod 0.5m <![CDATA[l2]]> Length of the calf connecting rod 0.6m <![CDATA[d1]]> Length from the center of mass of the thigh to the hip joint 0.25m <![CDATA[d2]]> Length from the center of mass of the calf to the knee joint 0.3m g Acceleration due to gravity <![CDATA[9.81m / s 2 >
[0219] Table 2 Assignment Table of Each Physical Quantity
[0220] The target motion trajectory of the hip joint is represented by a sine function, which is θ 1d =A thigh sin(2π / T×t); where A thigh is the hip joint angle amplitude, with a value of 20 and the unit of degree; T is the period, with a value of 10 and the unit of second;
[0221] The target motion trajectory of the knee joint is a sine function, lagging behind the movement of the thigh and with a larger amplitude, which is θ 2d =A shank sin(2π / T×t + φ); where A shank is the knee joint angle amplitude, with a value of 40 and the unit of degree; T is the period, with a value of 10, and φ is the phase difference between the target motion trajectory of the knee joint and the target motion trajectory of the hip joint, with a value of and the unit of radian.
[0222] The initial condition values of each joint are as follows:
[0223] The lower limb rehabilitation robot system using the interval type-2 fuzzy control method is simulated and analyzed to verify the effectiveness of the control method. Figure 9The curve of the hip joint and knee joint angle tracking errors of the lower limb rehabilitation robot under the interval type-2 fuzzy control method. The dotted line represents the hip joint angular velocity error, and the solid line represents the knee joint angle error. From the trend of the curve, the hip joint and knee joint angle tracking errors gradually decrease with the increase of time, indicating that the interval type-2 fuzzy control method can effectively control the hip joint angle and knee joint angle. The hip joint error reduces to 0 degrees within 1.5 seconds, and the knee joint error reduces to 0 degrees within 1 second. It verifies that the lower limb rehabilitation robot based on the interval type-2 fuzzy control method can quickly track the target trajectory.
[0224] Figure 9 It represents the trajectory tracking effect of the lower limb rehabilitation robot system under the interval type-2 fuzzy control. Figure 9 In (a), it is the hip joint angle tracking diagram. Figure 9 In (b), it is the knee joint angle tracking diagram. In Figure 9 In (a) and Figure 9 In (b), the dotted line represents the target curves of the hip joint and knee joint; the solid line represents the actual output curves of the hip joint and knee joint. From Figure 9 It can be seen that under the control of the interval type-2 fuzzy controller, the hip joint and knee joint can quickly track the target angle, with the maximum time not exceeding 1.5 seconds, and the maximum angle error not exceeding 1.3 degrees. It verifies that the interval type-2 fuzzy control can provide a quick and accurate control effect.
[0225] Next, the assignments of the physical quantities in the dynamic model are changed, as shown in Table 3.
[0226] Physical symbol Symbol meaning Assignment <![CDATA[m1]]> Mass of the thigh connecting rod 0.4 kg <![CDATA[m2]]> Mass of the calf connecting rod 0.2 kg <![CDATA[l1]]> Length of the thigh connecting rod 0.4m <![CDATA[l2]]> Length of the calf connecting rod 0.5m <![CDATA[d1]]> Length from the center of mass of the thigh to the hip joint 0.2m <![CDATA[d2]]> Length from the center of mass of the calf to the knee joint 0.25m g Acceleration due to gravity 9.81 m / s²
[0227] Table 3 The assignment table of the changed physical quantities
[0228] Figure 10 It represents the trajectory tracking effect of the lower limb rehabilitation robot system under the interval type-2 fuzzy control after the change of each physical quantity. Figure 10 In (a), it is the hip joint angle tracking diagram; Figure 10 In (b), it is the knee joint angle tracking diagram. In Figure 10 In (a) and Figure 10 In (b), the dotted line represents the target curves of the hip joint and knee joint; the solid line represents the actual output curves of the hip joint and knee joint. From Figure 10 It can be seen that after changing the initial conditions, the hip joint and knee joint under the control of the interval type-2 fuzzy controller can quickly track the target angle, with the maximum time not exceeding 0.8 seconds, and the maximum angle error not exceeding 1.3 degrees. It verifies that the interval type-2 fuzzy control can enable the control system to encompass the model uncertainties existing in the controlled object and still ensure real-time tracking of the expected motion trajectory when there are individual differences.
[0229] Figure 11 It shows the trajectory tracking effect of the lower limb rehabilitation robot system based on interval type-2 fuzzy control under external disturbances. Figure 11 In (a), it is the tracking graph of the hip joint angle under the disturbance. Figure 11 In (b), it is the tracking graph of the knee joint angle under the disturbance. Figure 11 In (a) and Figure 11 (b), the dashed line represents the target curve of the hip joint and the knee joint; the solid line represents the actual output curve of the hip joint and the knee joint. It can be seen from Figure 11 that a 10 N external force is input to the system every 3 seconds. Under the influence of the disturbance, the hip joint and the knee joint based on interval type-2 fuzzy control can quickly adjust to track the target angle. The maximum time taken to overcome the disturbing force does not exceed 0.3 seconds, and the maximum angle error does not exceed 4 degrees. It verifies that interval type-2 fuzzy control can enable the system to have good robustness in the presence of external disturbances and parameter perturbations.
[0230] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0231] The present application is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to the embodiments of the present application. It should be understood that each flow and / or block in the flowchart and / or block diagram can be implemented by computer program instructions, and the combination of the flows and / or blocks in the flowchart and / or block diagram can also be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing devices generate means for implementing the functions specified in Figure 1 one or more of the flows Figure 1 or blocks or the combination of multiple blocks.
[0232] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory generate a manufactured article including instruction means, and the instruction means implements the functions specified in Figure 1 one or more of the flows Figure 1 or blocks or the combination of multiple blocks.
[0233] These computer program instructions can also be loaded onto a computer or other programmable data processing apparatus, so that a series of operation steps are executed on the computer or other programmable apparatus to produce a computer-implemented process, and thus the instructions executed on the computer or other programmable apparatus provide steps for implementing the functions specified in one process or multiple processes and / or blocks Figure 1 One process or multiple processes and / or blocks Figure 1 Steps for implementing the functions specified in one block or multiple blocks.
[0234] Obviously, the above embodiments are only examples for clear illustration and are not limitations on the implementation manners. For those of ordinary skill in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all implementation manners here. And the obvious changes or modifications derived therefrom still fall within the protection scope of the present invention.
Claims
1. A control method for a lower limb rehabilitation robot based on IT2-FC, characterized in that, Including: Construct an interval type-2 fuzzy controller and construct a feedback linearized lower limb rehabilitation robot system model; Use the LQR method to find the optimal state feedback matrix of the system, and formulate the universes of discourse of the controller input and output in combination with the optimal state feedback matrix and the input and output of the interval type-2 fuzzy controller; Divide the universes of discourse of the controller input and output, and construct the triangular membership functions of the input and output of the hip joint interval type-2 fuzzy controller and the triangular membership functions of the input and output of the knee joint interval type-2 fuzzy controller; Construct interval type-2 fuzzy control rules according to the triangular membership functions of the input and output of the hip joint interval type-2 fuzzy controller and the triangular membership functions of the input and output of the knee joint interval type-2 fuzzy controller; Use the centroid defuzzification method to defuzzify the type-2 output fuzzy set inferred by the interval type-2 fuzzy control rules, and obtain the interval range of the type-1 membership function in the type-2 membership function; Use the center of gravity method to defuzzify the interval range of the type-1 membership function, obtain the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller, and simulate the motion trajectories of the hip joint and the knee joint according to the outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller.
2. The control method of the lower limb rehabilitation robot based on IT2-FC according to claim 1, characterized in that: The construction of the interval type-2 fuzzy controller and the construction of the feedback linearized lower limb rehabilitation robot system model are specifically as follows: Construct the dynamic equation of the lower limb rehabilitation robot: where \(M(\theta)\) is the inertia matrix, is the lower limb joint angle, \(\theta_1\) is the hip joint angle, and \(\theta_2\) is the knee joint angle; is the lower limb joint angular acceleration, is the hip joint angular acceleration, is the knee joint angular acceleration; is the centrifugal force and Coriolis force matrix, used to describe the radial inertial force caused by the system motion and the transverse inertial force generated by the system due to velocity coupling, and \(G(\theta)\) is the gravity matrix; is the lower limb joint angular velocity, is the hip joint angular velocity, is the knee joint angular velocity; is the hip joint and knee joint motor output torque matrix, \(\tau_1\) is the hip joint motor output torque, and \(\tau_2\) is the knee joint motor output torque; Deform the dynamic equation of the lower limb rehabilitation robot to obtain: Design the intermediate control variable W to transform the nonlinear dynamic equation into a linearized equation, and let: The inputs of the designed interval type-2 fuzzy controller are the angle error and the angular velocity error is the desired joint angle, θ 1d is the desired hip joint angle, θ 2d is the desired knee joint angle; e1 is the hip joint angle error and e2 is the knee joint angle error; is the desired joint angular velocity, is the desired hip joint angular velocity, is the desired knee joint angular velocity; is the hip joint angular velocity error, is the knee joint angular velocity error; The output of the designed interval type-2 fuzzy controller is the angular acceleration error is the hip joint angular acceleration error, is the knee joint angular acceleration error; Since θ and θ d are both second-order differentiable, the angular acceleration error Let the angular acceleration error be z, and obtain: wherein, is the desired joint angular acceleration, is the desired hip joint angular acceleration, is the desired knee joint angular acceleration; Construct the state equation of the feedback linearized lower limb rehabilitation robot system as: Among them, is the state vector, where x1 is the hip joint angle error, x2 is the hip joint angular velocity error, x3 is the knee joint angle error, and x4 is the knee joint angular velocity error; is the derivative of the state vector with respect to time, are respectively the hip joint angular velocity error, hip joint angular acceleration error, knee joint angular velocity error, and knee joint angular acceleration error; is the input vector, where z1 is the hip joint angular acceleration error and z2 is the knee joint angular acceleration error; A is the system matrix and B is the input matrix; The use of the LQR method to find the optimal state feedback matrix of the system includes: Construct the state feedback control law as: U(t) = -K l E(t), Among them, U(t) is the input variable, K l is the optimal state feedback matrix, E(t) is the state vector, e1 is the hip joint angle error, e2 is the knee joint angle error, is the hip joint angular velocity error, is the knee joint angular velocity error, T is the transpose operation; Construct the performance index as: Among them, J is the performance index, t0 is the initial time, and t f is the final time, Q l is the weight matrix for the state vector, R l is the weight matrix for the input variable, N x is the terminal state weight matrix; When the performance index J is minimized, the corresponding K l is the optimal state feedback matrix.
3. The lower limb rehabilitation robot control method based on IT2-FC according to claim 1, characterized in that: The formulation of the universes of discourse of the controller input and output in combination with the optimal state feedback matrix and the input and output of the interval type-2 fuzzy controller includes: The universes of discourse of the input and output of the controller include the universe of discourse of the hip joint angle error e1, the universe of discourse of the hip joint angular velocity error , the universe of discourse of the hip joint angular acceleration error , the universe of discourse of the knee joint angle error e2, the universe of discourse of the knee joint angular velocity error , and the universe of discourse of the knee joint angular acceleration error ; Set the domain of the hip joint angle error \(e_1\) and the domain of the knee joint angle error \(e_2\). Considering that the inputs of the interval type-2 fuzzy controller are the angle error and the angular velocity error, from Equation State vector Obtain the domain of the hip joint angular velocity error and the domain of the knee joint angular velocity error ; From the formula acceleration state vector the hip joint angular acceleration error is obtained universe of discourse and the knee joint angular acceleration error universe of discourse.
4. The lower limb rehabilitation robot control method based on IT2-FC according to claim 3, characterized in that: The division of the universes of discourse of the controller input and output and the construction of the triangular membership functions of the input and output of the hip joint interval type-2 fuzzy controller include: Set the inputs of the interval type-2 fuzzy controller for the hip joint to the hip joint angle error e1 and the hip joint angular velocity error Set the output of the interval type-2 fuzzy controller for the hip joint to the hip joint angular acceleration error In the domain of the hip joint angle error e1, the hip joint angular velocity error in the domain, and the hip joint angular acceleration error in the domain, multiple fuzzy subsets are partitioned respectively, The input and output triangular membership functions of the constructed hip joint interval type-2 fuzzy controller are as follows: For the universes of discourse of the hip joint angle error e1, the hip joint angular velocity error , and the hip joint angular acceleration error , triangular membership functions with the same number as the fuzzy subsets are constructed for each universe of discourse, so that the triangular membership functions correspond one-to-one with the fuzzy subsets; multiple triangular upper membership functions divide each universe of discourse into multiple parts, and the triangular lower membership functions are valued according to the height and the widths of the left and right bases of the triangular upper membership functions; the region enclosed by the triangular upper membership functions and the triangular lower membership functions is the uncertain region, and it is stipulated that the value of the secondary membership function falling within the uncertain region is 1; The triangular upper membership function is: The triangular lower membership function is: where c i , i = 1, 2, ..., n are the vertices of the membership function, and n is the number of vertices, i.e., the number of fuzzy subsets; Δ uL is the left base width of the upper triangular membership function, Δ uR is the right base width of the upper triangular membership function, Δ lL is the left base width of the lower triangular membership function, Δ lR is the right base width of the lower triangular membership function, and all base widths are taken as ρ is the height coefficient, and the domain is (0, 1).
5. The lower limb rehabilitation robot control method based on IT2-FC according to claim 4, characterized in that: The construction of the interval type-2 fuzzy control rules includes: For the hip joint angle error e1 and hip joint angular velocity error input to the type-2 fuzzy controller in the hip joint range The output hip joint angular acceleration error Both have n fuzzy subsets, generating n×n fuzzy control rules; for the knee joint angle error e2 and knee joint angular velocity error input to the type-2 fuzzy controller in the knee joint range The output knee joint angular acceleration error Both have n fuzzy subsets, generating n×n fuzzy control rules; In the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller, the form of the i-th rule is described by the fuzzy conditional statement as follows: Among them, A α , B β is the input interval type-2 fuzzy set, C αβ is the output interval type-2 fuzzy set, describing the fuzzy mapping relationship from the input space to the output space; e λ is the hip joint angle error or the knee joint angle error, where λ = 1 represents the hip joint angle error and λ = 2 represents the knee joint angle error; is the hip joint angular velocity error or the knee joint angular velocity error, where λ = 1 represents the hip joint angular velocity error and λ = 2 represents the knee joint angular velocity error; is the hip joint angular acceleration error or the knee joint angular acceleration error, where λ = 1 represents the hip joint angular acceleration error and λ = 2 represents the knee joint angular acceleration error.
6. The lower limb rehabilitation robot control method based on IT2-FC according to claim 5, characterized in that: The use of the centroid defuzzification method to defuzzify the type-2 output fuzzy set inferred by the interval type-2 fuzzy control rules and obtain the interval range of the type-1 membership function in the type-2 membership function includes: Set the input vector: Output vector Let X and Y represent the input space and the output space respectively. The fuzzy mapping relationship from the input space to the output space is: Among them, A α ×B β is the input two-dimensional Cartesian product space, A α ×B β →C αβ represents that the input space A α ×B β is mapped to the output space C αβ ; Interval type-2 fuzzy set For A α The constructed interval type-2 fuzzy set is as follows: Among them, is the secondary membership function, and are the upper membership function and the lower membership function of the input vector x belonging to the interval type-2 fuzzy set respectively; Interval type-2 fuzzy set is B β of the set, the constructed interval type-2 fuzzy set is as follows: Among them, is the secondary membership function, and are respectively the upper membership function and the lower membership function of the input vector x belonging to the interval type-2 fuzzy set ; When the input vector is x'∈X and the i-th rule is activated, the output of the fuzzy mapping relation is: where, μ X(x') is the input membership degree when the input is x', μ X (y) represents the membership degree of the output variable y in the fuzzy set X, represents the input space A α ×B β mapped to the output space C αβ on the membership degree; Set the membership function of the output variable y∈Y of the interval type-2 fuzzy controller as: where M is the number of fuzzy rules, and μ C (y) is the output membership degree of the i-th rule, representing the output membership degree function under the i-th rule; Centroid reduction formula Y C (x) is as follows: Among them, Y C (x) represents discretizing the output membership function μ C (y) into N points y1, y2 …, y N , y i is the i-th discrete point, is the membership degree at the i-th discrete point. In the formula, the integral sign represents traversing all discrete points and the values of the secondary membership degrees, is the secondary membership function of the i-th point in the interval type-2 fuzzy set , is the secondary membership function of the i-th point in the interval type-2 fuzzy set ; Calculate the interval range of the type-1 membership function embedded in the type-2 membership function by the centroid defuzzification formula, denoted as: [y l (x),y r (x)], where y l (x) is the minimum value of the value range of the type-1 membership function, and y r (x) is the maximum value of the value range of the type-1 membership function.
7. The lower limb rehabilitation robot control method based on IT2-FC according to claim 6, characterized in that: The outputs of the hip joint interval type-2 fuzzy controller and the knee joint interval type-2 fuzzy controller are specifically the crisp values obtained by defuzzifying the interval type-2 fuzzy set using the centroid method. The final output is: y = [y l (x) + y r (x)] / 2; The motion trajectories of the hip joint and the knee joint are simulated according to the outputs of the interval type-2 fuzzy controller for the hip joint and the interval type-2 fuzzy controller for the knee joint, specifically as follows: The final output results of the interval type-2 fuzzy controller for the hip joint and the interval type-2 fuzzy controller for the knee joint are the hip joint angular acceleration error and the knee joint angular acceleration error. Combining the dynamic equation and the state equation of feedback linearization, the motor torques of the hip joint and the knee joint are obtained. Finally, the hip joint angular acceleration and the knee joint angular acceleration are output through the dynamic equation. The hip joint angular velocity and the hip joint angle are obtained according to the hip joint angular acceleration, and the knee joint angular velocity and the knee joint angle are obtained according to the knee joint angular acceleration, thereby simulating the motion trajectories of the hip joint and the knee joint.
8. A lower limb rehabilitation robot control system based on IT2-FC, characterized in that, Including: A system model construction module, which is used to construct an interval type-2 fuzzy controller and construct a system model of a lower limb rehabilitation robot with feedback linearization; A domain calculation module, which is used to use the LQR method to obtain the optimal state feedback matrix of the system, and formulate the domain of the input and output of the controller in combination with the optimal state feedback matrix and the input and output of the interval type-2 fuzzy controller; A triangular membership function construction module, which is used to divide the domain of the input and output of the controller and construct the input and output triangular membership functions of the interval type-2 fuzzy controller for the hip joint and the input and output triangular membership functions of the interval type-2 fuzzy controller for the knee joint; An interval type-2 fuzzy control rule construction module, which constructs interval type-2 fuzzy control rules according to the input and output triangular membership functions of the interval type-2 fuzzy controller for the hip joint and the input and output triangular membership functions of the interval type-2 fuzzy controller for the knee joint; A fuzzy set defuzzification module, which is used to defuzzify the type-2 output fuzzy set inferred by the interval type-2 fuzzy control rule using the centroid defuzzification method to obtain the interval range of the type-1 membership function in the type-2 membership function; A trajectory simulation module, which is used to defuzzify the interval range of the type-1 membership function using the center of gravity method to obtain the outputs of the interval type-2 fuzzy controller for the hip joint and the interval type-2 fuzzy controller for the knee joint, and simulate the motion trajectories of the hip joint and the knee joint according to the outputs of the interval type-2 fuzzy controller for the hip joint and the interval type-2 fuzzy controller for the knee joint.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, it implements the IT2-FC-based lower limb rehabilitation robot control method according to any one of claims 1-7.
10. A lower limb rehabilitation robot control device based on IT2-FC, characterized in that: Including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it implements the IT2-FC-based lower limb rehabilitation robot control method according to any one of claims 1-7.