A method, system, device and medium for predicting speed of medium and low speed maglev train
By obtaining the actual operating data of medium and low-speed maglev trains and using the improved particle swarm algorithm to optimize the LSTM model, the problem of difficult determination of electro-hydraulic hybrid braking parameters for medium and low-speed maglev trains is solved, and accurate prediction and control of the speed of maglev trains are achieved. .
Patent Information
- Application Number
- CN202311504011.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-13
- Publication Date
- 2024-08-30
- Estimated Expiration
- 2043-11-13
Smart Images

Figure CN117818706B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of maglev train operation control, and in particular to a method, system, equipment and medium for predicting the speed of a medium- and low-speed maglev train. Background Art
[0002] As a new type of modern high-tech rail transit tool, maglev trains are an important development direction for future urban rail transit. At the same time, medium and low-speed maglev trains are particularly suitable for connecting cities, suburbs, inter-city and tourist attractions, and have received widespread attention in the field of urban rail transit. The parameters of the maglev train mechanism model are difficult to obtain, and the operating conditions are complex. Establishing an accurate maglev train model is a very challenging research direction.
[0003] The operation process of a maglev train includes traction and braking, of which the braking part consists of three parts: electric braking, electro-hydraulic hybrid braking and hydraulic braking. In particular, the parameters of the electro-hydraulic hybrid braking and hydraulic braking of medium and low-speed maglev trains are difficult to determine, so it is difficult to achieve precise control of the maglev train using the mechanism model method. Summary of the invention
[0004] The purpose of the present invention is to provide a method, system, device and medium for predicting the speed of a medium- and low-speed maglev train, which can build a model based on data drive and realize precise control of the maglev train.
[0005] To achieve the above object, the present invention provides the following solutions:
[0006] A method for predicting the speed of a medium- and low-speed maglev train, comprising:
[0007] Obtain actual operation data of medium and low speed maglev trains;
[0008] Performing unit normalization and force calculation on the actual operation data to obtain the speed and force of the medium- and low-speed maglev train at the current moment;
[0009] The speed, the force and the improved PSO method are used to optimize the number of hidden layer nodes and the learning rate of the LSTM model, and the speed of medium and low speed maglev trains is predicted based on the LSTM model after the optimized parameters.
[0010] Optionally, the obtaining of actual operation data of medium and low speed maglev trains specifically includes:
[0011] The actual operation data between two stations of the target maglev line is collected every 0.2 seconds, and the collected train speed and acceleration corresponding to the gear are determined as the actual operation data.
[0012] Optionally, the unit unification and force calculation of the actual operation data to obtain the speed and force of the medium- and low-speed maglev train at the current moment specifically includes:
[0013] First, the actual operation data is subjected to unit-unified processing to obtain unit-unified position information, speed information, and acceleration information;
[0014] Then, the dynamics formula of the maglev train is used in combination with the vehicle information to calculate the force, and the size of different positions of the maglev train is obtained; the dynamics formula is:
[0015]
[0016] Among them, W is the basic resistance of the maglev train, W m is the magnetic resistance, W a is the aerodynamic drag, W c is the collector resistance, F is the force of the maglev train during operation, Q is the additional resistance, Q i Add resistance to the ramp; Q r Add resistance to the curve; F 阻 is the total resistance; M is the mass of the train; a is the acceleration.
[0017] Optionally, the using the speed, the force and the improved PSO method to perform parameter optimization on the number of hidden layer nodes and the learning rate of the LSTM model specifically includes:
[0018] The force and speed at the current moment are used as the input of the model, and the speed at the next moment is used as the output of the model to build an LSTM model.
[0019] The improved PSO method is used to optimize the number of hidden layer nodes and the learning rate of the LSTM model. If the maximum number of iterations is reached, the parameters corresponding to the maximum number of iterations are assigned to the LSTM model as the optimal parameters for training, and the predicted value is output; otherwise, the previous step is returned to continue iterating until the maximum number of iterations is met.
[0020] Optionally, the method uses the force and speed at the current moment as the input of the model and the speed at the next moment as the output of the model to construct the LSTM model, specifically including:
[0021] The kinematic equation at time t+1 is as follows:
[0022] v(t+1)=v(t)+a(t)ΔT
[0023] Substituting the expression of acceleration into the kinematic equation, we can obtain the dynamic model of the train under the action of force:
[0024]
[0025] Where ΔT is the time interval; F is the force on the maglev train during operation; F 阻 is the total resistance; M is the mass of the train; a is the acceleration; v is the speed;
[0026] Before feeding the data into the model, normalize the data:
[0027]
[0028] Among them, x is the original data, x n is the processed data, x min is the minimum value of the data, x max is the maximum value of the data.
[0029] Optionally, the optimizing the number of hidden layer nodes and the learning rate of the LSTM model by using the improved PSO method specifically includes:
[0030] Step 1: Initialize the particle swarm parameters, determine the number of swarm particles, dimension, learning factor, inertia weight and maximum number of iterations, and limit the value range of variables;
[0031] Step 2: The input layer of the LSTM model is determined by the two variables of the train's current speed and force as network input, the output layer is determined by the variable of the speed at the next moment, and the learning rate and the number of hidden layer nodes are determined by PSO optimization;
[0032] Step 3: Determination of fitness function: The fitness function is determined by the mean square error between the actual value and the predicted value of the LSTM model;
[0033]
[0034] Where n is the total number of data samples, is the true value, y t is the predicted value;
[0035] Step 4: Particle optimization replacement; update speed and position until the predetermined number of iterations is reached, the particles continue to optimize and replace to reach the optimal parameters, and the optimal parameter combination at this time is input into the LSTM model; the optimal parameter combination includes the learning rate and the number of hidden layer nodes;
[0036] The update formula for speed and position is as follows:
[0037] v ld k+1 =wv ld k +c 1 r 1 (pbestld -x ld k )+c 2 r 2 (gbest d -x ld k )
[0038] x ld k+1 =x ld k +v ld k+1
[0039] Where w is the inertia weight, d = 1, 2, 3, K, D, D represents the dimension of the particle, r 1 and r 2 is a random number in the range [0,1], v ld k is the velocity of the particle at time k, c 1 and c 2 is the learning factor, gbest d is the value of the global optimal position of the entire particle swarm in dimension d, pbest ld is the value of the optimal position of the lth individual in dimension d, x ld k is the position of the lth particle at time k;
[0040] The value of the inertia weight in the particle swarm algorithm update formula is improved to change with the change of the particle fitness value. The expressions of the improved weight and learning factor are as follows:
[0041]
[0042]
[0043] In the formula, w max is the set maximum inertia value, w min is the set minimum inertia value, w is the inertia weight, f is the current fitness value, f min is the minimum fitness value, f ave is the average fitness value, c max is the maximum learning factor set, c min is the set minimum learning factor, i is the current iteration number, and T is the total iteration number.
[0044] The present invention also provides a medium- and low-speed maglev train speed prediction system, comprising:
[0045] Data acquisition module, used to obtain the actual operation data of the maglev train;
[0046] A unit unification and force calculation module, used to perform unit unification and force calculation on the actual operation data to obtain the speed and force of the maglev train at the current moment;
[0047] The model building and speed prediction module is used to optimize the number of hidden layer nodes and the learning rate of the LSTM model by using the speed, the force and the improved PSO method, and predict the speed of the maglev train according to the LSTM model after the optimized parameters.
[0048] The present invention also provides an electronic device, comprising a memory and a processor, wherein the memory is used to store a computer program, and the processor runs the computer program to enable the electronic device to execute the above-mentioned low-speed maglev train speed prediction method.
[0049] The present invention also provides a computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the method for predicting the speed of a medium- and low-speed maglev train as described above.
[0050] According to the specific embodiments provided by the present invention, the present invention discloses the following technical effects:
[0051] The present invention discloses a method, system, device and medium for predicting the speed of a medium- and low-speed maglev train, the method comprising obtaining actual operation data of the maglev train; unitizing and calculating the force of the actual operation data to obtain the speed and force of the maglev train at the current moment; optimizing the number of hidden layer nodes and the learning rate of the LSTM model using the speed, the force and the improved PSO method, and predicting the speed of the maglev train according to the LSTM model after optimizing the parameters. The present invention can establish an LSTM model according to the speed and force data of the maglev train, and in order to improve the shortcomings of the traditional LSTM model in the prediction, such as the difficulty in parameter selection and the inaccurate prediction, the improved particle swarm algorithm is used to optimize the number of hidden layer nodes and the learning rate and apply them to the model, thereby enhancing the model prediction performance, obtaining a better modeling effect, and facilitating the accurate control of the maglev train. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0053] Figure 1 It is a schematic diagram of the flow chart of the method for predicting the speed of a low-speed maglev train in the present invention;
[0054] Figure 2 The figure is a schematic diagram of the improved LSTM model algorithm flow in this embodiment. DETAILED DESCRIPTION
[0055] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0056] The purpose of the present invention is to provide a method, system, device and medium for predicting the speed of a medium- and low-speed maglev train, which can build a model based on data drive and realize precise control of the maglev train.
[0057] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.
[0058] like Figure 1-Figure 2 As shown, the present invention provides a method for predicting the speed of a medium- and low-speed maglev train, comprising:
[0059] Step 100: Acquire actual operation data of the maglev train;
[0060] Step 200: normalize the actual operation data and calculate the force to obtain the speed and force of the maglev train at the current moment; sample the operation data between two stations in batches, and divide the data obtained from different batches into training sets and test sets, respectively.
[0061] Step 300: Utilizing the speed, the force and the improved PSO method, the number of hidden layer nodes and the learning rate of the LSTM model are optimized, and the speed of the maglev train is predicted based on the LSTM model after the optimized parameters.
[0062] As a specific implementation, step 100 specifically includes:
[0063] The actual operation data between two stations of the target maglev line is collected every 0.2 seconds, and the collected train speed and acceleration corresponding to the gear are determined as the actual operation data.
[0064] As a specific implementation, step 200 specifically includes:
[0065] First, the actual operation data is processed into a unified unit to obtain position information s, velocity information v and acceleration information a with unified units; the units are processed into a unified unit, that is, converted into international standard units.
[0066] According to the position information s, the line characteristic information corresponding to the position of the maglev train, that is, the slope information i and the curvature information R, is obtained.
[0067] Then, according to the vehicle information and line characteristic information and combined with the following dynamic formula of the maglev train, the basic resistance W and additional resistance Q at different positions of the maglev train are calculated, thereby calculating the size of F at different positions of the maglev train. The dynamic formula is:
[0068]
[0069] Among them, W is the basic resistance of the maglev train, W m is the magnetic resistance, W a is the aerodynamic drag, W c is the collector resistance, F is the force of the maglev train during operation, Q is the additional resistance, Q i Add resistance to the ramp; Q r Add resistance to the curve; F 阻 is the total resistance; M is the mass of the train; a is the acceleration.
[0070] If a>0 and F≠0, the maglev train is in a traction state, and the F obtained at this time is the traction force; if a<0 and F≠0, the maglev train is in a braking state, and the F obtained at this time is the braking force; if a=0, the maglev train is in a cruising state, and the F obtained at this time is the force to keep the train cruising, which is opposite to the resistance; if F=0, the maglev train is in an idling state, and the train operation is only affected by the resistance.
[0071] As a specific implementation, step 300 specifically includes:
[0072] Step 310: Using the force and speed at the current moment as the input of the model and the speed at the next moment as the output of the model, construct an LSTM model;
[0073] Step 320: Use the improved PSO method to optimize the number of hidden layer nodes and the learning rate of the LSTM model. If the maximum number of iterations is reached, the parameters corresponding to the maximum number of iterations are assigned as the optimal parameters to the LSTM model for training, and the predicted value is output; otherwise, return to the previous step to continue iterating until the maximum number of iterations is met.
[0074] Step 310 specifically includes:
[0075] The kinematic equation at time t+1 is as follows:
[0076] v(t+1)=v(t)+a(t)ΔT
[0077] Substituting the expression of acceleration into the kinematic equation, we can obtain the dynamic model of the train under the action of force:
[0078]
[0079] Where ΔT is the time interval; F is the force on the maglev train during operation; F 阻 is the total resistance; M is the mass of the train; a is the acceleration; v is the speed;
[0080] Through the above analysis, the speed of the maglev train at time t+1 is related to the speed at time t and the force of the train. Therefore, the force and speed at the current moment are selected as the input of the model, and the speed at the next moment is used as the output of the model.
[0081] When inputting data into the model, if the data input is too large, it will affect the training effect of the model, so the data must be normalized first:
[0082]
[0083] Among them, x is the original data, x n is the processed data, x min is the minimum value of the data, x max is the maximum value of the data.
[0084] Long Short Term Memory (LSTM) is an improved recurrent neural network proposed by scholars in 1997. It is suitable for processing and predicting time series with large time intervals and high correlation. Its characteristics are that three gates are added to the hidden layer: forget gate, input gate and output gate. Through these three gates, LSTM can selectively remember or forget information and maintain the memory state, and useless information in the propagation process will be forgotten.
[0085] Forget gate: The forget gate is based on the output information h extracted from the previous moment. t-1 and the current input x t , use the activation function sigmoid to map the input data information to the interval [0,1] to obtain f t . It is used to control whether to retain the data feature information in the memory unit, and its formula is shown in the formula.
[0086] f t =σ(W f h t-1 +U f x t +b f )
[0087] Input gate: the state vector C at the current moment tUpdate and control the input data. First, use the activation function sigmoid to output i t , controls the degree of retention of new information at the current moment, and then uses the tanh function to obtain the output a of the input unit t , as the new amount of information input at the current moment, and finally according to a t and i t Output the current state vector C t . Its formula is shown in Eq.
[0088]
[0089] Output gate: controls the output of the next hidden state. t-1 and the current input x t Output O through the activation function sigmoid t , then the state vector C t and the tanh function outputs h t . Its formula is shown in Eq.
[0090]
[0091] Among them, σ activation function sigmoid, W f h t-1 To the weight of the forget gate, U f For x t To the weight of the forget gate, b f is the bias of the forget gate, W i h t-1 The weight to the input gate, U i For x t The weight to the input gate, b i is the bias of the input gate, W a h t-1 The weight of the input unit, U a For x t The weight of the input unit, b a is the bias of the input unit, W o h t-1 The weight to the output gate, U o For x t The weight to the output gate, b o is the bias of the output gate.
[0092] Step 320 specifically includes:
[0093] Specifically, particle swarm optimization (PSO) is a swarm intelligence algorithm proposed by researchers in 1995 based on the study of group behavior of birds and fish. Each particle represents an optimal solution, and the characteristics of the particle can be characterized by position, speed and fitness value. The principle is that the system first randomly initializes a group of particles, and then finds the optimal position through continuous iteration to obtain its optimal solution. During the iteration process, the particles update their individual positions by tracking individual extreme values and overall extreme values. Each time a particle updates its position, it calculates its fitness value, and updates the positions of individual extreme values and overall extreme values by comparing the fitness values of the new particles, individual extreme values and overall extreme values.
[0094] The specific steps are as follows:
[0095] Step 1: Initialize the particle swarm parameters, determine the number of swarm particles, dimension, learning factor, inertia weight and maximum number of iterations, and limit the value range of variables;
[0096] Step 2: The input layer of the LSTM model is determined by the two variables of the train's current speed and force as network input, the output layer is determined by the variable of the speed at the next moment, and the learning rate and the number of hidden layer nodes are determined by PSO optimization;
[0097] Step 3: Determination of fitness function: The fitness function is determined by the mean square error (MSE) between the actual value and the predicted value of the LSTM model;
[0098]
[0099] Where n is the total number of data samples, is the true value, y t is the predicted value;
[0100] Step 4: Particle optimization replacement; update speed and position until the predetermined number of iterations is reached, the particles continue to optimize and replace to reach the optimal parameters, and the optimal parameter combination at this time is input into the LSTM model; the optimal parameter combination includes the learning rate and the number of hidden layer nodes;
[0101] The update formula for speed and position is as follows:
[0102] v ld k+1 =wv ld k +c 1 r 1 (pbest ld -x ld k )+c 2 r2 (gbest d -x ld k )
[0103] x ld k+1 =x ld k +v ld k+1
[0104] Where w is the inertia weight, d = 1, 2, 3, K, D, D represents the dimension of the particle, r 1 and r 2 is a random number in the range [0,1], v ld k is the velocity of the particle at time k, c 1 and c 2 is the learning factor, gbest d is the value of the global optimal position of the entire particle swarm in dimension d, pbest ld is the value of the optimal position of the lth individual in dimension d, x ld k is the position of the lth particle at time k;
[0105] The inertia weight and learning factor of the standard PSO algorithm are fixed, and there are shortcomings such as low search accuracy and poor local search ability. When encountering complex nonlinear optimization problems, the algorithm is prone to fall into the local optimal solution. In order to better improve the performance of the algorithm, the adaptive weight method is used to improve the value of the inertia weight w in the particle swarm algorithm update formula to change with the change of the particle fitness value. When the particle fitness value is small, a larger inertia weight can help the particle jump out of the local optimal solution, so as to better explore the global optimal solution. When the particle fitness value is large, a smaller inertia weight can help the particle converge to the local optimal solution more stably. This method of dynamically adjusting the inertia weight can improve the convergence speed and search ability of the algorithm. The learning factor c in the update formula is updated. 1 and c 2 The value of is improved to change dynamically with the number of iterations, so that the algorithm has a strong global search capability at the beginning of the search, and gradually enhances the local search capability over time.
[0106] When encountering complex nonlinear optimization problems, in order to better improve the algorithm performance, the value of the inertia weight in the particle swarm algorithm update formula is now improved to change with the change of the particle fitness value. The expressions of the improved weight and learning factor are shown as follows:
[0107]
[0108]
[0109] In the formula, w max is the set maximum inertia value, w min is the set minimum inertia value, w is the inertia weight, f is the current fitness value, f min is the minimum fitness value, f ave is the average fitness value, c max is the maximum learning factor set, c min is the set minimum learning factor, i is the current iteration number, and T is the total iteration number.
[0110] Finally, the model training is completed through the iterative termination conditions, and the model is evaluated based on the data prediction effect.
[0111] There are two commonly used prediction error evaluation indicators, namely root mean square error (RMSE) and mean absolute error (MAE). These two evaluation indicators are defined by the following formulas.
[0112]
[0113] The invention proposes a data-driven medium- and low-speed maglev train LSTM model, which constructs a modeling analysis of the full-line data between two stations of the maglev train, and obtains good modeling accuracy, thereby solving the problem that it is difficult to mathematically analyze the state of hydraulic braking through a mechanism model due to the variable delay between the braking force and speed of the maglev train during actual operation. In view of the problems of small data volume and incomplete electric braking characteristics in the modeling of the electro-hydraulic hybrid stage of the maglev train, the full-line data is used for modeling. The LSTM model is established according to the speed and force data of the maglev train, and the shortcomings of difficult parameter selection and inaccurate prediction in the model are improved by an improved particle swarm algorithm. Secondly, the historical data of the actual medium- and low-speed maglev train operation on a certain maglev line is used as a sample, and experimental simulation is carried out to establish an improved medium- and low-speed maglev train LSTM prediction model. Finally, in order to verify the superiority of the improved LSTM prediction model, different models are selected for comparative experiments, and the accuracy of their errors is evaluated using different evaluation indicators. The accurate prediction of the speed of the maglev train is achieved, which is of great significance for the study of maglev train modeling.
[0114] The present invention also provides a medium- and low-speed maglev train speed prediction system, comprising:
[0115] Data acquisition module, used to obtain the actual operation data of the maglev train;
[0116] A unit unification and force calculation module, used to perform unit unification and force calculation on the actual operation data to obtain the speed and force of the maglev train at the current moment;
[0117] The model building and speed prediction module is used to optimize the number of hidden layer nodes and the learning rate of the LSTM model by using the speed, the force and the improved PSO method, and predict the speed of the maglev train according to the LSTM model after the optimized parameters.
[0118] The present invention also provides an electronic device, comprising a memory and a processor, wherein the memory is used to store a computer program, and the processor runs the computer program to enable the electronic device to execute the above-mentioned low-speed maglev train speed prediction method.
[0119] The present invention also provides a computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the method for predicting the speed of a medium- and low-speed maglev train as described above.
[0120] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0121] This article uses specific examples to illustrate the principles and implementation methods of the present invention. The above examples are only used to help understand the core idea of the present invention. At the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting the present invention.
Claims
1. A method for predicting the speed of a medium- and low-speed maglev train, characterized in that: include: Obtain actual operation data of medium and low speed maglev trains; Performing unit normalization and force calculation on the actual operation data to obtain the speed and force of the medium- and low-speed maglev train at the current moment; Utilizing the speed, the force and the improved PSO method, the number of hidden layer nodes and the learning rate of the LSTM model are optimized, and the speed of the medium and low speed maglev train is predicted according to the LSTM model after the optimized parameters; The method of optimizing the number of hidden layer nodes and the learning rate of the LSTM model by using the speed, the force and the improved PSO method specifically includes: The force and speed at the current moment are used as the input of the model, and the speed at the next moment is used as the output of the model to build an LSTM model. The improved PSO method is used to optimize the number of hidden layer nodes and the learning rate of the LSTM model. If the maximum number of iterations is reached, the parameters corresponding to the maximum number of iterations are assigned to the LSTM model as the optimal parameters for training, and the predicted value is output; otherwise, the previous step is returned to continue iterating until the maximum number of iterations is met; Furthermore, the force and speed at the current moment are used as the input of the model, and the speed at the next moment is used as the output of the model to construct the LSTM model, which specifically includes: The kinematic equation at time t+1 is as follows: v(t+1)=v(t)+a(t)ΔT Substituting the expression of acceleration into the kinematic equation, we can obtain the dynamic model of the train under the action of force: Where ΔT is the time interval; F is the force on the maglev train during operation; F 阻 is the total resistance; M is the mass of the train; a is the acceleration; v is the speed; Before feeding the data into the model, normalize the data: Among them, x is the original data, x n is the processed data, x min is the minimum value of the data, x max is the maximum value of the data.
2. The method for predicting the speed of a medium- and low-speed maglev train according to claim 1, characterized in that: The obtaining of actual operation data of the medium and low speed maglev train specifically includes: The actual operation data between two stations of the target maglev line is collected every 0.2 seconds, and the collected train speed and acceleration corresponding to the gear are determined as the actual operation data.
3. The method for predicting the speed of a medium- and low-speed maglev train according to claim 1, characterized in that: The unit unification and force calculation of the actual operation data to obtain the speed and force of the medium- and low-speed maglev train at the current moment specifically includes: First, the actual operation data is subjected to unit-unified processing to obtain unit-unified position information, speed information, and acceleration information; Then, the dynamics formula of the maglev train is used in combination with the vehicle information to calculate the force, and the size of different positions of the maglev train is obtained; the dynamics formula is: Among them, W is the basic resistance of the maglev train, W m is the magnetic resistance, W a is the aerodynamic drag, W c is the collector resistance, F is the force of the maglev train during operation, Q is the additional resistance, Q i Add resistance to the ramp; Q r Add resistance to the curve; F 阻 is the total resistance; M is the mass of the train; a is the acceleration.
4. The method for predicting the speed of a medium- and low-speed maglev train according to claim 1, characterized in that: The improved PSO method is used to optimize the number of hidden layer nodes and the learning rate of the LSTM model, specifically including: Step 1: Initialize the particle swarm parameters, determine the number of swarm particles, dimension, learning factor, inertia weight and maximum number of iterations, and limit the value range of variables; Step 2: The input layer of the LSTM model is determined by the two variables of the train's current speed and force as network input, the output layer is determined by the variable of the speed at the next moment, and the learning rate and the number of hidden layer nodes are determined by PSO optimization; Step 3: Determination of fitness function: The fitness function is determined by the mean square error between the actual value and the predicted value of the LSTM model; Where n is the total number of data samples, is the true value, y t is the predicted value; Step 4: Particle optimization replacement; update speed and position until the predetermined number of iterations is reached, the particles continue to optimize and replace to reach the optimal parameters, and the optimal parameter combination at this time is input into the LSTM model; the optimal parameter combination includes the learning rate and the number of hidden layer nodes; The update formula for speed and position is as follows: v ld k+1 =wv ld k +c1r1(pbest ld -x ld k )+c2r2(gbest d -x ld k ) x ld k+1 =x ld k +v ld k+1 Where w is the inertia weight, d = 1, 2, 3, K, D, D represents the dimension of the particle, r1 and r2 are random numbers in the range [0, 1], v ld k is the velocity of the particle at time k, c1 and c2 are learning factors, gbest d is the value of the global optimal position of the entire particle swarm in dimension d, pbest ld is the value of the optimal position of the lth individual in dimension d, x ld k is the position of the lth particle at time k; The value of the inertia weight in the particle swarm algorithm update formula is improved to change with the change of the particle fitness value. The expressions of the improved weight and learning factor are as follows: In the formula, w max is the set maximum inertia value, w min is the set minimum inertia value, w is the inertia weight, f is the current fitness value, f min is the minimum fitness value, f ave is the average fitness value, c max is the maximum learning factor set, c min is the set minimum learning factor, i is the current iteration number, and T is the total iteration number.
5. A medium- and low-speed maglev train speed prediction system, applied to the method according to any one of claims 1 to 4, characterized in that: include: Data acquisition module, used to obtain actual operation data of medium and low speed maglev trains; A unit unification and force calculation module, used to perform unit unification and force calculation on the actual operation data to obtain the speed and force of the medium and low speed maglev train at the current moment; The model building and speed prediction module is used to optimize the number of hidden layer nodes and the learning rate of the LSTM model by using the speed, the force and the improved PSO method, and predict the speed of medium and low speed maglev trains according to the LSTM model after optimizing the parameters.
6. An electronic device, characterized in that: It includes a memory and a processor, the memory is used to store a computer program, and the processor runs the computer program to enable the electronic device to execute the medium and low speed maglev train speed prediction method according to any one of claims 1-4.
7. A computer-readable storage medium, characterized in that: It stores a computer program, which, when executed by a processor, implements the method for predicting the speed of a medium- and low-speed maglev train as described in any one of claims 1-4.
Citation Information
Patent Citations
A train condition on-line prediction method based on long-short-time memory network
CN109131452A
Magnetically levitated train speed tracking method
CN114415510A
