当前位置:网站首页>Introduction to robotics I. spatial transformation (1) posture, transformation
Introduction to robotics I. spatial transformation (1) posture, transformation
2022-07-06 00:52:00 【RuiH. AI】
Introduction to Robotics One 、 Spatial transformation (1) Postures
Preface
Due to the close relationship between visual servo and manipulator , Therefore, we should start from the foundation , Record the robot kinematics .
This paper records the position and posture of rigid bodies . actually , Spatial transformation in SLAM It has been mentioned once in the column , However, the introduction to robotics gives a more detailed description of rigid body motion .
Coordinate system
There are usually two coordinate systems , One is the world coordinate system for reference ( Cartesian coordinate system ), One is the rigid body coordinate system with the center of mass of the rigid body as the origin .
The robot coordinate system follows the right-hand rule , As shown in the figure below 
Postures
Posture is position and posture , Corresponding displacement and rotation . The position and posture of the robot must be referred to the world coordinate system .
Posture represents the relationship between reference systems .
Location
The position of the rigid body is represented by a vector .
There is a point in the figure above P P P, In a coordinate system { A } \{A\} { A} For reference , You can put the vector O P OP OP To express A P ^AP AP The location of , Its left superscript indicates the reference system . A P ^AP AP The coordinates of are expressed as :
A P = [ p x , p y , p z ] T ^AP = [p_x,p_y,p_z]^T AP=[px,py,pz]T
Posture
The attitude of the rigid body is represented by the unit vector of the three principal axes of the rigid body coordinate system in the reference system .

Above picture , X ^ B , Y ^ B , Z ^ B \hat X_B,\hat Y_B, \hat Z_B X^B,Y^B,Z^B Represents the unit vector of the three principal axes of the rigid body in the upper right corner , They are in the frame of reference { A } \{A\} { A} The expression of in is A X ^ B , A Y ^ B , A Z ^ B ^A\hat X_B, ^A\hat Y_B, ^A\hat Z_B AX^B,AY^B,AZ^B. These three unit vectors form the rotation matrix :
B A R = ( A X ^ B A Y ^ B A Z ^ B ) ^A_BR=(^A\hat X_B \quad ^A\hat Y_B \quad ^A\hat Z_B) BAR=(AX^BAY^BAZ^B)
So how to calculate the coordinates of the principal axis unit vector of the rigid body in the reference system ?
With A X ^ B ^A\hat X_B AX^B For example , Its x The value of the coordinate is actually A X ^ B ^A\hat X_B AX^B In the frame of reference X The projection on the axis ,y, z The coordinates are in the reference system Y, Z The projection on the axis :
B A R = ( A X ^ B A Y ^ B A Z ^ B ) = [ X ^ B ⋅ X ^ A Y ^ B ⋅ X ^ A Z ^ B ⋅ X ^ A X ^ B ⋅ Y ^ A Y ^ B ⋅ Y ^ A Z ^ B ⋅ Y ^ A X ^ B ⋅ Z ^ A Y ^ B ⋅ Y ^ A Z ^ B ⋅ X ^ A ] ^A_BR=(^A\hat X_B \quad ^A\hat Y_B \quad ^A\hat Z_B) = \begin{bmatrix} \hat X_B \cdot \hat X_A & \hat Y_B \cdot \hat X_A & \hat Z_B \cdot \hat X_A\\ \hat X_B \cdot \hat Y_A & \hat Y_B \cdot \hat Y_A & \hat Z_B \cdot \hat Y_A\\ \hat X_B \cdot \hat Z_A & \hat Y_B \cdot \hat Y_A & \hat Z_B \cdot \hat X_A\\ \end{bmatrix} BAR=(AX^BAY^BAZ^B)=⎣⎡X^B⋅X^AX^B⋅Y^AX^B⋅Z^AY^B⋅X^AY^B⋅Y^AY^B⋅Y^AZ^B⋅X^AZ^B⋅Y^AZ^B⋅X^A⎦⎤
The rotation matrix is an orthogonal matrix , The proof is simple :
B A R T B A R = [ A X ^ B T A Y ^ B T A Z ^ B T ] ( A X ^ B A Y ^ B A Z ^ B ) = I 3 ^A_BR^T\ ^A_B R= \begin{bmatrix} ^A\hat X^T_B \\ ^A\hat Y^T_B \\ ^A\hat Z^T_B \end{bmatrix} (^A\hat X_B \quad ^A\hat Y_B \quad ^A\hat Z_B) = I_3 BART BAR=⎣⎡AX^BTAY^BTAZ^BT⎦⎤(AX^BAY^BAZ^B)=I3
The inner product of the unit vector in the same direction is 1, The inner product of mutually perpendicular unit vectors is 0, therefore A X ^ B T A X ^ B = 1 , A X ^ B T A Y ^ B = 0 ^A\hat X^T_B \ ^A\hat X_B=1, ^A\hat X^T_B \ ^A\hat Y_B=0 AX^BT AX^B=1,AX^BT AY^B=0, So we can get the identity matrix above .
Pose transformation
Pose transformation refers to the change of the position and pose of the rigid body coordinate system , Translation and rotation , Get the relative pose between the rigid system and the reference system
Still in order to 2-2 For example , The pose transformation of rigid body coordinate system relative to reference system can be expressed as :
{ B A R , A P B O R G } \{^A_B R, \ ^AP_{BORG} \} { BAR, APBORG}
That is to say SLAM In the fourteenth lecture R , t R,t R,t
mapping
Mapping represents the coordinate transformation of the same point between different coordinate systems .
Mapping includes translation and rotation .
translation
Translation is related to the position of the origin of the rigid body coordinate system .
Above picture , It is known that B P ^BP BP Indication point P In the coordinate system { B } \{B\} { B} Position in , A P B O R G ^AP_{BORG} APBORG Expressed in the reference system { A } \{A\} { A} Next { B } \{B\} { B} The position of the origin . be A P ^AP AP Can be expressed as :
A P = B P + A P B O R G ^AP= \ ^BP + \ ^AP_{BORG} AP= BP+ APBORG
Only when the attitude of the two coordinate systems is the same , To perform the above translation .
rotate
Rotation is related to the attitude of the rigid body coordinate system .

Above picture , It is known that B P ^BP BP Indication point P In the coordinate system { B } \{B\} { B} Position in . A P ^AP AP Expressed in the reference system { A } \{A\} { A} The next position , Vector A P ^AP AP In the direction of the principal axis of the reference system X ^ A , Y ^ A , Z ^ A \hat X_A, \hat Y_A, \hat Z_A X^A,Y^A,Z^A The projection of ( Unit vector inner product ). Besides , We know , The inner product of a vector needs to be expressed in the same coordinate system to be meaningful . be A P ^AP AP Can be expressed as :
A P = [ B X ^ A ⋅ B P B Y ^ A ⋅ B P B Z ^ A ⋅ B P ] = B A R B P ^AP= \begin{bmatrix} ^B \hat X_A \cdot\ ^BP & ^B \hat Y_A \cdot\ ^BP & ^B \hat Z_A \cdot\ ^BP \end{bmatrix} = \ ^A_BR \ ^BP AP=[BX^A⋅ BPBY^A⋅ BPBZ^A⋅ BP]= BAR BP
Transformation
Transformation = Spin first , Back translation .

Above picture , Need to use B P ^BP BP Express A P ^AP AP. First of all, will B P ^BP BP Map to an intermediate coordinate system { B ′ } \{B'\} { B′}, The attitude of this coordinate system is consistent with { A } \{A\} { A} identical , Origin and { B } \{B\} { B} identical . And then use B ′ P ^{B'}P B′P Express A P ^AP AP:
A P = B ′ P + A P B ′ O R G = B B ′ R B P + A P B ′ O R G = B A R B P + A P B O R G ^AP = \ ^{B'}P + \ ^AP_{B'ORG} = \ ^{B'}_BR \ ^BP + \ ^AP_{B'ORG} = \ ^{A}_BR \ ^BP + \ ^AP_{BORG} AP= B′P+ APB′ORG= BB′R BP+ APB′ORG= BAR BP+ APBORG
It corresponds to SLAM In the fourteenth lecture P ′ = R P + t P'=RP+t P′=RP+t
Introduce homogeneous matrix , There is the concept of transformation matrix :
[ A P 1 ] = [ B A R A P B O R G 0 1 ] [ B P 1 ] A P = B A T B P \begin{bmatrix} ^AP \\ 1 \\ \end{bmatrix} = \begin{bmatrix} \ ^A_BR & ^AP_{BORG} \\ {\bf 0} & 1 \\ \end{bmatrix} \begin{bmatrix} \ ^BP \\ 1 \\ \end{bmatrix} \\ \quad \\ \\ \quad \\ ^AP = \ ^A_BT \ ^BP [AP1]=[ BAR0APBORG1][ BP1]AP= BAT BP
Composite transformation
If known B A T , C B T ^A_B T, \ ^B_CT BAT, CBT, You can use the C P ^CP CP Express A P ^AP AP:
A P = B A T C B T C P ^AP = ^A_BT \ ^B_CT \ ^CP AP=BAT CBT CP
inverse transformation
Inverse of rotation matrix :
B A R = A B R T ^A_B R = \ ^B_AR^T BAR= ABRT
Inverse of transformation matrix :
[ B A R T − B A R T A P B O R G 0 1 ] \begin{bmatrix} \ ^A_BR^T & -^A_BR^T\ ^AP_{BORG} \\ {\bf 0} & 1 \\ \end{bmatrix} [ BART0−BART APBORG1]
There are two ways to find the inverse of a transformation matrix , One is to find the inverse of the matrix directly ; The other is to find the inverse through the transformation property . Introduce the latter .

If known A P ^AP AP seek B P ^BP BP, Yes :
B P = A B R A P + B P A O R G ^BP = \ ^B_AR \ ^AP + \ ^BP_{AORG} BP= ABR AP+ BPAORG
If A P ^AP AP yes { B } \{B\} { B} The origin of , namely :
0 = B P B O R G = A B R A P B O R G + B P A O R G B P A O R G = − A B R A P B O R G = − B A R T A P B O R G B P = B A R T A P − B A R T A P B O R G {\bf 0} = ^BP_{BORG} = ^B_AR \ ^AP_{BORG} + \ ^BP_{AORG} \\ \quad \\ \ ^BP_{AORG} = - ^B_AR \ ^AP_{BORG} = -^A_BR^T \ ^AP_{BORG} \\ \quad \\ \ ^BP = \ ^A_BR^T \ ^AP - \ ^A_BR^T \ ^AP_{BORG} 0=BPBORG=ABR APBORG+ BPAORG BPAORG=−ABR APBORG=−BART APBORG BP= BART AP− BART APBORG
Postscript
This article is actually SLAM The clearer expression method of posture transformation in Lecture 14 , The reference system is placed on the left superscript .
边栏推荐
- How to make your own robot
- Interview must brush algorithm top101 backtracking article top34
- Getting started with devkit
- Anconda download + add Tsinghua +tensorflow installation +no module named 'tensorflow' +kernelrestart: restart failed, kernel restart failed
- Spark SQL null value, Nan judgment and processing
- KDD 2022 | EEG AI helps diagnose epilepsy
- Four dimensional matrix, flip (including mirror image), rotation, world coordinates and local coordinates
- Beginner redis
- 免费的聊天机器人API
- Cve-2017-11882 reappearance
猜你喜欢

Finding the nearest common ancestor of binary tree by recursion

uniapp开发,打包成H5部署到服务器

MIT博士论文 | 使用神经符号学习的鲁棒可靠智能系统
![Cf:h. maximum and [bit operation practice + K operations + maximum and]](/img/c2/9e58f18eec2ff92e164d8d156629cf.png)
Cf:h. maximum and [bit operation practice + K operations + maximum and]

2022-02-13 work record -- PHP parsing rich text

MySQL storage engine

KDD 2022 | 脑电AI助力癫痫疾病诊断

XML Configuration File
![[groovy] XML serialization (use markupbuilder to generate XML data | create sub tags under tag closures | use markupbuilderhelper to add XML comments)](/img/d4/4a33e7f077db4d135c8f38d4af57fa.jpg)
[groovy] XML serialization (use markupbuilder to generate XML data | create sub tags under tag closures | use markupbuilderhelper to add XML comments)

Recoverable fuse characteristic test
随机推荐
Cloud guide DNS, knowledge popularization and classroom notes
MYSQL GROUP_ The concat function realizes the content merging of the same ID
云导DNS和知识科普以及课堂笔记
RAID disk redundancy queue
MIT博士论文 | 使用神经符号学习的鲁棒可靠智能系统
Data analysis thinking analysis methods and business knowledge - analysis methods (III)
Promise
[groovy] compile time meta programming (compile time method interception | method interception in myasttransformation visit method)
Ubantu check cudnn and CUDA versions
如何制作自己的机器人
图解网络:TCP三次握手背后的原理,为啥两次握手不可以?
Building core knowledge points
curlpost-php
MCU realizes OTA online upgrade process through UART
数据分析思维分析方法和业务知识——分析方法(三)
孤勇者
Intensive learning weekly, issue 52: depth cuprl, distspectrl & double deep q-network
从 1.5 开始搭建一个微服务框架——调用链追踪 traceId
MIT doctoral thesis | robust and reliable intelligent system using neural symbol learning
Reading notes of the beauty of programming