提示:本文上接 机器人运动学笔记2——林沛群
文章目录
前言
本文将涉及到机器人学的轨迹规划相关内容。这些内容均来自学习过程中记录的笔记。笔记摘自台大机器人学之运动学——林沛群
一、机械手臂轨迹规划
1.1 机械手臂轨迹规划引言
- 轨迹:机械手臂的末端在一段时间内的位置速度加速度情况。
- 理想轨迹:光滑路径,速度加速度变化连续
1.2 Joint-Space下轨迹规划
步骤:
- 定义{T}刀具坐标系相对于{G}物体坐标系的起始点、过程点和终点,齐次变换矩阵为 T G T i {_T^G}T_i TGTi(包含移动转动自由度)
- 将 T G T i {_T^G}T_i TGTi以6个参数来表达 G X T = [ G P T o r g R O T ( G K ^ T , θ ) ] {_\ ^G}X_T=\left[\begin{matrix}{_\ ^G}P_{T\ org}\\ROT({_\ ^G}{\hat{K}}_T,\theta)\\\end{matrix}\right] GXT=[ GPT orgROT( GK^T,θ)](非rotation matrix的方式表达)
- 逆运动学:将手臂末端点状态转换到joint的状态: G X T → Θ i {_\ ^G}X_T\rightarrow\Theta_i GXT→Θi
- 在joint空间下规划 Θ i \Theta_i Θi光滑轨迹(smooth trajectories)
- 正运动学:将joint状态转换到手臂末端状态,检查末端点在Cartesian-space下轨迹的可行性。
2.3 Cartesian-Space下轨迹规划
步骤:
- 定义{T}刀具坐标系相对于{G}物体坐标系的起始点、过程点和终点,齐次变换矩阵为 T G T i {_T^G}T_i TGTi(包含移动转动自由度)
- 将 T G T i {_T^G}T_i TGTi以6个参数来表达 G X T = [ G P T o r g R O T ( G K ^ T , θ ) ] {_\ ^G}X_T=\left[\begin{matrix}{_\ ^G}P_{T\ org}\\ROT({_\ ^G}{\hat{K}}_T,\theta)\\\end{matrix}\right] GXT=[ GPT orgROT( GK^T,θ)](非rotation matrix的方式表达)
- 对所有手臂末端点状态规划光滑轨迹
- 将规划好手臂末端点状态的轨迹点转换到joint状态: G X T → Θ i {_\ ^G}X_T\rightarrow\Theta_i GXT→Θi
- 检查joint状态在Joint-space下轨迹的可行性
注释(采用笛卡尔坐标系下的轨迹规划):
- 具物理直观的轨迹
- 较高的运算负载
1.4 三次多项式(Cubic-Polynomials)
- 轨迹:不同的轨迹区段 [ t i , t i + 1 ] \left[t_i,t_{i+1}\right] [ti,ti+1]以不同参数的函数来规划。
- 光滑轨迹:需定义各函数的边界条件(包含位置速度 θ ( t i ) , θ ( t i + 1 ) , θ ˙ ( t i ) , θ ˙ ( t i + 1 ) \theta\left(t_i\right),\theta\left(t_{i+1}\right),\dot{\theta}\left(t_i\right),\dot{\theta}\left(t_{i+1}\right) θ(ti),θ(ti+1),θ˙(ti),θ˙(ti+1),4个条件,即 [ t i , t i + 1 ] \left[t_i,t_{i+1}\right] [ti,ti+1]轨迹中 t i t_i ti点所在位置和速度需要和 [ t i − 1 , t i ] \left[t_{i-1},t_i\right] [ti−1,ti]轨迹规划的终点 t i t_i ti相等, t i + 1 t_{i+1} ti+1点同理)
上图右边表示各阶次多项式的命名方式。
求解cubic-polynomial:
通式:
θ
(
t
~
)
=
a
0
+
a
1
t
+
a
2
t
2
+
a
3
t
3
\theta\left(\widetilde{t}\right)=a_0+a_1t+a_2t^2+a_3t^3
θ(t
)=a0+a1t+a2t2+a3t3
四个未知数:
a
0
,
a
1
,
a
2
,
a
3
a_0,a_1,a_2,a_3
a0,a1,a2,a3
对每个区间:
t
∈
[
t
i
,
t
i
+
1
]
t\in\left[t_i,t_{i+1}\right]
t∈[ti,ti+1]每一段的∆t可以不同,取决于过程点的设定
t
~
=
t
−
t
i
\widetilde{t}=t-t_i
t
=t−ti 所以
t
~
∣
t
=
t
i
=
0
\widetilde{t}|_{t=t_i}=0
t
∣t=ti=0 ,
t
~
∣
t
=
t
i
+
1
=
∆
t
=
t
i
+
1
−
t
i
>
0
\widetilde{t}|_{t=t_{i+1}}=∆t=ti+1-ti>0
t
∣t=ti+1=∆t=ti+1−ti>0
4个边界条件:
{
θ
(
t
~
∣
t
=
t
i
)
=
θ
i
=
a
0
θ
(
t
~
∣
t
=
t
i
+
1
)
=
θ
i
+
1
=
a
0
+
a
1
∆
t
+
a
2
∆
t
2
+
a
3
∆
t
3
θ
˙
(
t
~
∣
t
=
t
i
)
=
θ
˙
i
=
a
1
θ
˙
(
t
~
∣
t
=
t
i
+
1
)
=
θ
˙
i
+
1
=
a
1
+
2
a
2
∆
t
+
3
a
3
∆
t
2
\left\{\begin{matrix} \theta\left(\widetilde{t}|_{t=t_i}\right)=\theta_i=a_0\\\theta\left(\widetilde{t}|_{t=t_{i+1}}\right)=\theta_{i+1}=a_0+a_1∆t+a_2∆t^2+a_3∆t^3 \\\dot{\theta}\left(\widetilde{t}|_{t=t_i}\right)={\dot{\theta}}_i=a_1 \\\dot{\theta}\left(\widetilde{t}|_{t=t_{i+1}}\right)={\dot{\theta}}_{i+1}=a_1+{2a}_2∆t+3a_3∆t^2 \end{matrix}\right.
⎩⎪⎪⎨⎪⎪⎧θ(t
∣t=ti)=θi=a0θ(t
∣t=ti+1)=θi+1=a0+a1∆t+a2∆t2+a3∆t3θ˙(t
∣t=ti)=θ˙i=a1θ˙(t
∣t=ti+1)=θ˙i+1=a1+2a2∆t+3a3∆t2
最终求解:
{
a
0
=
θ
i
a
1
=
θ
˙
i
a
2
=
3
∆
t
2
(
θ
i
+
1
−
θ
i
)
−
2
∆
t
θ
˙
i
−
1
∆
t
θ
˙
i
+
1
a
3
=
−
2
∆
t
3
(
θ
i
+
1
−
θ
i
)
+
1
∆
t
2
(
θ
˙
i
+
1
−
θ
˙
i
)
\left\{\begin{matrix} a_0=\theta_i\\a_1={\dot{\theta}}_i \\a_2=\frac{3}{∆t^2}(\theta_{i+1}-\theta_{i})-\frac{2}{∆t}{\dot{\theta}}_i-\frac{1}{∆t}{\dot{\theta}}_{i+1} \\a_3=-\frac{2}{∆t^3}(\theta_{i+1}-\theta_{i})+\frac{1}{∆t^2}({\dot{\theta}}_{i+1}-{\dot{\theta}}_i) \end{matrix}\right.
⎩⎪⎪⎨⎪⎪⎧a0=θia1=θ˙ia2=∆t23(θi+1−θi)−∆t2θ˙i−∆t1θ˙i+1a3=−∆t32(θi+1−θi)+∆t21(θ˙i+1−θ˙i)
以矩阵的形式解:
[
θ
i
θ
i
+
1
θ
˙
i
θ
˙
i
+
1
]
=
[
1
0
0
0
1
∆
t
∆
t
2
∆
t
3
0
1
0
0
0
1
2
∆
t
3
∆
t
2
]
[
a
0
a
1
a
2
a
3
]
\left[\begin{matrix}\begin{matrix}\theta_i\\\theta_{i+1}\\\end{matrix}\\\begin{matrix}{\dot{\theta}}_i\\{\dot{\theta}}_{i+1}\\\end{matrix}\\\end{matrix}\right]=\begin{bmatrix} 1 & 0 & 0 & 0\\ 1 & ∆t & ∆t^2 & ∆t^3 \\ 0 & 1 & 0 & 0\\ 0 & 1 & 2∆t & 3∆t^2 \end{bmatrix}\left[\begin{matrix}\begin{matrix}a_0\\a_1\\\end{matrix}\\\begin{matrix}a_2\\a_3\\\end{matrix}\\\end{matrix}\right]
⎣⎢⎢⎡θiθi+1θ˙iθ˙i+1⎦⎥⎥⎤=⎣⎢⎢⎡11000∆t110∆t202∆t0∆t303∆t2⎦⎥⎥⎤⎣⎢⎢⎡a0a1a2a3⎦⎥⎥⎤
Θ
=
T
4
×
4
(
∆
t
)
∙
A
\Theta=T_{4\times4}(∆t)∙A
Θ=T4×4(∆t)∙A
det
(
T
4
×
4
)
=
−
∆
t
4
≠
0
可
逆
\det{\left(T_{4\times4}\right)}=-∆t^4≠0可逆
det(T4×4)=−∆t4=0可逆
A
=
T
4
×
4
−
1
∙
Θ
A=T_{4\times4}^{-1}\bullet\Theta
A=T4×4−1∙Θ
[
a
0
a
1
a
2
a
3
]
=
[
1
0
0
0
0
0
0
1
−
3
∆
t
2
3
∆
t
2
−
2
∆
t
−
1
∆
t
2
∆
t
3
−
2
∆
t
2
1
∆
t
2
1
∆
t
2
]
[
θ
i
θ
i
+
1
θ
˙
i
θ
˙
i
+
1
]
\left[\begin{matrix}\begin{matrix}a_0\\a_1\\\end{matrix}\\\begin{matrix}a_2\\a_3\\\end{matrix}\\\end{matrix}\right]=\begin{bmatrix} 1 & 0 & 0 & 0\\ 0 & 0 & 0 & 1\\ -\frac{3}{∆t^2} & \frac{3}{∆t^2} & -\frac{2}{∆t} & -\frac{1}{∆t}\\ \frac{2}{∆t^3} & -\frac{2}{∆t^2} & \frac{1}{∆t^2} & \frac{1}{∆t^2} \end{bmatrix}\left[\begin{matrix}\begin{matrix}\theta_i\\\theta_{i+1}\\\end{matrix}\\\begin{matrix}{\dot{\theta}}_i\\{\dot{\theta}}_{i+1}\\\end{matrix}\\\end{matrix}\right]
⎣⎢⎢⎡a0a1a2a3⎦⎥⎥⎤=⎣⎢⎢⎡10−∆t23∆t3200∆t23−∆t2200−∆t2∆t2101−∆t1∆t21⎦⎥⎥⎤⎣⎢⎢⎡θiθi+1θ˙iθ˙i+1⎦⎥⎥⎤
1.5 多段Cubic-Polynomials
如何选择速度条件 θ ˙ i {\dot{\theta}}_i θ˙i和 θ ˙ i + 1 {\dot{\theta}}_{i+1} θ˙i+1?
- 直接定义(不建议)
- 自动生成。如果 θ ˙ i {\dot{\theta}}_i θ˙i在 t i t_i ti前后变号,选择 θ ˙ i = 0 {\dot{\theta}}_i=0 θ˙i=0;如果 θ ˙ i {\dot{\theta}}_i θ˙i在 t i t_i ti前后不变号,选择平均值
规划速度使过程中加速度也连续(有效使用此可控变量):
不同区段cubic-polynomial需要整合一起,一并求解。
加速度调控的例子:
上方示例的矩阵法求解:
1.6 N段路径的三次多项式(General Cubic Polynomials)
N段路径则有n个三次多项式,总共4N个未知参数。
4N个未知参数需要4N个方程求解。
还需要2个条件(方程)有3种选择:
示例1(平面RRR手臂Cartesian-space):
求解步骤从左到右从上到下依次为,
示例2(平面RRR手臂joint-space):
求解步骤从左到右从上到下依次为,
当路径规划过程中需要规划位置速度加速度时将使用五次多项式。
二、含抛物线的线性函数
2.1 Linear Function with Parabolic Blends
使用该混合抛物线的线性函数的原因:
- 许多任务中需要使用直线轨迹。
- 轨迹中包含多段直线轨迹,线段转折点速度不连续
- 解决方案:将直线段两端修正为二次方程式,让速度轨迹光滑。
规划方式:
上图中式②=①可得,
θ
¨
t
b
=
θ
˙
t
b
=
θ
h
−
θ
b
t
h
−
t
b
=
θ
f
−
θ
0
2
−
(
θ
0
+
1
2
θ
¨
t
b
2
)
t
f
2
−
t
b
=
θ
f
−
θ
0
−
θ
¨
t
b
2
t
f
−
2
t
b
\ddot{\theta}t_b={\dot{\theta}}_{t_b}=\frac{\theta_h-\theta_b}{t_h-t_b}=\frac{\frac{\theta_f-\theta_0}{2}-(\theta_0+\frac{1}{2}\ddot{\theta}{t_b}^2)}{\frac{t_f}{2}-t_b}=\frac{\theta_f-\theta_0-\ddot{\theta}{t_b}^2}{t_f-{2t}_b}
θ¨tb=θ˙tb=th−tbθh−θb=2tf−tb2θf−θ0−(θ0+21θ¨tb2)=tf−2tbθf−θ0−θ¨tb2
θ
¨
t
b
2
−
θ
¨
t
f
t
b
+
(
θ
f
−
θ
0
)
=
0
\ddot{\theta}{t_b}^2-\ddot{\theta}t_ft_b+(\theta_f-\theta_0)=0
θ¨tb2−θ¨tftb+(θf−θ0)=0
t
b
=
θ
¨
t
f
−
θ
¨
2
t
f
2
−
4
θ
¨
(
θ
f
−
θ
0
)
2
θ
¨
t_b=\frac{\ddot{\theta}t_f-\sqrt{{\ddot{\theta}}^2{t_f}^2-4\ddot{\theta}(\theta_f-\theta_0)}}{2\ddot{\theta}}
tb=2θ¨θ¨tf−θ¨2tf2−4θ¨(θf−θ0)
判别式内需为
θ
¨
2
t
f
2
−
4
θ
¨
(
θ
f
−
θ
0
)
≥
0
\sqrt{{\ddot{\theta}}^2{t_f}^2-4\ddot{\theta}(\theta_f-\theta_0)}≥0
θ¨2tf2−4θ¨(θf−θ0)≥0,所得
t
b
t_b
tb才为实数:
θ
¨
≥
4
(
θ
f
−
θ
0
)
t
f
2
\ddot{\theta}\geq\frac{4(\theta_f-\theta_0)}{{t_f}^2}
θ¨≥tf24(θf−θ0)
θ
¨
m
i
n
=
4
(
θ
f
−
θ
0
)
t
f
2
{\ddot{\theta}}_{min}=\frac{4(\theta_f-\theta_0)}{{t_f}^2}
θ¨min=tf24(θf−θ0)
加速度状态讨论:
1.如果
θ
¨
=
θ
¨
m
i
n
\ddot{\theta}={\ddot{\theta}}_{min}
θ¨=θ¨min
t
b
=
t
f
2
=
t
h
⇒
t_b=\frac{t_f}{2}=t_h\Rightarrow
tb=2tf=th⇒无线性线段,两个抛物线曲线段相连,
在
t
b
t_b
tb处:
θ
˙
(
t
b
)
=
θ
¨
t
b
=
4
(
θ
f
−
θ
0
)
t
f
2
t
f
2
=
2
θ
f
−
θ
0
t
f
\dot{\theta}\left(t_b\right)=\ddot{\theta}t_b=\frac{4(\theta_f-\theta_0)}{{t_f}^2}\frac{t_f}{2}=2\frac{\theta_f-\theta_0}{t_f}
θ˙(tb)=θ¨tb=tf24(θf−θ0)2tf=2tfθf−θ0,
速度为和原本无规划直接相连的速度:
θ
˙
=
θ
f
−
θ
0
t
f
\dot{\theta}=\frac{\theta_f-\theta_0}{t_f}
θ˙=tfθf−θ0相比为2倍。
2.如果
θ
¨
<
θ
¨
m
i
n
\ddot{\theta}<{\ddot{\theta}}_{min}
θ¨<θ¨min,
加速度不足,在
t
b
=
t
h
t_b=t_h
tb=th,
θ
<
θ
h
\theta<\theta_h
θ<θh,
导致
t
h
t_h
th时抛物线和直线不连续。
2.2 多段Linear Function with Parabolic Blends
多个中间点的路径,此时每一段类比前一节的始末位置,只不过现在每一段的始末位置的速度不为0。
类似需要规划图中所示的路径,分为第一个线段部分,中间线段部分,最后一个线段部分。
对于中间线段部分:
上图中,
t
θ
j
t_{\theta_j}
tθj,
t
θ
k
t_{\theta_k}
tθk表示到达点j和点k所在位置的时间
t
j
t_j
tj,
t
k
t_k
tk表示点j和点k所在位置部分二次曲线段经历的时间,
t
j
k
t_{jk}
tjk表示点j到点k路径中直线段经历的时间,
t
k
l
t_{kl}
tkl同理,
t
d
j
k
t_{djk}
tdjk表示从点j到点k路径经历的时间。
对上图中j到k段和k到l段(或者说对于任意一段
θ
i
\theta_i
θi到
θ
i
+
1
\theta_{i+1}
θi+1区间):
Linea部分:
θ
˙
j
k
=
θ
k
−
θ
j
t
d
j
k
{\dot{\theta}}_{jk}=\frac{\theta_k-\theta_j}{t_{djk}}
θ˙jk=tdjkθk−θj
θ
˙
k
l
=
θ
l
−
θ
k
t
d
k
l
{\dot{\theta}}_{kl}=\frac{\theta_l-\theta_k}{t_{dkl}}
θ˙kl=tdklθl−θk
Parabolic部分:
方法一:设定加速度解时间
θ
¨
k
=
s
i
g
n
(
θ
˙
k
l
−
θ
˙
j
k
)
∣
θ
¨
k
∣
{\ddot{\theta}}_k=sign({\dot{\theta}}_{kl}-{\dot{\theta}}_{jk})\left|{\ddot{\theta}}_k\right|
θ¨k=sign(θ˙kl−θ˙jk)∣∣∣θ¨k∣∣∣
t
k
=
θ
˙
k
l
−
θ
˙
j
k
θ
¨
k
t_k=\frac{{\dot{\theta}}_{kl}-{\dot{\theta}}_{jk}}{{\ddot{\theta}}_k}
tk=θ¨kθ˙kl−θ˙jk
上式中,
∣
θ
¨
k
∣
|{\ddot{\theta}}_k|
∣θ¨k∣的大小时需要我们设定的参数,
s
i
g
n
(
)
sign()
sign()表示取符号操作,仅获取
θ
˙
k
l
−
θ
˙
j
k
{\dot{\theta}}_{kl}-{\dot{\theta}}_{jk}
θ˙kl−θ˙jk结果的符号。
方法二:设定时间解加速度
θ
¨
k
=
θ
˙
k
l
−
θ
˙
j
k
t
k
{\ddot{\theta}}_k=\frac{{\dot{\theta}}_{kl}-{\dot{\theta}}_{jk}}{t_k}
θ¨k=tkθ˙kl−θ˙jk
上式中,
t
k
t_k
tk的大小时需要我们设定的参数。
最后计算出直线部分经历的
t
j
k
t_{jk}
tjk时间,
t
j
k
=
t
d
j
k
−
1
2
t
j
−
1
2
t
k
t_{jk}=t_{djk}-\frac{1}{2}t_j-\frac{1}{2}t_k
tjk=tdjk−21tj−21tk
对于第一个线段部分:
上图中,
t
θ
1
t_{\theta_1}
tθ1,
t
θ
2
t_{\theta_2}
tθ2表示到达
θ
1
\theta_1
θ1和到达
θ
2
\theta_2
θ2时的时间,
t
1
t_1
t1表示初始第一个线段二次曲线段经历的时间,
θ
1
\theta_1
θ1的位置可以视为将整个起始点为
θ
0
\theta_0
θ0的轨迹在时间上向后平移了
t
1
2
\frac{t_1}{2}
2t1时
θ
0
\theta_0
θ0所在的位置,目的时为了便于增加一段二次曲线缓加速部分。否则,
θ
0
\theta_0
θ0在
θ
\theta
θ轴上,则没有初始的二次曲线部分。
t
12
t_{12}
t12表示点1到点2路径中直线段经历的时间,
t
d
12
t_{d12}
td12表示从起始位置到点2路径(二次曲线段+直线段)经历的时间。
方法一:设定加速度解时间
θ
¨
1
=
s
i
g
n
(
θ
2
−
θ
1
)
∣
θ
¨
1
∣
{\ddot{\theta}}_1=sign(\theta_2-\theta_1)\left|{\ddot{\theta}}_1\right|
θ¨1=sign(θ2−θ1)∣∣∣θ¨1∣∣∣
θ
˙
12
=
θ
2
−
θ
1
t
d
12
−
1
2
t
1
=
θ
¨
1
t
1
{\dot{\theta}}_{12}=\frac{\theta_2-\theta_1}{t_{d12}-\frac{1}{2}t_1}={\ddot{\theta}}_1t_1
θ˙12=td12−21t1θ2−θ1=θ¨1t1
1
2
θ
¨
1
t
1
2
−
t
d
12
θ
¨
1
t
1
+
(
θ
2
−
θ
1
)
=
0
\frac{1}{2}{\ddot{\theta}}_1t_1^2-t_{d12}{\ddot{\theta}}_1t_1+{(\theta}_2-\theta_1)=0
21θ¨1t12−td12θ¨1t1+(θ2−θ1)=0
t
1
=
t
d
12
−
t
d
12
2
−
2
(
θ
2
−
θ
1
)
θ
¨
1
t_1=t_{d12}-\sqrt{{t_{d12}}^2-\frac{{2(\theta}_2-\theta_1)}{{\ddot{\theta}}_1}}
t1=td12−td122−θ¨12(θ2−θ1)
上式中,
s
i
g
n
(
)
sign()
sign()表示取符号操作,仅获取
θ
2
−
θ
1
\theta_2-\theta_1
θ2−θ1结果的符号,
∣
θ
¨
1
∣
|{\ddot{\theta}}_1|
∣θ¨1∣的大小时需要我们设定的参数。
方法二:设定时间解加速度
θ
¨
1
=
θ
2
−
θ
1
(
t
d
12
−
1
2
t
1
)
1
t
1
{\ddot{\theta}}_1=\frac{\theta_2-\theta_1}{(t_{d12}-\frac{1}{2}t_1)}\frac{1}{t_1}
θ¨1=(td12−21t1)θ2−θ1t11
t
12
=
t
d
12
−
t
1
−
1
2
t
2
t_{12}=t_{d12}-t_1-{\frac{1}{2}t_2}
t12=td12−t1−21t2
上式中,
t
1
t_1
t1的大小时需要我们设定的参数,
t
2
t_2
t2是点2所在部分的二次曲线段经历的时间。
对于最后一个线段部分:
上图中:
t
θ
n
t_{\theta_n}
tθn,
t
θ
n
−
1
t_{\theta_{n-1}}
tθn−1表示到达
θ
n
\theta_n
θn和到达
θ
n
−
1
\theta_{n-1}
θn−1时的时间,
t
n
t_n
tn表示最后一个线段二次曲线段经历的时间,
θ
n
\theta_n
θn的位置可以视为将整个终点为
θ
f
\theta_f
θf的轨迹在时间上向前平移了
t
n
2
\frac{t_n}{2}
2tn时
θ
f
\theta_f
θf所在的位置,目的时为了便于增加一段二次曲线缓减速部分。否则,
θ
f
\theta_f
θf在整个轨迹的终点上,则没有最终的二次曲线部分。
t
(
n
−
1
)
n
t_{(n-1)n}
t(n−1)n表示点n-1到点n路径中直线段经历的时间,
t
d
(
n
−
1
)
n
t_{d(n-1)n}
td(n−1)n表示从n-1到最终位置路径(二次曲线段+直线段)经历的时间。
方法一:设定加速度解时间
θ
¨
n
=
s
i
g
n
(
θ
n
−
θ
n
−
1
)
∣
θ
¨
n
∣
{\ddot{\theta}}_n=sign(\theta_n-\theta_{n-1})\left|{\ddot{\theta}}_n\right|
θ¨n=sign(θn−θn−1)∣∣∣θ¨n∣∣∣
θ
˙
(
n
−
1
)
n
=
θ
n
−
θ
n
−
1
t
d
(
n
−
1
)
n
−
1
2
t
n
=
θ
¨
n
(
−
t
n
)
{\dot{\theta}}_{(n-1)n}=\frac{\theta_n-\theta_{n-1}}{t_{d(n-1)n}-\frac{1}{2}t_n}={\ddot{\theta}}_n{(-t}_n)
θ˙(n−1)n=td(n−1)n−21tnθn−θn−1=θ¨n(−tn)
1
2
θ
¨
n
t
n
2
−
t
d
(
n
−
1
)
n
θ
¨
n
t
n
−
(
θ
n
−
θ
n
−
1
)
=
0
\frac{1}{2}{\ddot{\theta}}_nt_n^2-t_{d\left(n-1\right)n}{\ddot{\theta}}_nt_n-{(\theta}_n-\theta_{n-1})=0
21θ¨ntn2−td(n−1)nθ¨ntn−(θn−θn−1)=0
t
n
=
t
d
(
n
−
1
)
n
−
t
d
(
n
−
1
)
n
2
−
2
(
θ
n
−
θ
n
−
1
)
θ
¨
n
t_n=t_{d(n-1)n}-\sqrt{{t_{d(n-1)n}}^2-\frac{{2(\theta}_n-\theta_{n-1})}{{\ddot{\theta}}_n}}
tn=td(n−1)n−td(n−1)n2−θ¨n2(θn−θn−1)
上式中,
s
i
g
n
(
)
sign()
sign()表示取符号操作,仅获取
θ
n
−
θ
n
−
1
\theta_n-\theta_{n-1}
θn−θn−1结果的符号,
∣
θ
¨
n
∣
|{\ddot{\theta}}_n|
∣θ¨n∣的大小时需要我们设定的参数。
方法二:设定时间解加速度
θ
¨
n
=
θ
n
−
θ
n
−
1
(
t
d
12
−
1
2
t
n
)
1
−
t
n
{\ddot{\theta}}_n=\frac{\theta_n-\theta_{n-1}}{(t_{d12}-\frac{1}{2}t_n)}\frac{1}{-t_n}
θ¨n=(td12−21tn)θn−θn−1−tn1
t
(
n
−
1
)
n
=
t
d
(
n
−
1
)
n
−
t
n
−
1
2
t
n
−
1
t_{(n-1)n}=t_{d(n-1)n}-t_n-{\frac{1}{2}t_{n-1}}
t(n−1)n=td(n−1)n−tn−21tn−1
上式中,
t
n
t_n
tn的大小时需要我们设定的参数,
t
n
−
1
t_{n-1}
tn−1是点n-1所在部分的二次曲线段经历的时间。
2.3 Linear Function with Parabolic Blends注解
一、真实系统中可达到的加速度
θ
¨
\ddot{\theta}
θ¨取决于许多因素
1.马达规格
2.手臂姿态:手臂在不同姿态下,各轴所需承载(如重力)的扭力不同
3.手臂动态状态:手臂在不同动态下,各轴需承载惯性力不同
二、规划后轨迹未通过中间过程点
仅加速度无限大时轨迹有通过中间过程点(via points)
如果通过中间过程点为必须,需要建立伪中间过程点(pseudo via points) ,让原本的中间过程点落在直线段上。
三、若有Cartesian space 下有某些部分有直线轨迹的需求,轨迹规划需要在Cartesian space下进行。
四、编程里,仔细定义好某时间t所属的线段或曲线段。
2.4 Cartesian Space 下轨迹几何极限
一、中间某些区域无法到达。(在工作空间(work space)之外)
二、轨迹需要高加减速。(接近singular configuration)
三、针对特定起始和终点姿态,无法产生连续轨迹(几何上不可能)
如下图,除非
l
1
−
l
2
=
d
l_1-l_2=d
l1−l2=d
2.5 回顾R-R-R机械臂(Revisit the RRR Manipulator)
总结
以上就是今天要讲的内容,本文是本人观看机器人运动学所作的笔记,本文主要包含轨迹规划部分。整个笔记到此都已经完结。