其他分享
首页 > 其他分享> > [学习SLAM]轮速仪的建模/机器人运动模型详细分析(理论篇)

[学习SLAM]轮速仪的建模/机器人运动模型详细分析(理论篇)

作者:互联网

机器人运动模型

由其他组采集到的轮速数据需要根据公式将速度转化为位移量,具体机器人运动模型有两大类。如下:

模型1

模型1 同类表达1-1

模型1 同类表达1-2

模型2

 

模型2 同类表达2-1

用轮速计实现双轮差动机器人的位姿估计

 

用轮速计实现双轮差动机器人的位姿估计

用轮速计实现双轮差动机器人的位姿估计

模型2 同类表达2-2 (图中坐标xy与公式相反)

模型2 同类表达2-3

 

 

mode 1

http://faculty.salina.k-state.edu/tim/robotics_sg/Control/kinematics/unicycle.html

12.1.3. The Unicycle Model

Dealing with the displacement and velocities of the two wheels of a differential drive robot is messy. A preferred model is that of a unicycle, where we can think of the robot as having one wheel that can move with a desired velocity (V) at a specified heading (\phi). Having the equations to translate between the unicycle model and our wheel velocities is what allows us to simplify the robot with the unicycle model. We have seen how to take measured wheel displacements to calculate the new robot pose. Now we do the reverse and calculate the desired wheel velocities from the unicycle model.

../../_images/unicycle.png

The Simplified Unicycle Robot Model

Note

We represent the measured forward velocity and robot orientation with variables V_x and \theta. The desired speed and direction are represented with the unicycle model using variables V and \phi.

In the global coordinate frame, we can represent the velocity of the unicycle robot as:

(1)\mathcal{U} = \left[ \begin{array}{c}                              \dot{x} \\ \dot{y} \\ \dot{\phi}                              \end{array} \right]                    = \left[ \begin{array}{c}                              V \!\cos\,\phi \\                              V \!\sin\,\phi \\                              \omega                              \end{array} \right]

12.1.3.1. The Jacobian

The kinematics of mechanical systems are often described in terms of Jacobian matrices. A Jacobian defines how movement of parts of a system affect the movement of the whole or a larger part of the system. Let V_s be the velocity vector of the system, \mathcal{P} be the pose of the system, and P_q be the pose vector of certain parts of the system.

\mathbf{J} = \frac{\partial \mathcal{P}}{\partial P_q}

V_s = \dfrac{\mathrm{d}\mathcal{P}}{\mathrm{d}t} = \frac{\partial \mathcal{P}}{\partial P_q}   \frac{\partial P_q}{\partial t} = \mathbf{J} \frac{\partial P_q}{\partial t}

We can calculate the robot velocity relative to the velocities of the left and right wheels. Recall from Updating the Robot Position that the kinematics of directional drive systems gives us the forward and rotational displacement of the robot within a short time interval based on the displacement of the left and right wheels. The forward and rotational velocities can also be computed using the velocity of the left and right wheels. The forward velocity is the average of the wheel velocities.

V_x = \frac{R}{2} \,(v_r + v_l)

Note

Remember that v_r and v_l have units of radians/second, while V_x has units of meters/second. Multiplying by R, which is the radius of the wheels (meters/radian) does the unit conversion.

The rotational velocity is the difference of the wheel velocities divided by the radius of rotation. In robotics literature, the radius of rotation is L, or the distance between the wheels. One way to think of this is to consider the case when the left wheel is stopped while the right wheel moves forward. The robot will rotate about the left wheel making an arc with radius of L.

../../_images/robot_rotation.png

\omega = \frac{R}{L}\,(v_r - v_l)

In the local coordinate frame, the three components of the robot velocity are its forward velocity (V_x), its perpendicular velocity (V_p) and its rotational velocity (\dot{\theta} = \omega) in radians per second. Differential Drive robots can not move perpendicular to the direction of wheel rotation, so V_p is always zero. This is the non-holonomic constraint of a differential drive system.

(2)\spalignvector{V_x; V_p; \omega} =          \spalignmat{R/2, R/2; 0, 0; R/L, -R/L}          \spalignvector{v_r; v_l} \\   \spalignvector{V_x; \omega} =          \spalignmat{R/2, R/2; R/L, -R/L}          \spalignvector{v_r; v_l}

Thus,

\mathbf{J} = \frac{R}{2 L}\,\spalignmat{L, L; 2, -2}.

In the global coordinate frame, the velocity vector is the time derivative of the pose.

\dot{\mathcal{P}} = \left[ \begin{array}{c}                              \dot{X} \\ \dot{Y} \\ \dot{\theta}                              \end{array} \right]                    = \spalignmat{\cos \theta, 0; \sin \theta, 0; 0, 1}                      \spalignvector{V_x; \omega}

Note

../../_images/differential_drive.PNG

12.1.3.2. Calculating Wheel Velocities

Starting with the desired forward and rotational velocities, we can calculate the desired wheel velocities. Using the above equations for V_x and \omega, we can use either inversion of Jacobian or equation substitution with some simple algebra to come up with the needed equations.

\spalignvector{V_x, \omega} = \mathbf{J} \,\spalignvector{v_r, v_l}

\spalignvector{v_r, v_l} = \mathbf{J}^{-1}\,\spalignvector{V_x, \omega}

\spalignvector{v_r, v_l} = \frac{1}{2 R}\,\spalignmat{2, L; 2, -L} \spalignvector{V_x, \omega}

v_r = \frac{2\,V_x + \omega\,L}{2\,R}

v_l = \frac{2\,V_x - \omega\,L}{2\,R}

Note

A desired forward velocity (V) is an expected input for steering the robot towards a goal, but we don’t normally think of a steering heading in terms of a rotational velocity (\omega). This is why we need a controller ... continue reading or see Steering the Robot.

 

mode 2

http://faculty.salina.k-state.edu/tim/robotics_sg/Control/kinematics/odometry.html

12.1.1. Using Odometry to Track Robot Movement

Odometry means measuring wheel rotation with the Optical Encoders – like the odometer on your car. Odometry is not always as accurate as one would like, but it is the cornerstone of tracking robot movement.

Odometry can be reliable enough to make it quite useful. Just don’t expect it to be perfect. Later, we’ll address the causes of Odometry Errors and analyze the magnitude of some errors.

12.1.1.1. Odometry Calculations

../../_images/arc.png

With different wheel velocities, the robot spans an arc.

If the two wheel velocities are different but constant long enough, the robot will turn in a complete circle around a center point P.

12.1.1.2. Updating the Robot Position

If in a short time interval, \Delta t, the two wheel velocities are relatively constant, then the robot’s forward velocity, V_x, and rotational velocity, \omega, and can also be considered constant and we can update the global position from \mathcal{P}_i = (x,y,\theta) to \mathcal{P}_{i+1} = (x',y',\theta').

For the sake of avoiding repetition, the derivation is not shown here, but it is clearly outlined in this short primer by Edwin Olson at MIT.

A Primer on Odometry and Motor Control

Olson shows that the new position x' and y' are given by:

x' = x + r_{center}[ -\sin \theta + \sin \phi \cos \theta + \sin \theta \cos \phi ]

y' = y + r_{center}[ \cos \theta - \cos \phi \cos \theta + \sin \theta \sin \phi ]

Now, to significantly simplify the equations, an approximation can be made. If \phi is small, as is usually the case for small time steps, we can approximate \sin \phi = \phi and \cos \phi = 1. Now this gives us:

x' = x + r_{center}[ -\sin \theta + \phi\,\cos \theta + sin \theta ]

x' = x + r_{center}\,\phi\,\cos \theta

x' = x + d_{center}\,\cos \theta

and

y' = y + r_{center}[ \cos \theta - \cos \theta + \phi\,\sin \theta ]

y' = y + r_{center}\,\phi\,\sin \theta

y' = y + d_{center}\,\sin \theta

The change in the robot’s direction of orientation, \phi, is the difference of the distances traveled by the wheels divided by radius of rotation, L, which is the distance between the wheels.

The odometry equations for (x',y',\theta') are:

d_{center} = \frac{d_{left} + d_{right}}{2}

\phi = \frac{d_{right} - d_{left}}{L}

\mathcal{P}_{i+1} = \left[ \begin{array}{c} X_i \\ Y_i \\ \theta_i \end{array} \right] + \left[ \begin{array}{c} d_{center}\,\cos \theta_i\\ d_{center}\,\sin \theta_i\\ \phi \end{array} \right]

It can also be found in the literature that as a compromise between the full equation and the simplification of assuming that \phi \approx 0, that the average orientation angle over the time interval is used to calculate the new position.

\mathcal{P}_{i+1} = \left[ \begin{array}{c} X_i \\ Y_i \\ \theta_i \end{array} \right] + \left[ \begin{array}{c} d_{center}\,\cos(\theta_i + \phi/\,2) \\ d_{center}\,\sin(\theta_i + \phi/\,2) \\ \phi \end{array} \right]

12.1.1.3. Alternatives to Odometry

标签:wheel,Odometry,velocities,robot,SLAM,轮速仪,velocity,详细分析,wheels
来源: https://blog.csdn.net/KYJL888/article/details/100515455