An intelligent optimization method for cylinder piston sealing groove based on a new improved particle swarm algorithm
By applying a new improved particle swarm algorithm in the cylinder piston sealing groove, the problems of low efficiency of PID control parameter optimization and local optimal traps in traditional technology are solved, and the effectiveness of high-precision motion control and parameter optimization of cylinder piston is achieved.
Patent Information
- Application Number
- CN202210909052.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-29
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2042-07-29
AI Technical Summary
The prior art is difficult to effectively optimize the PID control parameters of the cylinder piston sealing groove, resulting in low cylinder motion control accuracy, and traditional particle swarm algorithms have shortcomings in the problems of local search and global search balance and local optimal jump out.
The intelligent optimization method of cylinder piston sealing groove based on a new improved particle swarm algorithm is adopted. Through adaptive inertial weights, improved position update formulas and new local optimal formulas, dynamically coordinate local search and global search, avoid local optimal traps, and judge system oscillation through the error change amount, and optimize PID control parameters.
High-precision motion control of cylinder piston seal groove is realized, the optimization efficiency of PID control parameters is improved, local and global searches are dynamically balanced, local optimization is effectively jumped out, optimization time is reduced and system oscillation is prevented.
Smart Images

Figure CN115268268B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of intelligent optimization, and in particular to an intelligent optimization method for a cylinder piston sealing groove based on a novel improved particle swarm algorithm. Background Art
[0002] Pneumatic systems are widely used in various industrial automation occasions due to their own advantages such as cleanliness, pollution-free, safety and reliability. As the actuator of the pneumatic system, the sealing performance of the cylinder plays a vital role in the normal operation of the system. As we all know, there are usually two types of seals inside the common cylinder, namely static seals and dynamic seals, both of which are for the purpose of preventing leakage. Therefore, in the design and manufacturing process of the cylinder, manufacturers often only focus on two aspects of sealing: leakproofness and wear resistance. Since the friction pair formed between the sealing ring on the cylinder piston and the inner wall of the cylinder will affect the motion servo control performance of the cylinder, the dynamic seal in the cylinder also needs to take on a new mission—movement as smooth as possible and control accuracy as high as possible. As far as the motion control accuracy of the cylinder is concerned, it is mainly affected by the friction generated by the dynamic seal. However, since friction is a nonlinear force affected by many factors, it has uncertainty, time-varying, and cannot be accurately modeled, so the direct relationship between friction and motion control accuracy cannot be clearly defined at present. Therefore, it is considered to use PID to test and optimize multiple seal grooves designed empirically, and select the seal groove with the best control accuracy with the cylinder motion control accuracy as the goal.
[0003] At present, the method for adjusting PID control parameters is usually manual adjustment based on experience. However, the "optimal" control parameters obtained in this way are highly subjective. In this regard, optimizing PID parameters through swarm intelligence optimization algorithms has outstanding advantages.
[0004] Particle swarm optimization algorithm is widely used in function optimization, path planning, target tracking, neural network training, controller parameter optimization, etc. due to its simple structure and few adjustment parameters. However, the traditional particle swarm optimization algorithm has problems such as low optimization accuracy, poor balance between local search and global search, and inability to effectively handle when the algorithm falls into local optimality. Summary of the invention
[0005] Based on the above reasons, the present invention provides an intelligent optimization method for cylinder piston sealing grooves based on a new improved particle swarm algorithm, which aims to dynamically coordinate the balance between local search and global search during the algorithm optimization process, and to effectively jump out when particles fall into local optimality, and to objectively and effectively obtain the optimal motion control accuracy of each sealing groove in a short time.
[0006] In order to achieve the above object, the present invention adopts the following technical solution:
[0007] An intelligent optimization method for cylinder piston sealing groove based on a novel improved particle swarm algorithm comprises the following steps:
[0008] S1: Design multiple seal grooves of different sizes for the cylinder piston according to mechanical design manual and experience;
[0009] S2: Build a cylinder motion trajectory tracking PID control test platform;
[0010] S3: roughly determining the value range of the PID controller parameters to be optimized to form a search space;
[0011] S4: Set the initial parameters of the new improved particle swarm algorithm, select the maximum error of the system in the trajectory tracking process as the fitness function of the algorithm, and determine the shrinkage threshold and shrinkage coefficient of the algorithm;
[0012] S5: A new improved particle swarm algorithm is used to optimize the cylinder PID motion trajectory tracking control parameters when the seal ring is located in different sealing grooves, and the sealing groove with the highest PID trajectory tracking control accuracy is selected;
[0013] S6: The optimal groove design dimensions are used as the final piston seal groove dimensions of the high-performance cylinder.
[0014] The step S5 specifically includes the following steps:
[0015] S51: Randomly generate initial particles in the search space, and the position vector X of each particle i The three control parameters K of PID p , K i and K d composition;
[0016] S52: Perform PID position control on each particle to obtain the fitness value of each particle;
[0017] S53: Count the fitness value of each particle, and record the individual best position of the ith particle and the global best position of the entire group after t iterations;
[0018] S54: Determine whether the global optimal position reaches the contraction threshold for the first time. If it does, re-divide the search space and randomly generate particles in the new search space, and then execute step S52; otherwise, execute step S55;
[0019] S55: Iterate and update all particles. The specific steps are as follows:
[0020] S551: Calculate the weight λ of the maximum difference of the i-th particle in all dimensions imax (t), adaptability coefficient μ, inertia weight w of the i-th particle iAnd the acceleration coefficients c1 and c2;
[0021] S552: Update particles using the velocity update formula and the improved position update formula;
[0022] S56: The number of iterations t is increased by 1. If the current number of iterations has reached the maximum number of iterations, the algorithm ends and outputs the optimal PID control parameters and the optimal fitness value. Otherwise, execute step S52.
[0023] Furthermore, the inertia weight w in step S551 i It can realize adaptive dynamic adjustment, and its calculation formula is:
[0024]
[0025] In the formula, t is the current iteration number, t max is the maximum number of iterations, and are the individual optimal fitness and global optimal fitness of the ith particle after t iterations, respectively, and w max and w min are the maximum and minimum inertia weights respectively.
[0026] Furthermore, the improved location update formula in step S552 includes: a standard location update formula, a new location update formula and a new local optimal escape formula. The improved location update formula is:
[0027]
[0028] Among them, the new position update formula is The standard position update formula is The new formula for escaping from the local optimum is:
[0029] In the formula, is the position vector of the ith particle after t iterations, is the global optimal position vector of the entire group after t iterations, is the velocity vector of the ith particle after t iterations, u and v are random numbers that obey Gaussian distribution, α is the variation factor, r3 is a random number in the range of [0, 1], and λ imax (t) is the weight of the maximum difference of the i-th particle in all dimensions, which can be described as:
[0030]
[0031] In the formula, x ik (t) is the k-th dimension value of the ith particle after t iterations, x gbk(t) is the k-th dimension value of the global best position after t iterations, λ ik (t) is x ik (t) and x gbk The weight of the difference between (t).
[0032] Furthermore, the formula of the random number u for adaptively adjusting the dispersion degree of Gaussian distribution introduced in the novel position update formula is:
[0033]
[0034] In the formula, σ u is the standard deviation of the random number u that obeys the Gaussian distribution, μ is the adaptability coefficient, and its formula is:
[0035]
[0036] Furthermore, the formula of the random number v obeying the Gaussian distribution introduced in the novel jump-out local optimal formula is:
[0037]
[0038] In the formula, σ v is the standard deviation of the random number v that follows the Gaussian distribution, r4 is a random number in [-1.5, 1.5], and r5 is a random number in [0, 1].
[0039] Furthermore, in step S54, the search space is re-divided according to the following formula:
[0040]
[0041] In the formula, k1 and k2 are contraction coefficients. is the global optimal position vector of the entire group after t iterations.
[0042] Furthermore, a first restriction is set for the process of step S52: a threshold is set for the fitness, and the period of PID position control is determined by monitoring the fitness value of each particle.
[0043] Furthermore, a second restriction is set for step S52: whether oscillation occurs is determined by the change in error during PID control, and a penalty mechanism is established based on this, that is, when the error change exceeds a certain range, the particle will automatically stop running and be assigned a poor fitness value.
[0044] The present invention proposes an intelligent optimization method for cylinder piston sealing groove based on a novel improved particle swarm algorithm, which has the following beneficial effects compared with the prior art:
[0045] 1) In the design of the cylinder piston sealing groove, the present invention not only ensures the traditional requirements of leak-proof and wear-resistant, but also provides performance indicators of cylinder control accuracy, aiming to meet the demand for high-precision control of the cylinder.
[0046] 2) The present invention proposes a novel improved particle swarm optimization algorithm, which has the characteristics of adaptive inertia weight, novel position update formula, novel jump out of local optimum formula and self-contraction of search space. Such a design not only improves the diversity of particle motion, but also dynamically coordinates the relationship between the local search and the global search of the algorithm, and can effectively jump out when the particles fall into the local optimum.
[0047] 3) The present invention determines whether the system oscillates by the change in error during the PID control process. When the error change exceeds a certain range, the particle will automatically stop running, which can effectively prevent system oscillation and protect experimental equipment. By monitoring whether the fitness value of each particle exceeds the set value, the cycle of PID position control is determined to reduce the optimization time. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] Figure 1 This is a flow chart of the intelligent optimization method for cylinder piston sealing groove based on the novel improved particle swarm algorithm proposed by the present invention;
[0049] Figure 2 Flow chart of the novel improved particle swarm algorithm proposed by the present invention;
[0050] Figure 3 This is a graph showing the particle swarm optimization results of a multi-sealing groove piston in an embodiment of the present invention. DETAILED DESCRIPTION
[0051] The following will be combined with the drawings in the examples of this application 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.
[0052] Reference Figure 1 and 2 The present invention provides an intelligent optimization method for cylinder piston sealing groove based on a novel improved particle swarm algorithm, comprising the following steps:
[0053] S1: Refer to the mechanical design manual and based on experience, process several sealing grooves of different sizes for the cylinder piston to be tested.
[0054] S2: Build a cylinder motion trajectory tracking PID control test platform.
[0055] S3: Roughly determine the value range of the PID controller parameters to be optimized to form a search space.
[0056] Specifically, the variation range of the three PID control parameters is determined by coarse tuning parameters or based on experience, and the variation range should be appropriately large in order to include the optimal parameters of PID control.
[0057] S4: Set the initial parameters of the new improved particle swarm algorithm, select the maximum error of the system in the trajectory tracking process as the fitness function of the algorithm, and determine the shrinkage threshold and shrinkage coefficient of the algorithm.
[0058] Specifically, the initial parameters of the novel improved particle swarm algorithm include the population size N, the maximum number of iterations t max , maximum and minimum inertia weights w max and w min and speed range
[0059] The fitness function is shown in formula (1).
[0060]
[0061] Where t is the current iteration number, is the position vector of the ith particle after t iterations, e max is the maximum steady-state error of the system.
[0062] S5: A new improved particle swarm algorithm is used to optimize the PID trajectory tracking control parameters when the sealing ring is located in different sealing grooves, and the sealing groove with the highest PID trajectory tracking control accuracy is selected.
[0063] Furthermore, the detailed steps of optimizing the PID control parameters by the novel improved particle swarm algorithm described in step S5 are as follows:
[0064] S51: Randomly generate initial particles in the search space, and the position vector X of each particle i The three control parameters K of PID p , K i and K d composition.
[0065] S52: Perform PID position control on each particle to obtain the fitness value of each particle.
[0066] Specifically, the following limitations exist in the process of performing a PID position control on each particle:
[0067] 1) Set a threshold for fitness, and determine the cycle of PID trajectory tracking control by monitoring the fitness value of each particle, so as to solve the problem of long control time caused by particles with poor control accuracy;
[0068] 2) Whether oscillation occurs is determined by the change in error during PID control, and a penalty mechanism is established based on this. That is, when the error change exceeds a certain range, the particle will automatically stop running and be assigned a poor fitness value, thereby solving the problem of cylinder oscillation caused by inappropriate PID parameters.
[0069] S53: Count the fitness value of each particle and record the individual best position of the i-th particle after t iterations and the global optimal position of the entire group
[0070] S54: Determine the global optimal fitness value Whether it is the first time to reach the contraction threshold, if it is satisfied, then re-divide the search space and randomly generate particles in the new search space, and then execute step S52; otherwise, execute step S55.
[0071] Specifically, the specific steps of re-dividing the search space and randomly generating particles in the new search space are: in the iterative process, when When the shrinkage threshold is reached for the first time, the search space is re-divided according to formula (2) with the global optimal position of the algorithm at this time as the center; after that, the position of the global optimal particle is kept unchanged until the next iteration, and other particles are randomly generated again in the newly divided solution space.
[0072]
[0073] Where k1 and k2 are contraction coefficients.
[0074] S55: Iterate and update all particles. The detailed steps are as follows:
[0075] S551: Calculate the weight λ of the maximum difference of the i-th particle in all dimensions imax (t), adaptability coefficient μ, inertia weight w of the i-th particle i And the acceleration factors c1 and c2.
[0076] Specifically, the weight λ of the maximum difference imax The calculation formula of (t) is shown in formula (3).
[0077]
[0078] In the formula, x ik (t) is the k-th dimension value of the ith particle after t iterations, x gbk(t) is the k-th dimension value of the global best position after t iterations, λ ik (t) is x ik (t) and x gbk The weight of the difference between (t).
[0079] The calculation formula of the adaptability coefficient μ is shown in formula (4).
[0080]
[0081] In the formula, α is the variation factor.
[0082] The inertia weight w of the i-th particle i The calculation formula of is shown in formula (5). i It can realize adaptive dynamic adjustment, taking the individual optimal fitness of a single particle as feedback. In each iteration, each particle will get w related to the current iteration number, individual optimal fitness and global optimal fitness. i , thereby increasing the diversity of particles.
[0083]
[0084] Where, t max is the maximum number of iterations, and are the individual optimal fitness and global optimal fitness of the ith particle after t iterations, respectively, and w max and w min are the maximum and minimum inertia weights respectively.
[0085] The calculation formulas for the acceleration coefficients c1 and c2 are shown in formula (6).
[0086]
[0087] S552: Update particles using the velocity update formula and the improved position update formula.
[0088] Specifically, the speed update formula and the new position update formula are shown in equations (7) and (8). The improved position update formula includes: a standard position update formula, a new position update formula and a new jump out of local optimal formula. It has the following characteristics: the new position update formula that is nonlinearly improved with the number of iterations uses probability and a random number u that adaptively adjusts the degree of dispersion of the Gaussian distribution to dynamically coordinate the relationship between global search and local search to obtain the best optimization result; the random number v that obeys the Gaussian distribution introduced in the new jump out of local optimal formula is used to reactivate the particles so that the particles continue to be active in the search space, thereby effectively preventing the particles from entering an "inactive" state.
[0089]
[0090]
[0091] In the formula, is the velocity vector of the ith particle after t iterations, r1, r2 and r3 are random numbers in the range of [0, 1], and u and v are random numbers that obey the Gaussian distribution, as shown in formula (9).
[0092]
[0093] In the formula, σ u and σ v are the standard deviations of u and v that follow the Gaussian distribution respectively, r4 is a random number in the range of [-1.5, 1.5], and r5 is a random number in the range of [0, 1].
[0094] S56: The number of iterations t is increased by 1. If the current number of iterations has reached the maximum number of iterations, the algorithm ends and outputs the optimal PID control parameters and the optimal fitness value. Otherwise, execute step S52.
[0095] S6: The optimal groove design dimensions are used as the final piston seal groove dimensions of the high-performance cylinder.
[0096] Embodiment 1
[0097] Taking a self-made six-seal groove piston as an example, the specific implementation cases and effects of the present invention are introduced.
[0098] The six sealing grooves of the designed piston are named sealing groove No. 1, sealing groove No. 2, ..., sealing groove No. 6 from left to right.
[0099] On this basis, a cylinder motion trajectory tracking control test platform was built using proportional directional valves, laser displacement sensors, PCI-6221 acquisition cards and other equipment.
[0100] The reference signal tracked by the homemade six-seal groove piston cylinder is 30sin(πt-0.5π)+10mm, and the PID control parameter K p , K i and K d The ranges are set to [0,0.6], [0,0.1] and [0,0.005] respectively; the specific restrictions of PID position control are: when the particle fitness value exceeds the set threshold, it is controlled for two cycles, otherwise it is controlled for four cycles; when it is determined that oscillation occurs, a poor fitness value of 12mm is assigned to it.
[0101] The initial parameters of the new improved particle swarm algorithm are set as follows: population size N = 20, maximum number of iterations t max =20, maximum inertia weight w max=0.9, minimum inertia weight w min =0.4, take 20% of the range of change in each dimension in the search space as the speed range.
[0102] According to experience, the threshold e of the search space shrinking itself max It is set to 2.6mm, and the contraction coefficients k1 and k2 are set to 0.4 and 1.6.
[0103] Figure 3 This is the optimization result diagram of the six sealing grooves of the piston in the embodiment. It can be seen that sealing groove No. 2 has higher control accuracy, and the optimized sealing groove design size is used as the final piston size of the high-performance cylinder.
[0104] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0105] The above-mentioned embodiment only expresses one implementation mode of the present invention, and its description is relatively specific and detailed, but it cannot be understood as limiting the scope of the invention patent. It should be pointed out that for ordinary technicians in this field, several modifications and improvements can be made without departing from the concept of the present application, which all belong to the protection scope of the present application. Therefore, the protection scope of the patent of this application shall be based on the attached claims.
Claims
1. An intelligent optimization method for cylinder piston sealing groove based on a new improved particle swarm algorithm, characterized in that: The following steps are involved: S1: Design multiple seal grooves of different sizes for the cylinder piston according to mechanical design manual and experience; S2: Build a cylinder motion trajectory tracking PID control test platform; S3: Determine the value range of the PID controller parameters to be optimized to form a search space; S4: Set the initial parameters of the new improved particle swarm algorithm, select the maximum error of the system in the trajectory tracking process as the fitness function of the algorithm, and determine the shrinkage threshold and shrinkage coefficient of the algorithm; S5: A new improved particle swarm algorithm is used to optimize the cylinder PID motion trajectory tracking control parameters when the seal ring is located in different sealing grooves, and the sealing groove with the highest PID trajectory tracking control accuracy is selected; S6: The optimal groove design size is used as the final piston seal groove size of the high-performance cylinder; The step S5 specifically comprises the following steps: S51: Randomly generate initial particles in the search space, and the position vector X of each particle i The three control parameters K of PID p , K i and K d composition; S52: Perform PID position control on each particle to obtain the fitness value of each particle; S53: Count the fitness value of each particle, and record the individual best position of the i-th particle and the global best position of the entire group after t iterations; S54: Determine whether the global optimal position reaches the contraction threshold for the first time. If it does, re-divide the search space and randomly generate particles in the new search space, and then execute step S52; otherwise, execute step S55; S55: Iterate and update all particles. The specific steps are as follows: S551: Calculate the weight λ of the maximum difference of the i-th particle in all dimensions imax (t), adaptability coefficient μ, inertia weight w of the i-th particle i And the acceleration coefficients c1 and c2; S552: Update particles using the velocity update formula and the improved position update formula; S56: The number of iterations t is increased by 1. If the current number of iterations has reached the maximum number of iterations, the algorithm ends and outputs the optimal PID control parameters and the optimal fitness value. Otherwise, execute step S52.
2. The method for intelligent optimization of cylinder piston sealing groove based on a novel improved particle swarm algorithm as claimed in claim 1, characterized in that: The inertia weight w in step S551 i It can realize adaptive dynamic adjustment, and its calculation formula is: In the formula, t is the current iteration number, t max is the maximum number of iterations, and are the individual optimal fitness and global optimal fitness of the ith particle after t iterations, respectively, and w max and w min are the maximum and minimum inertia weights respectively.
3. The method for intelligent optimization of cylinder piston sealing groove based on novel improved particle swarm algorithm as claimed in claim 1, characterized in that: The improved position update formula in step S552 includes: a standard position update formula, a new position update formula and a new jump out of local optimal formula, and the improved position update formula is: Among them, the new position update formula is The standard position update formula is The new formula for escaping from the local optimum is: In the formula, is the position vector of the ith particle after t iterations, is the global optimal position vector of the entire group after t iterations, is the velocity vector of the ith particle after t iterations, u and v are random numbers that obey Gaussian distribution, α is the variation factor, r3 is a random number in the range of [0, 1], and λ imax (t) is the weight of the maximum difference of the i-th particle in all dimensions, which can be described as: In the formula, x ik (t) is the k-th dimension value of the ith particle after t iterations, x gbk (t) is the k-th dimension value of the global best position after t iterations, λ ik (t) is x ik (t) and x gbk The weight of the difference between (t).
4. The method for intelligently selecting cylinder piston sealing groove based on a novel improved particle swarm algorithm as claimed in claim 3, characterized in that: The formula for the random number u for adaptively adjusting the dispersion degree of Gaussian distribution introduced in the novel position update formula is: In the formula, σ u is the standard deviation of the random number u that obeys the Gaussian distribution, μ is the adaptability coefficient, and its formula is: 。 5. The method for intelligent optimization of cylinder piston sealing groove based on novel improved particle swarm algorithm as claimed in claim 3, characterized in that: The formula of the random number v obeying the Gaussian distribution introduced in the novel jump-out local optimal formula is: In the formula, σ v is the standard deviation of the random number v that follows the Gaussian distribution, r4 is a random number in [-1.5, 1.5], and r5 is a random number in [0, 1].
6. The method for intelligent optimization of cylinder piston sealing groove based on novel improved particle swarm algorithm as claimed in claim 1, characterized in that: In step S54, the search space is re-divided according to the following formula: In the formula, k1 and k2 are contraction coefficients. is the global optimal position vector of the entire group after t iterations.
7. The method for intelligent optimization of cylinder piston sealing groove based on novel improved particle swarm algorithm as claimed in claim 1, characterized in that: Also includes: The first restriction is set for the process of step S52: a threshold is set for the fitness, and the period of PID position control is determined by monitoring the fitness value of each particle.
8. The method for intelligent optimization of cylinder piston sealing groove based on novel improved particle swarm algorithm as claimed in claim 1, characterized in that: Also includes: The second restriction is set for step S52: the change in error during the PID control process is used to determine whether oscillation occurs, and a penalty mechanism is established based on this. That is, when the error change exceeds a certain range, the particle will automatically stop running and be assigned a poor fitness value.
Citation Information
Patent Citations
PID (Proportion Integration Differentiation) control parameter optimization method for TBM (Tunnel Boring Machine) hydraulic propelling system
CN106292281A
PID parameter optimization method based on PSO-SOA fusion algorithm
CN110308649A