Four-rail crane turning control method based on PSO-MPC and computer program product
By optimizing the prediction and control time-domain parameters of the crane using the PSO-MPC algorithm, the problem of insufficient trajectory tracking accuracy and stability during crane turning is solved, achieving higher accuracy and more stable turning control.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-19
- Publication Date
- 2026-03-10
AI Technical Summary
In existing technologies, it is difficult to simultaneously ensure trajectory tracking accuracy and turning stability when a crane is running on a turning track, especially due to insufficient trajectory tracking accuracy or vehicle instability caused by the non-optimization of prediction time-domain parameters in the MPC model.
The particle swarm optimization (PSO) algorithm is used to simultaneously optimize the prediction time-domain and control time-domain parameters of the model predictive control (MPC). By designing fitness functions and cost functions, the weight matrix is adjusted to improve trajectory tracking accuracy and turning stability.
This technology enables the crane to travel along the centerline of the track during turning, reducing rail wear, improving the accuracy and stability of trajectory tracking during turning, and reducing maintenance costs.
Smart Images

Figure CN121626097A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of automatic control technology of construction machinery, and more particularly, to a four-track crane turning control method based on PSO-MPC and a computer program product. BACKGROUND
[0002] With the development of shipbuilding technology and port trade and the increase of sea trade benefits, container ships are continuously increasing in size. In order to meet the demand, cranes also show a trend of large-scale and heavy-duty. In order to prevent excessive wheel pressure from damaging the site, the number of wheels and tracks is usually increased to share the weight.
[0003] Due to site restrictions and special requirements such as loading and unloading efficiency, sometimes the crane needs to run on a turning track. The turning guide of wheel-rail vehicles usually relies on the contact between the wheel flange or guide wheel and the track to achieve it. Some high-speed running wheel-rail vehicles also use conical wheels and set the outer track superhigh to increase the self-guiding ability of the vehicle. However, the above methods have high manufacturing and maintenance costs and cannot guarantee that the crane can accurately run along the track centerline during turning operation, which is prone to rail biting phenomenon, reducing the service life of the wheel-rail and increasing the maintenance cost, and also affecting the turning stability of the crane.
[0004] Chinese patent application with publication number CN114510063A discloses a track tracking control method for unmanned tracked vehicles. A model predictive control (MPC) model is generated based on the target function of the track tracking controller and the constraint function of the track tracking controller. The reference track and vehicle track tracking response state information are input into the MPC model to obtain a parameter combination. The parameter combination is input into an MLP neural network to optimize the length and step of the control time domain to obtain control parameters. The track tracking control of the unmanned tracked vehicle is completed according to the control parameters. However, the prediction time domain parameters in the MPC also need to be optimized. If the prediction time domain parameters in the MPC are too large, the track tracking accuracy will be affected, and if they are too small, the stability of the vehicle will be affected. Therefore, how to optimize the prediction time domain and control time domain in the MPC model to improve the track tracking accuracy and turning stability is a technical problem that needs to be solved. SUMMARY
[0005] In view of the above defects of the prior art, the present application provides a four-track crane turning control method based on PSO-MPC and a computer program product. An active control method is used for the low-speed heavy-load wheel-rail running vehicle, i.e. the crane. The prediction time domain and control time domain parameters of the MPC are simultaneously optimized by the particle swarm optimization (PSO) algorithm, thereby synchronously improving the accuracy of track tracking and the turning stability.
[0006] To achieve the above object, in one aspect, the application provides a four-track crane turning control method based on PSO-MPC, characterized in that it comprises the following steps:
[0007] Step S10: obtaining reference information of a reference trajectory; the reference trajectory is a center line of four tracks; the reference information comprises reference longitudinal positions of centers of two front wheel pairs, reference transverse positions of centers of two front wheel pairs, reference longitudinal positions of centers of two rear wheel pairs, reference transverse positions of centers of two rear wheel pairs, a front wheel pair reference turning angle and a rear wheel pair reference turning angle;
[0008] Step S20: obtaining actual information in a crane running process; the actual information comprises actual longitudinal positions of centers of two front wheel pairs , actual transverse positions of centers of two front wheel pairs , actual longitudinal positions of centers of two rear wheel pairs , actual transverse positions of centers of two rear wheel pairs , an actual front wheel pair turning angle , an actual rear wheel pair turning angle , an actual yaw angle and an actual vehicle speed ;
[0009] Step S30: establishing a crane kinematics equation based on the actual information to obtain a kinematics state space equation; designing an MPC strategy according to the kinematics state space equation of the crane and the reference information; predicting output state quantities in future time steps based on state quantities at a current time point;
[0010] Step S40: performing real-time optimization on a prediction time domain and a control time domain of the MPC by using a PSO algorithm: constructing a fitness function of the PSO algorithm to optimize time domain parameters of the MPC to obtain optimal time domain parameters;
[0011] Step S50: constructing a cost function Cost of the MPC according to the optimal time domain parameters, and adjusting values of a weight matrix according to requirements for trajectory accuracy and stability of the crane during turning.
[0012] Further, in the step S10, the front wheel pair reference turning angle and the rear wheel pair reference turning angle are calculated by the following formula:
[0013] ,
[0014] wherein, is the reference longitudinal position of the center of the two front wheel pairs, is a reference longitudinal position of the center of the pair of front wheels on the two sides, is a reference longitudinal position of the center of the pair of rear wheels on the two sides, is a reference lateral position of the center of the pair of front wheels on the two sides, , and , are coordinates of two adjacent reference coordinate points on the reference path, respectively.
[0015] Further, in the step S20, the actual longitudinal positions of the centers of the pair of front wheels on the two sides , the actual lateral positions of the centers of the pair of front wheels on the two sides , the actual longitudinal positions of the centers of the pair of rear wheels on the two sides , and the actual lateral positions of the centers of the pair of rear wheels on the two sides are obtained by position sensors arranged on the crane; the actual turning angles of the pair of front wheels and the actual turning angles of the pair of rear wheels are obtained by steering encoders on the crane; the actual yaw angles are obtained by angle sensors arranged on the crane; and the actual vehicle speeds are obtained by travel encoders on the crane.
[0016] Further, in the step S30, the kinematic equation of the crane is as follows:
[0017] ,
[0018] wherein, is the base distance of the crane, that is, the horizontal distance between the center lines of the two support points of the crane on the same track;
[0019] the state variable is selected as , the control variable is , a constraint interval is set for the control variable and the change of the control variable, and the kinematic equation is expressed as ;
[0020] the kinematic equation is discretized using the forward Euler method, and the kinematic equation is linearized to obtain the kinematic state space equation of the crane; based on the actual state variable of the crane at the current time, the output state variable at the future time steps is predicted by the MPC strategy and is as follows:
[0021] ,
[0022] wherein, represents the output quantity sequence in the prediction time domain, is the output quantity of the kinematic state space equation. A is a system matrix, C is an output matrix, is a new state variable composed of state variable x and control variable u; B is an input matrix, D is a transfer matrix, denotes a control increment sequence in a control time domain, is an increment of control variable, , denotes a linearization error sequence, is a prediction time domain, is a control time domain; for control variable U and the change amount of control variable set a constraint interval.
[0023] Further, in the step S40, the fitness of the PSO algorithm is:
[0024] .
[0025] Further, in the step S50, the cost function of the MPC is:
[0026] ,
[0027] wherein, is an output variable, is a reference output variable, , is a weight matrix, is a weight coefficient, is a relaxation factor;
[0028] The output state variable formula of the MPC strategy based on the optimal time domain parameters and is brought into the cost function to obtain a final cost function:
[0029]
[0030] wherein, , and are diagonal matrices with weight matrix Q and R respectively, is a reference output variable sequence.
[0031] Further, in the step S50, the values of the weight matrix are adjusted according to the importance of the position and the turning angle of the wheel pair of the crane in the running process in the trajectory tracking process; the values of the weight matrix are adjusted according to the importance of the stability of the crane in the running process.
[0032] In another aspect, the present application provides a computer program product for turning control of a four-rail crane; when the computer program product is run on a computer or device, the computer or device is caused to perform the PSO-MPC-based turning control method of a four-rail crane as described above.
[0033] Compared with the prior art, the present application has the following advantages or beneficial effects:
[0034] (1) The present application realizes trajectory tracking of the crane by MPC, so that the crane travels along the center line of the track during turning, reduces the phenomenon of biting the rail, and increases the running stability.
[0035] (2) The present application realizes synchronous real-time optimization of the prediction time domain and the control time domain of MPC by the PSO algorithm, further increases the trajectory tracking accuracy and turning stability of the crane during turning. BRIEF DESCRIPTION OF DRAWINGS
[0036] The present application and its features and advantages will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings. The same reference signs indicate the same parts throughout the drawings.
[0037] Figure 1 is a flowchart of the turning control method of a four-rail crane in an embodiment of the present application.
[0038] Figure 2 is a schematic diagram of the turning reference trajectory of a four-rail crane in an embodiment of the present application. DETAILED DESCRIPTION
[0039] The present application will be further described below with reference to the accompanying drawings and specific embodiments, but is not limited thereto.
[0040] The order of execution of the actions, steps, etc. in the devices and methods shown in the claims, specification and drawings can be implemented in any order unless the order is specifically limited by the context, and the output of the previous processing is not necessarily used in the subsequent processing.
[0041] In the following detailed description, many specific details are set forth in order to provide a more thorough understanding of the present application. However, it will be apparent to one skilled in the art that well-known algorithms and models are not shown in detail to avoid obscuring the subject matter of the present application.
[0042] EMBODIMENT
[0043] Reference Figure 1 The present embodiment provides a PSO-MPC-based turning control method of a four-rail crane, comprising the following steps:
[0044] Step S10, obtaining reference information of a reference trajectory;
[0045] Specifically, reference information of a reference path is obtained, and the reference path is attached to the reference trajectory Figure 2 For the reference trajectory diagram in the embodiment of the present application, the reference path is the center line of four tracks, and the obtained reference information includes the reference longitudinal position of the center of the front wheel pair on both sides , the reference lateral position of the center of the front wheel pair on both sides , the reference longitudinal position of the center of the rear wheel pair on both sides , the reference lateral position of the center of the rear wheel pair on both sides , the reference turning angle of the front wheel pair , the reference turning angle of the rear wheel pair The reference turning angle is calculated by the following formula:
[0046]
[0047] wherein, , and , are the coordinates of the adjacent two reference coordinate points on the reference path.
[0048] Step S20, obtaining actual information of the crane in the driving process;
[0049] Specifically, the actual information of the crane in the driving process is obtained, including the actual longitudinal position of the center of the front wheel pair on both sides of the crane , the actual lateral position of the center of the front wheel pair on both sides , the actual longitudinal position of the center of the rear wheel pair on both sides , the actual lateral position of the center of the rear wheel pair on both sides , the actual turning angle of the front wheel pair , the actual turning angle of the rear wheel pair , the actual yaw angle , the actual vehicle speed .
[0050] The actual longitudinal position of the center of the front wheel pair on both sides , the actual lateral position of the center of the front wheel pair on both sides , the actual longitudinal position of the center of the rear wheel pair on both sides , the actual lateral position of the center of the rear wheel pair on both sides can be obtained by the position sensor arranged on the crane, the actual turning angle of the front wheel pair , the actual turning angle of the rear wheel pair can be obtained by the steering encoder on the crane, the actual yaw angle can be obtained by the angle sensor arranged on the crane, and the actual vehicle speed can be obtained by the walking encoder on the crane.
[0051] Step S30, design the MPC strategy according to the kinematic model of the crane;
[0052] The kinematic equation of the crane is established, as shown in equation (2):
[0053]
[0054] wherein, is the base span of the crane, that is, the horizontal distance between the center lines of the two support points of the crane on the same track.
[0055] The state variable is selected as , and the control variable is . The system can be represented as .
[0056] Discretization of the system using the forward Euler method can obtain , is the sampling step, which is defined as .
[0057] The system is linearized again, and the new state variable and the output variable are taken, and the kinematic state space equation is as shown in equation (3):
[0058]
[0059] wherein, , , , , , , , , , the Jacobian matrix , ,
[0060] ,
[0061] ,
[0062] .
[0063] The MPC strategy of the crane can be designed through the kinematic state space equation.
[0064] Based on the actual state variable of the crane at the current moment, the output state variable at the future time steps can be predicted as shown in equation (4):
[0065]
[0066] wherein, , ,
[0067] , , , , is the prediction horizon, is the control horizon.
[0068] In order to ensure the safe operation of the crane, the control quantity can be constrained:
[0069]
[0070]
[0071] Step S40, constructing the fitness function of PSO algorithm to optimize the time domain parameters of MPC;
[0072] The PSO algorithm is used to optimize and in real time.
[0073] The population is initialized and set, and there are two-dimensional particles in total, and the maximum number of iterations is The initial position of each particle can be represented as:
[0074]
[0075] And each particle has a flight speed:
[0076]
[0077] When the th generation of particle evolution is the th generation of particle, the position and speed are:
[0078]
[0079] wherein, is the inertia weight, is the individual learning coefficient, is the global learning coefficient, and are random numbers in [0, 1], is the The optimal position of the individual in the sub-iteration, For The global optimal position in the sub-iteration.
[0080] The fitness function is used to evaluate the pros and cons of the particle position. Considering that a larger prediction time domain will increase the calculation amount of the model, the fitness function used is:
[0081]
[0082] The output quantity and the reference output quantity and the prediction time domain parameter N p At the same time, the fitness function can balance the tracking accuracy and the calculation amount, and prevent the calculation amount from being too large due to the pursuit of accuracy.
[0083] Step S50, construct the cost function Cost of MPC, adjust the numerical value of the weight matrix according to the demand;
[0084] Get the optimal time domain parameter , The cost function of MPC is established as formula (9):
[0085]
[0086] Among them, is the output quantity, is the reference output quantity, , is the weight matrix, is the weight coefficient, is the relaxation factor.
[0087] The cost function is obtained by bringing formula (4) into formula (9):
[0088]
[0089] Among them, , and are matrices with weight matrix Q and R as the diagonal, , is the reference output quantity sequence.
[0090] The cost function is converted into a quadratic form:
[0091]
[0092] Among them, , , .
[0093] In some embodiments, adjusting the weight matrix of the cost function includes: adjusting the weight matrix according to the position of the wheelsets and the importance of the turning angle in the trajectory tracking process during the crane's operation. The numerical values; the weight matrix is adjusted according to the importance of the crane's stability during operation. The value.
[0094] Cost function weight matrix and It can be adjusted according to the requirements of the accuracy and stability of the crane's trajectory tracking, ensuring that the crane can stably track the center line of the track; and the time domain parameters of MPC are continuously updated and optimized as the crane travels, further increasing the accuracy of the crane during curve operation.
[0095] The aforementioned four-rail crane turning control method can be implemented as a computer program product or a software functional unit. If the aforementioned four-rail crane turning control method is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. When the computer program product is run on a computer or device, it causes the computer or device to execute the four-rail crane turning control method as described above.
[0096] Those skilled in the art will recognize that the units, i.e., algorithm steps, of the various examples described in connection with this embodiment can be implemented in electronic hardware or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0097] Those skilled in the art should understand that variations can be implemented by combining existing technology with the above embodiments, which will not be elaborated here. Such variations do not affect the essential content of the present invention and will not be elaborated here. Any simple modifications, equivalent changes, and alterations made to the above embodiments based on the technical essence of the present invention without departing from the content of the technical solution of the present invention shall still fall within the protection scope of the technical solution of the present invention.
Claims
1. A PSO-MPC-based four-rail crane turning control method, characterized in that, The method comprises the following steps: Step S10: obtaining reference information of a reference trajectory; The reference trajectory is a center line of four tracks; the reference information comprises a reference longitudinal position of a center of a front wheel pair on both sides, a reference transverse position of a center of the front wheel pair on both sides, a reference longitudinal position of a center of a rear wheel pair on both sides, a reference transverse position of a center of the rear wheel pair on both sides, a reference turning angle of the front wheel pair, and a reference turning angle of the rear wheel pair; Step S20: acquiring actual information in the traveling process of the crane; the actual information includes actual longitudinal positions of the front wheel pair centers on both sides of the crane , actual lateral positions of the front wheel pair centers on both sides of the crane , actual longitudinal positions of the rear wheel pair centers on both sides of the crane , actual lateral positions of the rear wheel pair centers on both sides of the crane , actual turning angles of the front wheel pairs , actual turning angles of the rear wheel pairs , actual yaw angles , and actual vehicle speeds ; Step S30: establishing a crane kinematics equation based on the actual information to obtain a kinematics state space equation; designing an MPC strategy according to the kinematics state space equation of the crane and the reference information; predicting output state quantities in future time steps based on current state quantities at a current time point; Step S40: using particle swarm optimization algorithm to optimize the prediction time domain of MPC and control time domain Real-time optimization: constructing fitness function of particle swarm optimization algorithm to optimize the time domain parameters of MPC to obtain optimal time domain parameters; Step S50: constructing a cost function Cost of MPC according to the optimal time domain parameters, and adjusting a value of a weight matrix according to a demand for trajectory accuracy and stability of the crane during turning.
2. The PSO-MPC based four-rail crane turning control method according to claim 1, characterized in that, In the step S10, the front wheel pair reference angle and the rear wheel pair reference angle is calculated from the following equation: , wherein is a reference longitudinal position of the center of the pair of front wheels on the left side, is a reference lateral position of the center of the pair of front wheels on the left side, is a reference longitudinal position of the center of the pair of rear wheels on the left side, is a reference lateral position of the center of the pair of rear wheels on the left side, , and , are coordinates of two adjacent reference coordinate points on the reference path, respectively.
3. The PSO-MPC based four-rail crane turning control method according to claim 1, characterized in that, the actual longitudinal position of the center of the front wheel pair on both sides the actual lateral position of the center of the front wheel pair on both sides the actual longitudinal position of the center of the rear wheel pair on both sides the actual lateral position of the center of the rear wheel pair on both sides obtained by a position sensor provided on the crane; the actual turning angle of the front wheel pair the actual turning angle of the rear wheel pair obtained by a steering encoder on the crane; the actual yaw angle obtained by an angle sensor provided on the crane; the actual vehicle speed obtained by a traveling encoder on the crane.
4. The PSO-MPC based four-rail crane turning control method of claim 1, wherein, In the step S30, a kinematics equation of the crane is as follows: , wherein, L is the base span of the crane, i.e. the horizontal distance between the center lines of the two support points of the crane on the same track; The selected state quantity is , the control quantity is , and the kinematics equation can be expressed as ; The kinematic equations are discretized using the forward Euler method, and then linearized to obtain the kinematic state-space equations of the crane; based on the current... The actual state of the crane at any given time is used to predict future states using the MPC strategy. The output state variables at each time step are shown in the following formula: , wherein denotes a sequence of output quantities in the prediction horizon, is an output quantity of the kinematic state space equation; A is a system matrix and C is an output matrix, is a new state quantity composed of the state quantity x and the control quantity u; B is an input matrix and D is a transfer matrix, denotes a sequence of control increments in the control horizon, is an increment of the control quantity, , denotes a sequence of linearization errors, is a prediction horizon, is a control horizon; for the control quantity U and the change quantity a constraint interval is set.
5. The PSO-MPC based four-rail crane turning control method according to claim 4, characterized in that, In the step S40, a fitness function fitness of the particle swarm optimization algorithm is as follows: 。 6. The PSO-MPC based four-rail crane turning control method according to claim 5, characterized in that, In the step S50, a cost function of the MPC is as follows: , wherein, is an output quantity, is a reference output quantity, , is a weight matrix, is a weight coefficient, is a relaxation factor; The output state quantity formula of the MPC strategy based on the optimal time domain parameters and is substituted into the cost function to obtain a final cost function as follows: wherein , are matrices diagonal in the weight matrices Q and R, respectively, , is a sequence of reference output quantities.
7. The PSO-MPC based four-rail crane turning control method according to claim 6, characterized in that, In the step S50, the values of the weight matrix are adjusted in accordance with the importance of the position of the wheel set of the crane during travel and the turning angle during trajectory tracking , and the values of the weight matrix are adjusted in accordance with the importance of the stability of the crane during travel .
8. A computer program product, characterised in that, The computer program product is used for turning control of a four-track crane, and when the computer program product runs on a computer or a device, the computer or the device performs the PSO-MPC-based four-track crane turning control method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Unmanned tracked vehicle and trajectory tracking control method and system thereof
CN114510063A