Path planning method for particle swarm optimization of swarm foraging strategy for puncture needle
By applying the particle swarm optimization algorithm of the swarm foraging strategy in puncture surgery, the kinematic model and path planning of the puncture needle are optimized, which solves the problem of low accuracy of path planning in complex environments and achieves a more efficient and precise puncture effect. Risks to doctors and patients are reduced.
Patent Information
- Application Number
- CN202410628195.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-21
- Publication Date
- 2024-08-30
AI Technical Summary
The existing technology has low accuracy in path planning during puncture surgery in complex environments, which increases the risk of radiation exposure for doctors and the pain of patients. Moreover, traditional methods are difficult to effectively avoid multiple obstacles, resulting in tissue destruction during the puncture process.
The particle swarm optimization algorithm based on the bee colony foraging strategy is used to establish the kinematic model of the puncture needle, separate the needle insertion and rotation actions, optimize the path planning, and combine the retreat needle insertion strategy to reduce the path length and improve the puncture accuracy.
It significantly improves puncture efficiency and accuracy, enhances adaptability to complex environments, and reduces radiation exposure to doctors and patient pain.
Smart Images

Figure CN118557282A
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of robot motion planning and is a path planning method of bee colony foraging strategy particle swarm optimization for puncture needles. Background Art
[0002] Percutaneous interventional diagnosis and treatment is an important part of minimally invasive surgery in modern clinical medicine, and is also an important means of pathological examination, local anesthesia, and local drug administration. In the actual clinical puncture operation, doctors often need to use CT or ultrasound to observe the position of the puncture needle, which directly exposes the doctor to the radiation environment and causes certain damage to the doctor's health. In addition, if the needle tip encounters an obstacle during the puncture process, the doctor can only change the position of the needle tip by adjusting the needle tail. This type of surgery increases the risk of additional harm to the patient, increases the patient's pain during the operation, and prolongs the patient's postoperative recovery time.
[0003] The difficulty of puncture surgery lies in accurately reaching the lesion while effectively avoiding obstacles such as nerves, arteries, blood vessels, bones, etc. in the path. In recent years, various control and planning methods have been proposed for the development of medical robots, but these studies have failed to provide effective control and path planning methods for complex puncture problems. Therefore, it is particularly important to design an automatic path planning method for robot puncture operations.
[0004] Although the existing path planning method for the oblique-tip flexible puncture needle has good planning accuracy in single-target single-obstacle and single-target multiple-obstacle environments, it is not strong in path planning in more complex environments. On the other hand, for the path planning problem of multiple target points, the traditional needle insertion logic makes the total puncture path length longer, resulting in more tissue damage during the puncture process. In view of the above problems, it is necessary to study the application of intelligent motion planning algorithms in puncture surgery to improve the efficiency and accuracy of puncture in complex environments; Summary of the invention
[0005] In view of the above problems existing in the prior art, the purpose of the present invention is to provide a path planning algorithm based on intelligent particle swarm, which is applied to puncture robot surgery to solve the problems of poor adaptability in complex environments and low puncture planning accuracy.
[0006] The present invention provides the following technical solution: a path planning method for bee colony foraging strategy particle swarm optimization for puncture needles, comprising the following steps:
[0007] 1) Assume that the flexible needle is rigidly connected in the axial direction, that is, the puncture needle will not deform in the axial direction during the puncture process;
[0008] 2) Taking the needle tip forward direction as the z-axis direction, establish the puncture needle kinematic model to obtain the parameter vector The specific formula is as follows:
[0009]
[0010] in, are the speeds of the puncture needle in the three directions in the coordinate system, α, β, γ are the rotation angles of the needle tip around the x, y, and z axes in the world coordinate system, k is the slope of the curve of the puncture needle during the puncture process, v is the forward speed of the needle tip, and ω is the angular velocity of the needle axial rotation;
[0011] The model is further simplified: the control variables are simplified into time-independent physical quantities, that is, v and ω are simplified into the needle insertion distance s and the needle tip rotation angle θ, respectively, then the motion model parameter vector Further expressed as:
[0012]
[0013] The control of the model adopts a stop-rotation strategy, that is, the needle insertion action and the needle tip rotation action are performed separately, and only one of the needle insertion action or the needle tip rotation action can be performed at the same time;
[0014] 3) By controlling the sequence θ=((s1,θ1),(s2,θ2),...,(s n ,θ n )) uniquely determines the path of the puncture needle, where n is the number of segments of the path; sets a target optimization function including path length, deviation and collision penalty function, and its specific expression is as follows:
[0015] Y=k1Y s (Θ)+Y d (Θ)+k2Y tip (Θ)
[0016] Y tip (Θ)=|P tip (Θ)-P d |
[0017]
[0018]
[0019]
[0020] Among them, Y s is the path length function, s i is the length of the i-th segment of the path; Y tip is the error function between the target point and the needle tip position; P tip (Θ),P d are the actual position and expected position of the puncture needle respectively; Y dis the function for judging whether there is a collision with an obstacle, j represents the jth obstacle, assuming there are m obstacles in total, y(d) is the collision function of a single obstacle; d and D are the actual distance and safety distance between the obstacle and the needle tip, respectively; k1 and k2 are the weights of the path length function and the path error function, respectively;
[0021] 4) Using the target optimization function in step 3) as the fitness value of the particle swarm optimization algorithm of the bee colony foraging strategy, adjusting the parameters, and obtaining a better puncture reference path;
[0022] 5) A backward needle insertion strategy is used to reduce the overall puncture path length of the multi-target path and complete the puncture path planning for all target points.
[0023] Furthermore, in step 2), all variables ξ of the motion model of the puncture needle g =[x,y,z,α,β,γ] T It is based on the world coordinate system, while the needle tip speed and rotation angular velocity are based on the needle body coordinates, which are derived from the following formula:
[0024]
[0025] V P =vV1+ωV2
[0026] Where V1 = [0 0 1 k 0 0] T ,V2=[0 0 0 0 0 1] T ; According to the velocity transformation equation between the needle body coordinates and the world coordinates, we can get V P =QV g ,and Where P T gp It is the rotation matrix of the world coordinates and the needle body coordinates. When used, it is uniquely determined after calibration after the placement of the needle and the electromagnetic positioning system is determined; P Ω is the Euler kinematics coefficient matrix of the rigid body fixed-point motion, which establishes the needle body coordinate ψ p and the world coordinate system ψ g The angular velocity transformation relationship between
[0027] Furthermore, in step 3), the entire puncture path is divided into multiple standard arcs and the control sequence θ=((s1,θ1),(s2,θ2),...,(s n ,θ n )) is the only certainty. It is further assumed that the curvature of the path of the bevel-tipped flexible puncture needle tip is constant; the needle tip will move in a circular arc with a fixed radius, and the direction of movement is determined by the direction of the needle tip; then the path conversion process in three-dimensional space is as follows:
[0028] 3.1) In two-dimensional space, each arc path is composed of the starting point coordinates q of the i-th arc path i ,q i The tangent vector n of the path arc i , and the center of the arc segment O i and arc length s i Uniquely determined; given that the radius of each arc of the path is r, the arc of the i-th arc is:
[0029]
[0030] So, q i , n i , O i and i The conversion formula between them is:
[0031] q i+1 =q i cosσ i +(1-cosσ i ) i +rq i sinσ i
[0032] O i+1 =2q i+1 -O i
[0033] n i+1 =(1-cosσ i ) i+1 +q i+1 cosσ i -q i
[0034] 3.2) In three-dimensional space, the transformation relationship between the center coordinates of each arc path segment is:
[0035] O i+1 =λ2+q i+1
[0036] λ2=λ1cosθ i+1 +n i+1 ×λ1sinθ i+1 +n i+1 (n i+1 *λ1)(1-cosθ i+1 )
[0037] Among them, λ1,λ2 are auxiliary vectors, respectively, λ1=O i -q i+1 ,λ2=Oi+1 -q i+1 ,θ i is the rotation angle of the needle tip in three-dimensional space.
[0038] Furthermore, the specific process of the optimization algorithm in step 4) is as follows:
[0039] 4.1) Initialize algorithm parameters;
[0040] 4.2) Update the speed and position of each particle, and adjust the counter count according to the update status of each particle;
[0041] 4.3) Calculate the probability n(x) of each particle being selected according to its fitness value i ), and use the roulette wheel selection strategy to select particles. The specific calculation formula is:
[0042]
[0043]
[0044] Among them, f(pBest i ) is the optimal fitness value of the i-th particle, p i is the probability result after the particle uses roulette, and N is the number of particles in the particle group;
[0045] 4.4) For the selected particle, the speed and position of the particle are updated, and the counter count is adjusted according to the updated status of the particle;
[0046] 4.5) Traverse the counter count of each particle. If the counter value of one particle reaches the set upper limit, reinitialize the particle;
[0047] 4.6) Determine whether the algorithm has reached the iteration stop condition. If not, return to step 4.2. If satisfied, stop the calculation and output the result.
[0048] Furthermore, in 4.2) and 4.4), for the position and speed update of the particle group and the counter count adjustment, the specific steps are as follows:
[0049] 4.2.1) The speed and position update formula is expressed as:
[0050] V i (t+1)=τV i (t)+c1r1(pBest i -X i (t))+c2r2(gBest-X i (t))
[0051] X i (t+1)=X i (t)+V i (t+1)
[0052] Where t is the current iteration number, i=1,2,3,...,n is the particle number; c1 is the individual learning factor, c2 is the social learning factor, r1 and r2 are random numbers in the interval [0,1], pBest is the location of the optimal fitness value of the i-th particle, gBest is the location of the particle with the global optimal fitness value, τ is the inertia weight coefficient, and the iteration equation is:
[0053] τ=τ max -τ k t
[0054] in,
[0055] 4.2.2) After updating the speed and position of the particle swarm, the fitness value of each particle is updated using the objective function expression of step 3), and the update status of each particle is recorded; if the fitness value of one of the particles is not better after iteration, the counter corresponding to the particle will increase; if the fitness value of one of the particles is optimized after iteration, the counter corresponding to the particle will be reset to zero; the particle counter is updated as follows:
[0056]
[0057] Where count(i) is the counter of the i-th particle, x i_new is the new position of the ith particle, and f(·) is the fitness value calculation function.
[0058] Furthermore, the specific process of step 5 is as follows:
[0059] 5.1) Sort all targets according to the absolute distance between the target and the needle point from large to small. This order is the order of path planning for each target. The target farther from the needle point will be punctured first.
[0060] 5.2) The puncture needle will start the path planning operation for the second target point from the end point of the initial puncture path. If the puncture path to the second target point cannot be successfully planned at the end point of the initial puncture path, the needle tip will return to the position of the last parking turning point; the puncture path planning for the second target point will be performed again, and so on, until the puncture path to the second target point is successfully planned; if the path to the second target point is not successfully planned before the needle tip returns to the needle insertion point, the path planning will be restarted from the needle insertion point;
[0061] According to the above needle insertion strategy, the puncture path planning for all target points is completed.
[0062] By adopting the above technology, compared with the prior art, the beneficial effects of the present invention are as follows:
[0063] From an overall perspective, the present invention proposes a new path planning scheme based on an intelligent particle swarm algorithm. The planning scheme establishes relevant target optimization functions for the puncture error, path length, and collision function with the tissue during the puncture process, and combines the intelligent particle swarm algorithm for further optimization. It can overcome the defects of traditional planning methods and significantly improve the puncture efficiency as well as the adaptability and accuracy to complex environments. BRIEF DESCRIPTION OF THE DRAWINGS
[0064] Figure 1 is a flow chart of the method of the present invention;
[0065] Figure 2 This is a force analysis diagram of the needle tip after the needle body penetrates the tissue in an embodiment of the present invention;
[0066] Figure 3 Schematic diagram of the motion model of the oblique-pointed needle in the embodiment of the present invention;
[0067] Figure 4 is a schematic diagram of a two-dimensional puncture path in an embodiment of the present invention;
[0068] Figure 5 The figure is a schematic diagram of the intelligent particle swarm algorithm process in an embodiment of the present invention. DETAILED DESCRIPTION
[0069] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments of the specification. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0070] On the contrary, the present invention covers any substitution, modification, equivalent method and scheme made on the essence and scope of the present invention as defined by the claims. Further, in order to make the public have a better understanding of the present invention, some specific details are described in detail in the detailed description of the present invention below. Those skilled in the art can fully understand the present invention without the description of these details.
[0071] See also Figure 1-5 , a particle swarm optimization method for bee colony foraging strategy and fusion needle retreat and insertion strategy for oblique-tip flexible puncture needles, such as Figure 1 As shown, the following steps are included:
[0072] S1: Due to the asymmetric structure of the flexible puncture needle tip, such as Figure 2 As shown, the force exerted on the needle tip by the human tissue during the puncture process is also asymmetric, which will also cause the path to deflect when the needle is inserted. Therefore, when establishing the kinematic model of the needle tip, this embodiment makes the following assumptions: the flexible needle is rigidly connected in the axial direction, that is, the puncture needle will not deform in the axial direction during the puncture process. With the above assumptions, the forward direction of the flexible needle during the puncture process is determined by the direction of the needle tip bevel, which will simplify the complex modeling process;
[0073] S2: After the analysis and assumptions in step 1, the kinematic model of the puncture needle of the present invention is established: the specific steps are as follows:
[0074] S2.1: First, the kinematic model of the puncture needle is established with the needle tip moving in the z-axis direction, and the parameter vector is obtained.
[0075]
[0076] in, are the speeds of the puncture needle in three directions in the coordinate system, α, β, γ are the rotation angles of the needle tip around the x, y, and z axes in the world coordinate system, k is the slope of the curve of the puncture needle during the puncture process, v is the forward speed of the needle tip, and ω is the angular velocity of the needle axial rotation; in order to make the above nonlinear system more suitable for path planning, further simplification is made: the control variables are simplified to physical quantities that are independent of time, that is, v and ω are simplified to the needle distance s and the needle tip rotation angle θ respectively, then the motion model can be further expressed as:
[0077]
[0078] In addition, the control of the model also adopts a stop-rotation strategy, that is, the needle insertion action and the needle tip rotation action are performed separately, and only one of the needle insertion or needle tip rotation actions can be performed at the same time;
[0079] S2.2: If Figure 3 As shown, all variables ξ of the motion model of the puncture needle g =[x,y,z,α,β,γ] T It is based on the world coordinate system, while the needle tip speed and rotation angular velocity are based on the needle body coordinates, which are derived from the following formula:
[0080]
[0081] V P =vV1+ωV2
[0082] Where V1 = [0 0 1 k 0 0] T,V2=[0 0 0 0 0 1] T According to the velocity transformation equation between the needle body coordinates and the world coordinates, we can get V P =QV g ,and Where P T gp It is the rotation matrix of the world coordinates and the needle body coordinates. When used, when the placement of the needle and the electromagnetic positioning system is determined, it can be calibrated and uniquely determined; P Ω is the Euler kinematics coefficient matrix of the rigid body fixed-point motion, which establishes the needle body coordinate ψ p and the world coordinate system ψ g The angular velocity transformation relationship between
[0083] S3: According to the assumption in step 2, the puncture path of the puncture needle is independent of the needle insertion speed and the needle tip rotation angular velocity. The physical quantities that affect the puncture path are only the needle insertion distance s and the rotation angle θ. Therefore, the path of the puncture needle can be controlled by the control sequence θ=((s1,θ1),(s2,θ2),...,(s n ,θ n )) is uniquely determined, where n is the number of segments of the path. Further assumptions are made: the curvature of the path of the beveled flexible puncture needle tip is constant. The needle tip will move in an arc with a fixed radius, and the direction of movement is determined by the direction of the needle tip. The path transformation in three-dimensional space and the objective function setting are as follows:
[0084] S3.1: If Figure 4 As shown, in two-dimensional space, each arc path can be represented by the starting coordinates q of the i-th arc path i ,q i The tangent vector n of the path arc i , and the center of the arc segment O i and arc length s i Uniquely determined. Under the premise that the radius of each path arc is r, the arc of the i-th arc can be obtained as:
[0085]
[0086] So, q i , n i , O i and i The conversion formula between them is:
[0087] q i+1 =q i cosσ i +(1-cosσ i ) i +rq isinσ i
[0088] O i+1 =2q i+1 -O i
[0089] n i+1 =(1-cosσ i ) i+1 +q i+1 cosσ i -q i
[0090] S3.2: In three-dimensional space, the transformation relationship between the center coordinates of each arc path segment is:
[0091] O i+1 =λ2+q i+1
[0092] λ2=λ1cosθ i+1 +n i+1 ×λ1sinθ i+1 +n i+1 (n i+1 *λ1)(1-cosθ i+1 )
[0093] Among them, λ1,λ2 are auxiliary vectors, respectively, λ1=O i -q i+1 ,λ2=O i+1 -q i+1 ,θ i is the rotation angle of the needle tip in three-dimensional space;
[0094] S3.3: Set the target optimization function including path length, deviation and collision penalty function. The specific expression is as follows:
[0095] Y=k1Y s (Θ)+Y d (Θ)+k2Y tip (Θ)
[0096] Y tip (Θ)=|P tip (Θ)-P d |
[0097]
[0098]
[0099]
[0100] Among them, Y sis the path length function, s i is the length of the i-th segment of the path; Y tip is the error function between the target point and the needle tip position; P tip (Θ),P d are the actual position and expected position of the puncture needle respectively; Y d is the function for judging whether there is a collision with an obstacle, j represents the jth obstacle, assuming there are m obstacles in total, y(d) is the collision function of a single obstacle; D is the safe distance between the obstacle and the needle tip; k1 and k2 are the weights of the path length function and the path error function respectively;
[0101] S4: After the objective function is designed in step 3, it is used as the fitness value of the particle swarm optimization algorithm for bee colony foraging strategy. Figure 5 , the specific process of the optimization algorithm is as follows:
[0102] S4.1: Initialize the maximum number of iterations of the algorithm, the speed, position, optimal fitness value of each particle, optimal fitness value of the group, etc.;
[0103] S4.2: Update the speed and position of each particle, and adjust the counter count according to the update status of each particle. The specific steps are as follows:
[0104] S4.2.1: The speed and position update formulas are expressed as:
[0105] V i (t+1)=τV i (t)+c1r1(pBest i -X i (t))+c2r2(gBest-X i (t))
[0106] X i (t+1)=X i (t)+V i (t+1)
[0107] Where t is the current iteration number, i=1,2,3,...,n is the particle number; c1 is the individual learning factor, c2 is the social learning factor, r1 and r2 are random numbers in the interval [0,1], pBest is the location of the optimal fitness value of the i-th particle, gBest is the location of the particle with the global optimal fitness value, τ is the inertia weight coefficient, and the iteration equation is:
[0108] τ=τ max -τ k t
[0109] in,
[0110] S4.2.2: After updating the speed and position of the particle swarm, use the objective function expression in step 3 to update the fitness value of each particle, and record the update of each particle. If the fitness value of a particle is not better after a certain iteration, the counter corresponding to the particle will increase. If the fitness value of a particle is optimized after a certain iteration, the counter corresponding to the particle will be reset to zero. The particle counter is updated as follows:
[0111]
[0112] Where count(i) is the counter of the i-th particle, x i_new is the new position of the ith particle, and f(·) is the fitness value calculation function;
[0113] S4.3: Calculate the probability n(x) of each particle being selected according to the fitness value of each particle. i ), and use the roulette selection strategy (the core idea of roulette is that the larger the area on the roulette wheel, the greater the probability of being selected) to select particles. The specific calculation of the probability is:
[0114]
[0115]
[0116] Among them, f(pBest i ) is the optimal fitness value of the i-th particle, p i is the probability result after the particle uses roulette, and N is the number of particles in the particle group;
[0117] S4.4: For the selected particle, the speed and position of the particle are updated, and the counter count is adjusted according to the updated status of the particle. For details, refer to step 4.2;
[0118] S4.5: traverse the counter count of each particle, if the counter value of a particle reaches the set upper limit, reinitialize the particle;
[0119] S4.6: Determine whether the algorithm has reached the iteration stop condition. If not, return to step 4.2. If satisfied, stop the calculation and output the result.
[0120] S5: For the multi-target path, this embodiment adopts the strategy of back-entry to reduce the overall puncture path length. The specific steps are as follows:
[0121] S5.1: First, all targets are sorted from largest to smallest according to the absolute distance between the target and the needle insertion point (random sorting for the same distance), and this order is also the order of path planning for each target. The target farther from the needle insertion point will be punctured first.
[0122] S5.2: Then, the puncture needle will start the path planning operation for the second target point from the end point of the initial puncture path. If the puncture path to the second target point cannot be successfully planned at the end point of the initial puncture path, the needle tip will return to the position of the last parking turning point, and then plan the puncture path to the second target point again, and so on, until the puncture path to the second target point is successfully planned; if the path to the second target point is not successfully planned before the needle tip returns to the needle insertion point, the path planning will be restarted from the needle insertion point. Finally, the puncture path planning for all target points is completed according to the needle insertion strategy;
[0123] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. The path planning method of particle swarm optimization for bee colony foraging strategy for puncture needles is characterized by: The following steps are involved: 1) Assume that the flexible needle is rigidly connected in the axial direction, that is, the puncture needle will not deform in the axial direction during the puncture process; 2) Taking the needle tip forward direction as the z-axis direction, establish the puncture needle kinematic model to obtain the parameter vector The specific formula is as follows: in, are the speeds of the puncture needle in the three directions in the coordinate system, α, β, γ are the rotation angles of the needle tip around the x, y, and z axes in the world coordinate system, k is the slope of the curve of the puncture needle during the puncture process, v is the forward speed of the needle tip, and ω is the angular velocity of the needle axial rotation; The model is further simplified: the control variables are simplified into time-independent physical quantities, that is, v and ω are simplified into the needle insertion distance s and the needle tip rotation angle θ, respectively, then the motion model parameter vector Further expressed as: The control of the model adopts a stop-rotation strategy, that is, the needle insertion action and the needle tip rotation action are performed separately, and only one of the needle insertion action or the needle tip rotation action can be performed at the same time; 3) By controlling the sequence θ=((s1,θ1),(s2,θ2),...,(s n ,θ n )) uniquely determines the path of the puncture needle, where n is the number of segments of the path; sets a target optimization function including path length, deviation and collision penalty function, and its specific expression is as follows: Y=k1Y s (Θ)+Y d (Θ)+k2Y tip (I) Y tip (Θ)=|P tip (I)-P d | Among them, Y s is the path length function, s i is the length of the i-th segment of the path; Y tip is the error function between the target point and the needle tip position; P tip (Θ),P d are the actual position and expected position of the puncture needle respectively; Y d is the function for judging whether there is a collision with an obstacle, j represents the jth obstacle, assuming there are m obstacles in total, y(d) is the collision function of a single obstacle; d and D are the actual distance and safety distance between the obstacle and the needle tip, respectively; k1 and k2 are the weights of the path length function and the path error function, respectively; 4) Using the target optimization function in step 3) as the fitness value of the particle swarm optimization algorithm of the bee colony foraging strategy, adjusting the parameters, and obtaining a better puncture reference path; 5) A backward needle insertion strategy is used to reduce the overall puncture path length of the multi-target path and complete the puncture path planning for all target points.
2. The path planning method of particle swarm optimization for bee colony foraging strategy for puncture needle according to claim 1 is characterized in that In step 2), all variables ξ of the motion model of the puncture needle g =[x,y,z,α,β,γ] T It is based on the world coordinate system, while the needle tip speed and rotation angular velocity are based on the needle body coordinates, which are derived from the following formula: V P =vV1+ωV2 Where V1 = [0 0 1 k 0 0] T ,V2=[0 0 0 0 0 1] T ; According to the velocity transformation equation between the needle body coordinates and the world coordinates, we can get V P =QV g ,and Where P T gp It is the rotation matrix of the world coordinates and the needle body coordinates. When used, it is uniquely determined after calibration after the placement of the needle and the electromagnetic positioning system is determined; P Ω is the Euler kinematics coefficient matrix of the rigid body fixed-point motion, which establishes the needle body coordinate ψ p and the world coordinate system ψ g The angular velocity transformation relationship between 3. The path planning method of particle swarm optimization for bee colony foraging strategy for puncture needle according to claim 1 is characterized in that In step 3), the entire puncture path is divided into multiple standard arcs and the control sequence θ=((s1,θ1),(s2,θ2),...,(s n ,θ n )) is the only certainty. It is further assumed that the curvature of the path of the bevel-tipped flexible puncture needle tip is constant; the needle tip will move in a circular arc with a fixed radius, and the direction of movement is determined by the direction of the needle tip; then the path conversion process in three-dimensional space is as follows: 3.1) In two-dimensional space, each arc path is composed of the starting point coordinates q of the i-th arc path i ,q i The tangent vector n of the path arc i , and the center of the arc segment O i and arc length s i Uniquely determined; given that the radius of each arc of the path is r, the arc of the i-th arc is: So, q i , n i , O i and i The conversion formula between them is: q i+1 =q i cosσ i +(1-cosσ i )O i +rq i sinσ i EITHER i+1 =2q i+1 -EITHER i n i+1 =(1-cosσ i )O i+1 +q i+1 cosσ i -q i 3.2) In three-dimensional space, the transformation relationship between the center coordinates of each arc path segment is: Oh i+1 =λ2+q i+1 λ2=λ1cosθ i+1 +n i+1 ×λ1sinθ i+1 +n i+1 (n i+1 *λ1)(1-cosθ i+1 ) Among them, λ1,λ2 are auxiliary vectors, respectively, λ1=O i -q i+1 ,λ2=O i+1 -q i+1 ,θ i is the rotation angle of the needle tip in three-dimensional space.
4. The path planning method of particle swarm optimization for bee colony foraging strategy for puncture needles according to claim 1 is characterized in that The specific process of the optimization algorithm in step 4) is as follows: 4.1) Initialize algorithm parameters; 4.2) Update the speed and position of each particle, and adjust the counter count according to the update status of each particle; 4.3) Calculate the probability n(x) of each particle being selected according to its fitness value i ), and use the roulette wheel selection strategy to select particles. The specific calculation formula is: Among them, f(pBest i ) is the optimal fitness value of the i-th particle, p i is the probability result after the particle uses roulette, and N is the number of particles in the particle group; 4.4) For the selected particle, the speed and position of the particle are updated, and the counter count is adjusted according to the updated status of the particle; 4.5) Traverse the counter count of each particle. If the counter value of one particle reaches the set upper limit, reinitialize the particle; 4.6) Determine whether the algorithm has reached the iteration stop condition. If not, return to step 4.
2. If satisfied, stop the calculation and output the result.
5. The path planning method of particle swarm optimization for bee colony foraging strategy for puncture needle according to claim 4 is characterized in that In 4.2) and 4.4), for the position and speed update of the particle group and the counter count adjustment, the specific steps are as follows: 4.2.1) The speed and position update formula is expressed as: V i (t+1)=τV i (t)+c1r1(pBest i -X i (t))+c2r2(gBest-X i (t)) X i (t+1)=X i (t)+V i (t+1) Where t is the current iteration number, i=1,2,3,...,n is the particle number; c1 is the individual learning factor, c2 is the social learning factor, r1 and r2 are random numbers in the interval [0,1], pBest is the location of the optimal fitness value of the i-th particle, gBest is the location of the particle with the global optimal fitness value, τ is the inertia weight coefficient, and the iteration equation is: τ=τ max -t k t in, 4.2.2) After updating the speed and position of the particle swarm, the fitness value of each particle is updated using the objective function expression of step 3), and the update status of each particle is recorded; if the fitness value of one of the particles is not better after iteration, the counter corresponding to the particle will increase; if the fitness value of one of the particles is optimized after iteration, the counter corresponding to the particle will be reset to zero; the particle counter is updated as follows: Where count(i) is the counter of the i-th particle, x i_new is the new position of the ith particle, and f(·) is the fitness value calculation function.
6. The path planning method of particle swarm optimization for bee colony foraging strategy for puncture needle according to claim 1 is characterized in that The specific process of step 5 is as follows: 5.1) Sort all targets according to the absolute distance between the target and the needle point from large to small. This order is the order of path planning for each target. The target farther from the needle point will be punctured first. 5.2) The puncture needle will start the path planning operation for the second target point from the end point of the initial puncture path. If the puncture path to the second target point cannot be successfully planned at the end point of the initial puncture path, the needle tip will return to the position of the last parking turning point; the puncture path planning for the second target point will be performed again, and so on, until the puncture path to the second target point is successfully planned; if the path to the second target point is not successfully planned before the needle tip returns to the needle insertion point, the path planning will be restarted from the needle insertion point; According to the above needle insertion strategy, the puncture path planning for all target points is completed.
Citation Information
Cited By
Robot positioning control method and device based on segmented targeted correction
CN119326503A
