Method, device and storage medium for determining robot arm position
By traversing the target space, inverse kinematics to obtain processing and calculating the speed Jacques matrix, the optimal joint angle of the robot arm is determined, which solves the problem of insufficient accuracy of the robot arm in the prior art and improves the accuracy of the positioning.
Patent Information
- Application Number
- CN202410871498.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-01
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2044-07-01
AI Technical Summary
The prior art ignores the compression resistance of the positioning when determining the positioning of the robot arm, resulting in the determined positioning being inaccurate enough.
By traversing the target space with a preset step length, a set of Cartesian poses at the end of the robotic arm is obtained, and each Cartesian pose is inversely kinematically obtained to obtain the joint angle. Then, the velocity Jacques ratio matrix corresponding to each set of joint angles is calculated, and the singular parameters and stiffness parameters are calculated based on it, and the joint angle with the smallest singular parameters and the largest stiffness parameters is finally determined as the optimal joint angle.
Improve the accuracy of the robot arm swing and avoid inaccuracies caused by neglecting the compressive resistance.
Smart Images

Figure CN118806442B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a method, device and storage medium for determining the position of a robot arm. Background Art
[0002] The surgical robot can connect the surgical area with the robotic arm through the infrared optical navigation system, and use the robotic arm to complete various surgical operations. Reasonable robotic arm positioning can ensure that the robotic arm is always within the visual range of the infrared optical navigation system, thereby ensuring the smooth progress of the operation.
[0003] At present, the method of determining the position of the robot arm is usually to evaluate and score each group of joint angles based on the singular value of the joint angle, the variance of the dynamics between the joint angles, the shortest distance between the lesion visual marker and the robot arm link and the end tool, and the field of view angle, and determine the final position of the robot arm based on the scoring results. It can be seen that this method takes into account the singularity and field of view of the robot arm, but ignores the stress resistance of the position, resulting in the determined position being inaccurate. Summary of the invention
[0004] In order to solve the above technical problems, the present application provides a method, device and storage medium for determining the position of a robot arm, which can improve the accuracy of determining the position of the robot arm.
[0005] In the first aspect, the present application provides a method for determining the position of a robotic arm, including: traversing the target space with a preset step size to obtain a set of Cartesian poses of the end of the robotic arm; the target space is the working space of the robotic arm in the surgical area; for each Cartesian pose in the Cartesian pose set, inverse kinematics is performed to obtain the joint angle corresponding to each Cartesian pose; one Cartesian pose corresponds to a group of joint angles, and a group of joint angles constitutes a robotic arm position; calculating the velocity Jacobian matrix corresponding to each group of joint angles; calculating the singular parameters and stiffness parameters corresponding to each group of joint angles based on the velocity Jacobian matrix; the singular parameters are used to characterize the singularity of the robotic arm, and the stiffness parameters are used to characterize the stiffness of the robotic arm; the joint angle with the smallest singular parameter and the largest stiffness parameter is determined as the optimal joint angle.
[0006] In some embodiments, the singular parameters corresponding to each group of joint angles are calculated according to the velocity Jacobian matrix, including: calculating the robot arm condition value corresponding to each group of joint angles according to the velocity Jacobian matrix; and determining the inverse of the robot arm condition value as the singular parameter corresponding to each group of joint angles.
[0007] In some embodiments, calculating the manipulator condition value corresponding to each set of joint angles according to the velocity Jacobian matrix includes: calculating the manipulator condition value corresponding to each set of joint angles according to the velocity Jacobian matrix and the formula Calculate the manipulator condition value corresponding to each set of joint angles; where s is used to represent the manipulator condition value and J is used to represent the velocity Jacobian matrix.
[0008] In some embodiments, the stiffness parameters corresponding to each group of joint angles are calculated according to the velocity Jacobian matrix, including: calculating the linear displacement stiffness matrix corresponding to the target joint angle according to the velocity Jacobian matrix and the joint stiffness matrix; the target joint angle is the joint angle corresponding to any Cartesian pose in the Cartesian pose set; calculating the first radius, second radius and third radius of the operable ellipsoid of the robot arm in the flange coordinate system according to the linear displacement stiffness matrix; the first radius is the radius of the operable ellipsoid along the X-axis in the flange coordinate system, the second radius is the radius of the operable ellipsoid along the Y-axis in the flange coordinate system, and the third radius is the radius of the operable ellipsoid along the Z-axis in the flange coordinate system; mapping the operable ellipsoid to the plane where the X-axis and the Y-axis are located to obtain the major semi-axis radius and the minor semi-axis radius of the operable ellipse; determining the ratio of the minor semi-axis radius to the major semi-axis radius as the stiffness parameter corresponding to the target joint angle.
[0009] In some embodiments, the linear displacement stiffness matrix corresponding to the target joint angle is calculated based on the velocity Jacobian matrix and the joint stiffness matrix, including: multiplying the inverse matrix of the joint stiffness matrix corresponding to the target joint angle, the velocity Jacobian matrix, and the transposed matrix of the velocity Jacobian matrix to determine the linear displacement stiffness matrix corresponding to the target joint angle.
[0010] In some embodiments, the first radius, second radius and third radius of the operable ellipsoid of the robotic arm in the flange coordinate system are calculated based on the linear displacement stiffness matrix, including: determining the product of the linear displacement stiffness matrix and the transposed matrix of the linear displacement stiffness matrix as the target matrix; determining the eigenvalue of the target matrix as the first radius, second radius and third radius of the operable ellipsoid of the robotic arm in the flange coordinate system.
[0011] In some embodiments, when the robotic arm is a robotic arm of an anterior cruciate ligament reconstruction surgery robot and the calculated optimal joint angle corresponds to left leg surgery, the method also includes: determining the zero joint angle of the robotic arm; mirroring the optimal joint angle corresponding to the left leg surgery according to the zero joint angle to obtain the optimal joint angle corresponding to the right leg surgery.
[0012] In some embodiments, the optimal joint angle corresponding to the left leg surgery is mirrored according to the zero-position joint angle to obtain the optimal joint angle corresponding to the right leg surgery, including: determining the absolute value of the difference between the zero-position joint angle and the optimal joint angle corresponding to the left leg surgery as the mirror value; and determining the sum of the zero-position joint angle and the mirror value as the optimal joint angle corresponding to the right leg surgery.
[0013] In the second aspect, the present application provides a device for determining the position of a robotic arm, including: a traversal module, used to traverse the target space with a preset step size to obtain a set of Cartesian poses of the end of the robotic arm; the target space is the working space of the robotic arm in the surgical area; a processing module, used to perform inverse kinematics processing on each Cartesian pose in the Cartesian pose set to obtain the joint angle corresponding to each Cartesian pose; one Cartesian pose corresponds to a group of joint angles, and a group of joint angles constitutes a robotic arm position; a calculation module, used to calculate the velocity Jacobian matrix corresponding to each group of joint angles, and calculate the singular parameters and stiffness parameters corresponding to each group of joint angles based on the velocity Jacobian matrix; the singular parameters are used to characterize the singularity of the robotic arm, and the stiffness parameters are used to characterize the stiffness of the robotic arm; a determination module, used to determine the joint angle with the smallest singular parameter and the largest stiffness parameter as the optimal joint angle.
[0014] In some embodiments, the calculation module is specifically used to: calculate the robot arm condition value corresponding to each group of joint angles according to the velocity Jacobian matrix; and determine the inverse of the robot arm condition value as the singular parameter corresponding to each group of joint angles.
[0015] In some embodiments, the calculation module is specifically used to: according to the speed Jacobian matrix and the formula Calculate the manipulator condition value corresponding to each set of joint angles; where s is used to represent the manipulator condition value and J is used to represent the velocity Jacobian matrix.
[0016] In some embodiments, the calculation module is specifically used to: calculate the linear displacement stiffness matrix corresponding to the target joint angle according to the velocity Jacobian matrix and the joint stiffness matrix; the target joint angle is the joint angle corresponding to any Cartesian pose in the Cartesian pose set; calculate the first radius, second radius and third radius of the operable ellipsoid of the robot arm in the flange coordinate system according to the linear displacement stiffness matrix; the first radius is the radius of the operable ellipsoid along the X-axis in the flange coordinate system, the second radius is the radius of the operable ellipsoid along the Y-axis in the flange coordinate system, and the third radius is the radius of the operable ellipsoid along the Z-axis in the flange coordinate system; map the operable ellipsoid to the plane where the X-axis and the Y-axis are located to obtain the major semi-axis radius and the minor semi-axis radius of the operable ellipse; determine the ratio of the minor semi-axis radius to the major semi-axis radius as the stiffness parameter corresponding to the target joint angle.
[0017] In some embodiments, the calculation module is specifically used to: determine the linear displacement stiffness matrix corresponding to the target joint angle by multiplying the inverse matrix of the joint stiffness matrix corresponding to the target joint angle, the velocity Jacobian matrix, and the transposed matrix of the velocity Jacobian matrix.
[0018] In some embodiments, the calculation module is specifically used to: determine the product of the linear displacement stiffness matrix and the transposed matrix of the linear displacement stiffness matrix as the target matrix; determine the eigenvalue of the target matrix as the first radius, second radius and third radius of the operable ellipsoid of the robotic arm in the flange coordinate system.
[0019] In some embodiments, the determination module is also used to determine the zero joint angle of the robotic arm when the robotic arm is the robotic arm of an anterior cruciate ligament reconstruction surgery robot and the calculated optimal joint angle corresponds to a left leg surgery; the processing module is also used to mirror the optimal joint angle corresponding to the left leg surgery according to the zero joint angle to obtain the optimal joint angle corresponding to the right leg surgery.
[0020] In some embodiments, the processing module is specifically used to: determine the absolute value of the difference between the zero-position joint angle and the optimal joint angle corresponding to the left leg surgery as the mirror value; determine the sum of the zero-position joint angle and the mirror value as the optimal joint angle corresponding to the right leg surgery.
[0021] In a third aspect, the present application provides an electronic device comprising: a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein when the computer program is executed by the processor, the method for determining the position of a robotic arm as in the first aspect is implemented.
[0022] In a fourth aspect, the present application provides a computer-readable storage medium, comprising: a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, it implements the method for determining the position of a robot arm as in the first aspect.
[0023] In a fifth aspect, the present application provides a computer program product, comprising: when the computer program product runs on a computer, the computer implements the method for determining the position of a robot arm as in the first aspect.
[0024] The technical solution provided by the present application has the following advantages compared with the prior art: First, the target space is traversed with a preset step size to obtain a set of Cartesian poses at the end of the robotic arm. Among them, the target space is the working space of the robotic arm in the surgical area. Afterwards, each Cartesian pose in the Cartesian pose set is subjected to inverse kinematics processing to obtain the joint angle corresponding to each Cartesian pose. Among them, one Cartesian pose corresponds to a group of joint angles, and a group of joint angles constitutes a robotic arm position. Afterwards, the velocity Jacobian matrix corresponding to each group of joint angles is calculated, and the singular parameters and stiffness parameters corresponding to each group of joint angles are calculated based on the velocity Jacobian matrix. Among them, the singular parameters are used to characterize the singularity of the robotic arm, and the stiffness parameters are used to characterize the stiffness of the robotic arm. Finally, the joint angle with the smallest singular parameter and the largest stiffness parameter is determined as the optimal joint angle. In this way, when determining the position of the robotic arm, the optimal joint angle can be determined based on the singularity and stiffness of the joint angle corresponding to the robotic arm, avoiding the problem of inaccurate position determination due to ignoring the pressure resistance of the position, thereby improving the accuracy of determining the position of the robotic arm. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0026] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0027] Figure 1 One of the flowcharts of the method for determining the position of a robotic arm provided in an embodiment of the present application;
[0028] Figure 2 A second flow chart of a method for determining the position of a robotic arm provided in an embodiment of the present application;
[0029] Figure 3 A third flowchart of a method for determining a robot arm position provided in an embodiment of the present application;
[0030] Figure 4 A fourth flowchart of a method for determining a robot arm position provided in an embodiment of the present application;
[0031] Figure 5 A fifth flowchart of a method for determining a robot arm position provided in an embodiment of the present application;
[0032] Figure 6Flow chart of the method for determining the position of a robot arm provided in an embodiment of the present application.
[0033] Figure 7 A schematic diagram of the structure of a device for determining the position of a robotic arm provided in an embodiment of the present application;
[0034] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0035] In order to more clearly understand the above-mentioned purposes, features and advantages of the present application, the scheme of the present application will be further described below. It should be noted that the embodiments of the present application and the features in the embodiments can be combined with each other without conflict.
[0036] In the following description, many specific details are set forth to facilitate a full understanding of the present application, but the present application may also be implemented in other ways different from those described herein; obviously, the embodiments in the specification are only part of the embodiments of the present application, rather than all of the embodiments.
[0037] First, some nouns or terms involved in the specification and claims of this application are explained below.
[0038] Degrees of freedom of a robotic arm: Usually used to characterize the ability of a robotic arm to move independently in space, the number of degrees of freedom is used to indicate the number of different directions or angles in which the robotic arm can move independently.
[0039] Joint angle of the robotic arm: A robotic arm generally includes multiple joints, so the posture of a robotic arm corresponds to multiple joint angles, and the number of joint angles is usually positively correlated with the degree of freedom of the robotic arm. The size of the joint angle is used to characterize the rotation angle of the joint in the robotic arm.
[0040] Singularity: usually refers to the characteristics of the robotic arm having difficulty in movement or loss of movement ability in certain specific positions or postures.
[0041] Stiffness: usually refers to the ability of the robot arm to resist deformation under external force.
[0042] The following is a detailed description of the method, device and storage medium for determining the position of the robot arm provided in the embodiments of the present application through specific embodiments in combination with the accompanying drawings.
[0043] The method for determining the position of the robotic arm provided in the embodiment of the present application can be executed by a device for determining the position of the robotic arm, and the device for determining the position of the robotic arm can be hardware or software. When the device for determining the position of the robotic arm is hardware, it can be various electronic devices with the function of determining the position of the robotic arm, including but not limited to surgical robots, computers, tablet computers, mobile phones, etc. When the device for determining the position of the robotic arm is software, it can be installed in the electronic devices listed above. It can be implemented as multiple software or software modules, or it can be implemented as a single software or software module. No specific limitation is made here.
[0044] Figure 1 A schematic diagram of a flow chart of a method for determining the position of a robotic arm provided in an embodiment of the present application, such as Figure 1 As shown, the method for determining the position of the robot arm may include the following steps.
[0045] S11. Traverse the target space with a preset step size to obtain a set of Cartesian poses at the end of the robotic arm.
[0046] Among them, the target space is the working space of the robotic arm in the surgical area.
[0047] For example, when the robotic arm is the robotic arm of an anterior cruciate ligament reconstruction surgery robot, the target space includes a tibial workspace and a femoral workspace. The tibial workspace refers to the workspace corresponding to the position of the robotic arm when drilling a hole in the tibia, and the femoral workspace refers to the workspace corresponding to the position of the robotic arm when drilling a hole in the femur; similarly, the Cartesian pose set includes a tibial Cartesian pose set and a femoral Cartesian pose set.
[0048] First, determine the target space.
[0049] Specifically, the method for determining the target space can be to receive the position of the target space sent by the host computer; it can also be the position of the target space obtained in real time by a position sensor installed on the robotic arm; it can also be the position of the target space calculated by the geometric structure of the robotic arm and the rotation range of the joint angle, which is not limited in this application.
[0050] Secondly, the target space is traversed with a preset step size to obtain the Cartesian pose set of the end of the robot arm.
[0051] In some embodiments, the method of traversing the target space with a preset step length to obtain a set of Cartesian poses of the end of the robotic arm may be: first obtaining the current Cartesian pose of the end of the robotic arm and the current joint angle of the robotic arm, and then using the current Cartesian pose as the initial pose, traversing the target space according to the preset step length to obtain the set of Cartesian poses of the end of the robotic arm. Among them, the method of obtaining the current Cartesian pose of the end of the robotic arm and the current joint angle of the robotic arm may be receiving the current Cartesian pose of the end of the robotic arm and the current joint angle of the robotic arm sent by the host computer.
[0052] In some embodiments, the method of traversing the target space with a preset step size to obtain a set of Cartesian poses of the end of the robot arm can also be: taking any point in the target space as the initial pose of the end of the robot arm, traversing the target space according to the preset step size, and obtaining a set of Cartesian poses of the end of the robot arm.
[0053] S12. Perform inverse kinematics processing on each Cartesian posture in the Cartesian posture set to obtain the joint angle corresponding to each Cartesian posture.
[0054] Among them, a Cartesian pose corresponds to a set of joint angles, and a set of joint angles constitutes a robotic arm position.
[0055] Specifically, the inverse kinematics (IK) processing refers to calculating the joint angles of each joint of the robotic arm based on the Cartesian pose of the end of the robotic arm, which can be achieved through the inverse kinematics algorithm. Among them, the inverse kinematics algorithm is currently a mature technology, and this application will not go into details. For example, for each Cartesian pose in the Cartesian pose set, an inverse kinematics processing is performed to obtain the joint angle corresponding to each Cartesian pose, which can be expressed as: q=ik(pose)=(x+step, y+step, z+step), where (x, y, z) is used to represent the Cartesian pose, q is used to represent the joint angle corresponding to the Cartesian pose, step is used to represent the preset step size, and ik() is used to represent the inverse kinematics algorithm.
[0056] For example, when the robot arm is a robot arm for anterior cruciate ligament reconstruction surgery, the target space is a cube interval of a*a*a, which can be expressed as For each tibial Cartesian posture in the tibial Cartesian posture set, inverse kinematics is performed to obtain the tibial joint angle corresponding to each tibial Cartesian posture; for each femoral Cartesian posture in the femoral Cartesian posture set, inverse kinematics is performed to obtain the femoral joint angle corresponding to each femoral Cartesian posture; which can be expressed as: Among them, (x 1 ,y 1 , z 1) is used to represent the Cartesian position of the tibia, q 1 Used to represent the tibial joint angle corresponding to the Cartesian position of the tibia; (x 2 ,y 2 , z 2 ) is used to represent the Cartesian position of the femur, q 2 Used to indicate the femoral joint angle corresponding to the femoral Cartesian posture; step is used to indicate the preset step size, and ik() is used to indicate the inverse kinematics algorithm.
[0057] S13. Calculate the velocity Jacobian matrix corresponding to each set of joint angles.
[0058] Specifically, for the first joint angle, the terminal velocity when the end of the robot is in the first Cartesian posture and the joint velocity when the joint angle of the robot joint is equal to the first joint angle are obtained; the ratio of the terminal velocity to the joint velocity is used as the velocity Jacobian matrix corresponding to the first joint angle. The first Cartesian posture is any Cartesian posture in the Cartesian posture set, and the first joint angle is the joint angle corresponding to the first Cartesian posture.
[0059] First, the end velocity of the robot arm when the end is in the first Cartesian posture is obtained, and the joint velocity of the robot arm joint when the joint angle is equal to the first joint angle.
[0060] In some embodiments, the terminal velocity of the robotic arm when the terminal is in a first Cartesian position and the joint velocity of the robotic arm when the joint angle is equal to the first joint angle can be obtained by installing relevant sensors on the robotic arm to collect motion parameters, and using the motion parameters to calculate the terminal velocity and joint velocity.
[0061] For example, a sensor can be installed at the end of the robotic arm to collect end motion parameters when the end of the robotic arm is in a first Cartesian position, and the end speed of the robotic arm when the end of the robotic arm runs to the first Cartesian position is determined based on the end motion parameters; sensors can be installed at the joints of the robotic arm to collect joint motion parameters when the joint angle of the robotic arm joint is equal to the first joint angle, and the joint speed of the robotic arm joint when it is equal to the first joint angle is determined based on the joint motion parameters.
[0062] In some embodiments, the terminal velocity when the terminal of the robot arm is in a first Cartesian position and the joint velocity when the joint angle of the robot arm joint is equal to the first joint angle can be obtained by receiving the terminal velocity and joint velocity sent by the host computer. This application does not limit this.
[0063] In some embodiments, the tip velocity includes a linear velocity and an angular velocity.
[0064] Secondly, the ratio of the end velocity to the joint velocity is used as the velocity Jacobian matrix corresponding to the first joint angle.
[0065] S14. Calculate the singular parameters and stiffness parameters corresponding to each set of joint angles according to the velocity Jacobian matrix.
[0066] Among them, the singular parameters are used to characterize the singularity of the robot arm, and the stiffness parameters are used to characterize the stiffness of the robot arm.
[0067] First, the singular parameters corresponding to each set of joint angles are calculated according to the velocity Jacobian matrix.
[0068] In some embodiments, Figure 2 As shown, the method of calculating the singular parameters corresponding to each set of joint angles according to the velocity Jacobian matrix can include the following steps:
[0069] S141. Calculate the robot arm condition value corresponding to each set of joint angles according to the velocity Jacobian matrix.
[0070] Specifically, the numerical method of calculating the manipulator condition corresponding to each set of joint angles according to the velocity Jacobian matrix can be based on the velocity Jacobian matrix and the formula Calculate the manipulator condition value corresponding to each set of joint angles; where s is used to represent the manipulator condition value, and J is used to represent the velocity Jacobian matrix; det(J*J T ) is used to represent the calculation of J and J T The determinant of the product.
[0071] S142. Determine the reciprocal of the robot arm condition value as the singular parameter corresponding to each set of joint angles.
[0072] Specifically, the singular parameters satisfy the following formula Among them, M is used to represent singular parameters, s is used to represent the condition value of the robot arm, and J is used to represent the velocity Jacobian matrix.
[0073] In the above scheme, the robot arm condition value corresponding to each group of joint angles can be calculated according to the velocity Jacobian matrix, and the inverse of the robot arm condition value can be determined as the singular parameter corresponding to each group of joint angles, so as to facilitate the subsequent determination of the optimal joint angle of the robot arm according to the singular parameters, thereby reducing the probability of the occurrence of singularity of the robot arm and improving the accuracy of determining the position of the robot arm.
[0074] Secondly, the stiffness parameters corresponding to each set of joint angles are calculated according to the velocity Jacobian matrix.
[0075] In some embodiments, Figure 3 As shown, the method of calculating the stiffness parameters corresponding to each group of joint angles according to the velocity Jacobian matrix can include the following steps:
[0076] S143. Calculate the linear displacement stiffness matrix corresponding to the target joint angle according to the velocity Jacobian matrix and the joint stiffness matrix.
[0077] Among them, the target joint angle is the joint angle corresponding to any Cartesian pose in the Cartesian pose set.
[0078] The stiffness of the robot arm can be calculated using the formula: To express it, ΔD is used to represent the displacement of the end of the robot after the force is applied, J is used to represent the velocity Jacobian matrix, and k q It is used to represent the joint stiffness, F is used to represent the force acting on the end of the robot arm; q is used to represent the target joint angle, and C(q) is used to represent the robot arm stiffness matrix.
[0079] Among them, due to C fd is the stiffness matrix of the linear displacement of the force under the action of external force; C md is the stiffness matrix of the linear displacement of the moment under the action of external force; C fδ is the stiffness matrix of the angular displacement of the force under the action of external force; C mδ is the stiffness matrix of the angular displacement of the torque under the action of external force. Stiffness refers to the ability of the robot to resist deformation under the action of external force, so only the stiffness matrix C of the linear displacement of the force under the action of external force is considered. fd The influence of linear displacement is Right now
[0080] Therefore, according to the velocity Jacobian matrix and the joint stiffness matrix, the linear displacement stiffness matrix corresponding to the target joint angle can be calculated as follows: The linear displacement stiffness matrix corresponding to the target joint angle is determined by multiplying the inverse matrix of the joint stiffness matrix corresponding to the target joint angle, the velocity Jacobian matrix, and the transposed matrix of the velocity Jacobian matrix. fd0 It is used to represent the linear displacement stiffness matrix corresponding to the target joint angle, J 0 It is used to represent the velocity Jacobian matrix corresponding to the target joint angle. The inverse matrix of the joint stiffness matrix corresponding to the target joint angle is used to represent the joint stiffness matrix. The transposed matrix used to represent the velocity Jacobian matrix corresponding to the target joint angles.
[0081] S144. Calculate, according to the linear displacement stiffness matrix, a first radius, a second radius, and a third radius of the operable ellipsoid of the robot arm in the flange coordinate system.
[0082] The first radius is the radius of the operable ellipsoid along the X-axis in the flange coordinate system, the second radius is the radius of the operable ellipsoid along the Y-axis in the flange coordinate system, and the third radius is the radius of the operable ellipsoid along the Z-axis in the flange coordinate system.
[0083] Specifically, Figure 4As shown, the method of calculating the first radius, the second radius and the third radius of the manipulator ellipsoid in the flange coordinate system according to the linear displacement stiffness matrix may include the following steps:
[0084] S1441. Determine the product of the linear displacement stiffness matrix and the transposed matrix of the linear displacement stiffness matrix as the target matrix.
[0085] Specifically, the target matrix satisfies the formula C = C fd T C fd , where C is used to represent the target matrix, C fd Used to represent the linear displacement stiffness matrix.
[0086] S1442. Determine the eigenvalues of the target matrix as the first radius, the second radius, and the third radius of the operable ellipsoid of the robot arm in the flange coordinate system.
[0087] Specifically, we can combine the formula ΔD T ΔD=(C fd F) T (C fd F)=F T C fd T C fd F=F T CF = 1, calculate the eigenvalue of the target matrix. Among them, C is used to represent the target matrix, ΔD is used to represent the stiffness of the robot arm (the displacement of the end of the robot arm after being subjected to force), C fd is used to represent the linear displacement stiffness matrix, and F is used to represent the force acting on the end of the robot arm. In addition, since C fd It is a 3×3 full rank matrix, so the target matrix also includes three eigenvalues, and these three eigenvalues are determined as the first radius, the second radius and the third radius of the manipulator's operable ellipsoid in the flange coordinate system.
[0088] S145, mapping the operable ellipsoid to the plane where the X-axis and the Y-axis are located, and obtaining the major semi-axis radius and the minor semi-axis radius of the operable ellipsoid.
[0089] For example, the three eigenvalues of the target matrix are λ 1 ,λ 2 ,λ 3 When , the operational ellipsoid can be expressed as: Among them, λ 1 Used to represent the first radius of the operational ellipsoid, λ 2 Used to represent the second radius of the operational ellipsoid, λ 3 It is used to represent the third radius of the operational ellipsoid, and (x, y, z) is used to represent the coordinates of any point on the operational ellipsoid.
[0090] The operational ellipsoid is mapped to the plane where the X-axis and the Y-axis are located, that is, z=0, and the operational ellipsoid is mapped to the plane where the X-axis and the Y-axis are located, and the operational ellipse is mapped to the plane where the X-axis and the Y-axis are located, which can be expressed as: Among them, λ t1 The radius of the first ellipse used to represent the operational ellipse, λ t2 It is used to represent the radius of the second ellipse of the operational ellipse. t1 and λ t2 The largest median value is determined as the major semi-axis radius, and the smallest median value is determined as the minor semi-axis radius.
[0091] S146. Determine the ratio of the short semi-axis radius to the long semi-axis radius as the stiffness parameter corresponding to the target joint angle.
[0092] For example, in λ t1 is the semi-major axis radius, λ t2 When is the radius of the minor semi-axis, the stiffness parameter corresponding to the target joint angle satisfies the formula: Among them, μ is used to represent the stiffness parameter, λ t1 is the semi-major axis radius, λ t2 is the semi-minor axis radius.
[0093] In the above scheme, the linear displacement stiffness matrix corresponding to the target joint angle can be calculated according to the velocity Jacobian matrix and the joint stiffness matrix, and the first radius, second radius and third radius of the manipulator ellipsoid in the flange coordinate system can be calculated according to the linear displacement stiffness matrix. After that, the manipulator ellipsoid is mapped to the plane where the X-axis and the Y-axis are located to obtain the long semi-axis radius and the short semi-axis radius of the manipulator ellipse, and the ratio of the short semi-axis radius to the long semi-axis radius is determined as the stiffness parameter corresponding to the target joint angle. In order to facilitate the subsequent determination of the optimal joint angle of the manipulator according to the stiffness parameters, the stiffness of the manipulator in all directions is guaranteed to be the best, the operating accuracy of the manipulator is improved, and thus the accuracy of determining the position of the manipulator is improved.
[0094] S15. Determine the joint angle with the smallest singular parameter and the largest stiffness parameter as the optimal joint angle.
[0095] Specifically, among the joint angles corresponding to multiple Cartesian postures, the joint angle with the smallest singular parameter and the largest stiffness parameter is selected as the optimal joint angle.
[0096] In the above scheme, the target space is first traversed with a preset step length to obtain a Cartesian pose set of the end of the manipulator. Among them, the target space is the working space of the manipulator in the surgical area. Afterwards, each Cartesian pose in the Cartesian pose set is subjected to inverse kinematics processing to obtain the joint angle corresponding to each Cartesian pose. Among them, one Cartesian pose corresponds to a set of joint angles, and a set of joint angles constitutes a manipulator position. Afterwards, the velocity Jacobian matrix corresponding to each set of joint angles is calculated, and the singular parameters and stiffness parameters corresponding to each set of joint angles are calculated according to the velocity Jacobian matrix. Among them, the singular parameters are used to characterize the singularity of the manipulator, and the stiffness parameters are used to characterize the stiffness of the manipulator. Finally, the joint angle with the smallest singular parameter and the largest stiffness parameter is determined as the optimal joint angle. In this way, when determining the position of the manipulator, the optimal joint angle can be determined according to the singularity and stiffness of the manipulator corresponding to the joint angle, avoiding the problem of inaccurate position determination due to ignoring the pressure resistance of the position, thereby improving the accuracy of determining the position of the manipulator.
[0097] In some embodiments, Figure 5 As shown, when the robotic arm is a robotic arm of an anterior cruciate ligament reconstruction surgery robot, and the calculated optimal joint angle corresponds to a left leg surgery, the method for determining the robotic arm position also includes:
[0098] S16. Determine the zero position joint angle of the robot arm.
[0099] Specifically, the method for determining the zero-position joint angle of the robotic arm can be to find the firmware parameters corresponding to the robotic arm to obtain the zero-position joint angle of the robotic arm, or to receive the zero-position joint angle of the robotic arm sent by the host computer. This application does not limit this.
[0100] S17. Mirror the optimal joint angle corresponding to the left leg surgery according to the zero-position joint angle to obtain the optimal joint angle corresponding to the right leg surgery.
[0101] Specifically, Figure 6 As shown, the method of performing mirror processing on the optimal joint angle corresponding to the left leg surgery according to the zero-position joint angle to obtain the optimal joint angle corresponding to the right leg surgery may include the following steps:
[0102] S171. Determine the absolute value of the difference between the zero-position joint angle and the optimal joint angle corresponding to the left leg surgery as the mirror value.
[0103] Specifically, the mirror value satisfies the following formula: Δq = abs(q zero -q left ), where Δq is used to represent the mirror value, q zero Used to represent the zero joint angle, q left Used to represent the optimal joint angle corresponding to the left leg surgery, abs(q zero -qleft ) is used to express the search for q zero and q left The absolute value of the difference.
[0104] S172. Determine the sum of the zero-position joint angle and the mirror image value as the optimal joint angle corresponding to the right leg surgery.
[0105] Specifically, the optimal joint angle corresponding to the right leg surgery satisfies the following formula: q right =q zero +Δq, where Δq is used to represent the mirror value, q zero Used to represent the zero joint angle, q right Used to represent the optimal joint angles corresponding to the right leg surgery.
[0106] In the above scheme, when the robot arm is the robot arm of an anterior cruciate ligament reconstruction surgery robot and the calculated optimal joint angle corresponds to the left leg surgery, the mirror value can be used to calculate the optimal joint angle corresponding to the right leg surgery, thereby avoiding the problem of needing to re-execute the robot arm positioning determination step when determining the optimal joint angle corresponding to the right leg surgery, thus saving computing resources. In addition, the use of the mirror method ensures the consistency of the robot arm's performance on the left and right legs, caters to the doctor's surgical habits, and improves the safety of the surgery to a certain extent.
[0107] The embodiment of the present application can divide the functional modules of the device for determining the position of the robot arm according to the above method example. For example, each functional module can be divided according to each function, or two or more functions can be integrated into one processing unit. The above integrated module can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical functional division. There may be other division methods in actual implementation.
[0108] like Figure 7 As shown, it is a schematic diagram of the structure of the device for determining the position of a robot arm provided in an embodiment of the present application. The device for determining the position of a robot arm includes a traversal module 51, a processing module 52, a calculation module 53 and a determination module 54.
[0109] The traversal module 51 is used to traverse the target space with a preset step size to obtain the Cartesian posture set of the end of the robot arm; the target space is the working space of the robot arm in the surgical area; the processing module 52 is used to perform inverse kinematics processing on each Cartesian posture in the Cartesian posture set to obtain the joint angle corresponding to each Cartesian posture; one Cartesian posture corresponds to a group of joint angles, and a group of joint angles constitutes a robot arm position; the calculation module 53 is used to calculate the velocity Jacobian matrix corresponding to each group of joint angles, and calculate the singular parameters and stiffness parameters corresponding to each group of joint angles according to the velocity Jacobian matrix; the singular parameters are used to characterize the singularity of the robot arm, and the stiffness parameters are used to characterize the stiffness of the robot arm; the determination module 54 is used to determine the joint angle with the smallest singular parameter and the largest stiffness parameter as the optimal joint angle.
[0110] In some embodiments, the calculation module 53 is specifically used to: calculate the manipulator condition value corresponding to each group of joint angles according to the velocity Jacobian matrix; and determine the inverse of the manipulator condition value as the singular parameter corresponding to each group of joint angles.
[0111] In some embodiments, the calculation module 53 is specifically used to: according to the speed Jacobian matrix and the formula Calculate the manipulator condition value corresponding to each set of joint angles; where s is used to represent the manipulator condition value and J is used to represent the velocity Jacobian matrix.
[0112] In some embodiments, the calculation module 53 is specifically used to: calculate the linear displacement stiffness matrix corresponding to the target joint angle according to the velocity Jacobian matrix and the joint stiffness matrix; the target joint angle is the joint angle corresponding to any Cartesian pose in the Cartesian pose set; calculate the first radius, second radius and third radius of the operable ellipsoid of the robot arm in the flange coordinate system according to the linear displacement stiffness matrix; the first radius is the radius of the operable ellipsoid along the X-axis in the flange coordinate system, the second radius is the radius of the operable ellipsoid along the Y-axis in the flange coordinate system, and the third radius is the radius of the operable ellipsoid along the Z-axis in the flange coordinate system; map the operable ellipsoid to the plane where the X-axis and the Y-axis are located to obtain the major semi-axis radius and the minor semi-axis radius of the operable ellipse; determine the ratio of the minor semi-axis radius to the major semi-axis radius as the stiffness parameter corresponding to the target joint angle.
[0113] In some embodiments, the calculation module 53 is specifically used to determine the linear displacement stiffness matrix corresponding to the target joint angle by multiplying the inverse matrix of the joint stiffness matrix corresponding to the target joint angle, the velocity Jacobian matrix, and the transposed matrix of the velocity Jacobian matrix.
[0114] In some embodiments, the calculation module 53 is specifically used to: determine the product of the linear displacement stiffness matrix and the transposed matrix of the linear displacement stiffness matrix as the target matrix; determine the eigenvalue of the target matrix as the first radius, second radius and third radius of the operable ellipsoid of the robotic arm in the flange coordinate system.
[0115] In some embodiments, the determination module 54 is also used to determine the zero joint angle of the robotic arm when the robotic arm is the robotic arm of an anterior cruciate ligament reconstruction surgery robot and the calculated optimal joint angle corresponds to a left leg surgery; the processing module 52 is also used to mirror the optimal joint angle corresponding to the left leg surgery according to the zero joint angle to obtain the optimal joint angle corresponding to the right leg surgery.
[0116] In some embodiments, the processing module 52 is specifically used to: determine the absolute value of the difference between the zero-position joint angle and the optimal joint angle corresponding to the left leg surgery as the mirror value; determine the sum of the zero-position joint angle and the mirror value as the optimal joint angle corresponding to the right leg surgery.
[0117] The device for determining the position of a robotic arm provided in this embodiment can execute the method for determining the position of a robotic arm provided in the above method embodiment. Its implementation principle and technical effect are similar to those of the above method and will not be repeated here.
[0118] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application.
[0119] like Figure 8 As shown, an embodiment of the present application provides an electronic device, which includes: a processor 801, a memory 802, and a computer program stored in the memory 802 and executable on the processor 801, and when the computer program is executed by the processor 801, each process of the method for determining the position of the robot arm in the above method embodiment is implemented. And the same technical effect can be achieved, so it will not be repeated here to avoid repetition.
[0120] An embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the various processes of the method for determining the position of the robot arm in the above-mentioned method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0121] The computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.
[0122] An embodiment of the present application provides a computer program product, which stores a computer program. When the computer program is executed by a processor, the various processes of the method for determining the position of the robot arm in the above method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0123] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media that include computer-usable program code.
[0124] In the present application, the processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0125] In this application, memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of a computer-readable medium.
[0126] In this application, computer-readable media includes permanent and non-permanent, removable and non-removable storage media. Storage media can be implemented by any method or technology to store information, and the information can be computer-readable instructions, data structures, modules of programs or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, read-only compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. According to the definition in this article, computer-readable media does not include temporary computer-readable media (transitory media), such as modulated data and carrier waves.
[0127] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0128] The above description is only a specific implementation of the present application, so that those skilled in the art can understand or implement the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments described herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for determining the position of a robotic arm, characterized in that: include: Traverse the target space with a preset step size to obtain the Cartesian pose set of the end of the robot arm; The target space is the working space of the robotic arm in the surgical area; For each Cartesian posture in the Cartesian posture set, inverse kinematics is performed to obtain a joint angle corresponding to each Cartesian posture; one Cartesian posture corresponds to a group of joint angles, and a group of joint angles constitutes a robot arm position; Calculate the velocity Jacobian matrix corresponding to each set of joint angles; Calculating singular parameters and stiffness parameters corresponding to each group of joint angles according to the velocity Jacobian matrix; the singular parameters are used to characterize the singularity of the robotic arm, and the stiffness parameters are used to characterize the stiffness of the robotic arm; The joint angle with the smallest singular parameter and the largest stiffness parameter is determined as the optimal joint angle; The calculating the singular parameters corresponding to each group of joint angles according to the velocity Jacobian matrix includes: Calculate the manipulator condition value corresponding to each group of joint angles according to the velocity Jacobian matrix; The reciprocal of the condition value of the robot arm is determined as the singular parameter corresponding to each set of joint angles; The stiffness parameters corresponding to each set of joint angles are calculated according to the velocity Jacobian matrix, including: Calculate the linear displacement stiffness matrix corresponding to the target joint angle according to the velocity Jacobian matrix and the joint stiffness matrix; the target joint angle is the joint angle corresponding to any Cartesian pose in the Cartesian pose set; Calculate the first radius, the second radius and the third radius of the operable ellipsoid of the manipulator in the flange coordinate system according to the linear displacement stiffness matrix; the first radius is the radius of the operable ellipsoid along the X-axis in the flange coordinate system, the second radius is the radius of the operable ellipsoid along the Y-axis in the flange coordinate system, and the third radius is the radius of the operable ellipsoid along the Z-axis in the flange coordinate system; Mapping the operable ellipsoid to the plane where the X-axis and the Y-axis are located to obtain the major semi-axis radius and the minor semi-axis radius of the operable ellipsoid; The ratio of the short semi-axis radius to the long semi-axis radius is determined as the stiffness parameter corresponding to the target joint angle.
2. The determination method according to claim 1, characterized in that: The step of calculating the linear displacement stiffness matrix corresponding to the target joint angle according to the velocity Jacobian matrix and the joint stiffness matrix includes: The product of the inverse matrix of the joint stiffness matrix corresponding to the target joint angle, the velocity Jacobian matrix, and the transposed matrix of the velocity Jacobian matrix is determined as the linear displacement stiffness matrix corresponding to the target joint angle.
3. The determination method according to claim 1, characterized in that: The calculating, according to the linear displacement stiffness matrix, a first radius, a second radius, and a third radius of the operable ellipsoid of the robot arm in the flange coordinate system comprises: Determine the product of the linear displacement stiffness matrix and the transposed matrix of the linear displacement stiffness matrix as a target matrix; The eigenvalues of the target matrix are determined as the first radius, the second radius and the third radius of the operable ellipsoid of the robot arm in the flange coordinate system.
4. The determination method according to any one of claims 1 to 3, characterized in that: When the robotic arm is a robotic arm of an anterior cruciate ligament reconstruction surgery robot, and the calculated optimal joint angle corresponds to a left leg surgery, the method further includes: Determining the zero joint angle of the robotic arm; The optimal joint angle corresponding to the left leg surgery is mirrored according to the zero-position joint angle to obtain the optimal joint angle corresponding to the right leg surgery.
5. The determination method according to claim 4, characterized in that: The mirror processing of the optimal joint angle corresponding to the left leg surgery according to the zero-position joint angle to obtain the optimal joint angle corresponding to the right leg surgery includes: The absolute value of the difference between the zero-position joint angle and the optimal joint angle corresponding to the left leg surgery is determined as a mirror value; The sum of the zero-position joint angle and the mirror image value is determined as the optimal joint angle corresponding to the right leg surgery.
6. A device for determining the position of a robot arm, characterized in that: include: The traversal module is used to traverse the target space with a preset step size to obtain the Cartesian pose set of the end of the robot arm; The target space is the working space of the robotic arm in the surgical area; A processing module is used to perform inverse kinematics processing on each Cartesian posture in the Cartesian posture set to obtain a joint angle corresponding to each Cartesian posture; one Cartesian posture corresponds to a group of joint angles, and a group of joint angles constitutes a robot arm position; A calculation module, used to calculate the velocity Jacobian matrix corresponding to each group of joint angles, and calculate the singular parameters and stiffness parameters corresponding to each group of joint angles according to the velocity Jacobian matrix; the singular parameters are used to characterize the singularity of the manipulator, and the stiffness parameters are used to characterize the stiffness of the manipulator; A determination module is used to determine the joint angle with the smallest singular parameter and the largest stiffness parameter as the optimal joint angle; Computing module, specifically used for: Calculate the manipulator condition value corresponding to each group of joint angles according to the velocity Jacobian matrix; The reciprocal of the condition value of the robot arm is determined as the singular parameter corresponding to each set of joint angles; Calculate the linear displacement stiffness matrix corresponding to the target joint angle according to the velocity Jacobian matrix and the joint stiffness matrix; the target joint angle is the joint angle corresponding to any Cartesian pose in the Cartesian pose set; Calculate the first radius, the second radius and the third radius of the operable ellipsoid of the manipulator in the flange coordinate system according to the linear displacement stiffness matrix; the first radius is the radius of the operable ellipsoid along the X-axis in the flange coordinate system, the second radius is the radius of the operable ellipsoid along the Y-axis in the flange coordinate system, and the third radius is the radius of the operable ellipsoid along the Z-axis in the flange coordinate system; Mapping the operable ellipsoid to the plane where the X-axis and the Y-axis are located to obtain the major semi-axis radius and the minor semi-axis radius of the operable ellipsoid; The ratio of the short semi-axis radius to the long semi-axis radius is determined as the stiffness parameter corresponding to the target joint angle.
7. An electronic device, characterized in that: include: A processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the method for determining the position of a robot arm as described in any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that: include: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method for determining the position of a robotic arm as described in any one of claims 1 to 5 is implemented.
9. A computer program product, characterized in that When the computer program product runs on a computer, the computer is enabled to implement the method for determining the position of a robot arm as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Rigidity-oriented robot machining pose optimization method
CN113954074A
Robot tail end pose tracking compensation method for aviation large component milling
CN115229796A