四、车辆横向控制(基于几何)

1、车辆横向运动学模型

1.1、自行车模型(二自由度模型)

车辆运动学模型用于描述车辆在二维平面上的运动能力。在车速不高的情况下,自行车模型已能够符合实际需求,该模型遵循以下几点假设:

(1)车辆行驶于平坦路面,忽略车辆在垂直于路面方向上的运动;

(2)忽略车辆在行驶中受到的空气阻力以及地面侧向摩擦力;

(3)车轮与地面始终保持良好的滚动接触;

(4)车辆为刚体,忽略车身悬架结构的影响;

(5)左右两前轮、两后轮的转向角相等;

在这里插入图片描述

惯性坐标系下的自行车模型如上图所示。

ψ \psi ψ为车辆横摆角,即车辆的纵轴 x ⃗ \vec{x} x X ⃗ \vec{X} X 轴之间的夹角(绝对坐标系);

β \beta β为质心侧偏角,即车辆的纵轴 x ⃗ \vec{x} x 与质心速度的夹角(车身坐标系);

δ f \delta_f δf δ r \delta_r δr分别为前轮转角与后轮转角(一般为0);

l f l_f lf l r l_r lr分别为质心距前轴和后轴的距离;

在建立系统的状态空间表达式前,可以确定系统的控制量和状态量。

控制量:

前轮转角 δ f \delta_f δf(方向盘转角);

车身加速度 a a a(油门以及刹车信号);

状态量(能够完全表征系统运动状态的一组最小变量):

车辆位置 ( x , y ) (x,y) (x,y)

速度 v v v、加速度 a a a;

横摆角 ψ \psi ψ、横摆角速度 ψ ˙ \dot{\psi} ψ˙

根据不同的建模需求,可以选择不同的状态量。

在这里插入图片描述

如图所示,首先需要找到车辆此时的瞬时转动中心 O O O,根据几何关系,可以列写方程如下:
{ sin ⁡ ( δ f − β ) l f = sin ⁡ ( π 2 − δ f ) R sin ⁡ ( β − δ r ) l r = sin ⁡ ( π 2 + δ r ) R \begin{cases} \frac{\sin(\delta_f-\beta)}{l_f}=\frac{\sin(\frac{\pi}{2}-\delta_f)}{R}\\ \frac{\sin(\beta-\delta_r)}{l_r}=\frac{\sin(\frac{\pi}{2}+\delta_r)}{R} \end{cases} {lfsin(δfβ)=Rsin(2πδf)lrsin(βδr)=Rsin(2π+δr)

将上式展开,得:
{ sin ⁡ ( δ f ) cos ⁡ ( β ) − sin ⁡ ( β ) cos ⁡ ( δ f ) l f = cos ⁡ ( δ f ) R cos ⁡ ( δ r ) sin ⁡ ( β ) − cos ⁡ ( β ) sin ⁡ ( δ r ) l r = cos ⁡ ( δ r ) R \begin{cases} \frac{\sin(\delta_f)\cos(\beta)-\sin(\beta)\cos(\delta_f)}{l_f}=\frac{\cos(\delta_f)}{R}\\ \frac{\cos(\delta_r)\sin(\beta)-\cos(\beta)\sin(\delta_r)}{l_r}=\frac{\cos(\delta_r)}{R} \end{cases} {lfsin(δf)cos(β)sin(β)cos(δf)=Rcos(δf)lrcos(δr)sin(β)cos(β)sin(δr)=Rcos(δr)
继续化简,得:
{ tan ⁡ ( δ f ) cos ⁡ ( β ) − sin ⁡ ( β ) = l f R sin ⁡ ( β ) − tan ⁡ ( δ r ) cos ⁡ ( β ) = l r R \begin{cases} \tan(\delta_f)\cos(\beta)-\sin(\beta)=\frac{l_f}{R}\\ \sin(\beta)-\tan(\delta_r)\cos(\beta)=\frac{l_r}{R} \end{cases} {tan(δf)cos(β)sin(β)=Rlfsin(β)tan(δr)cos(β)=Rlr

将方程组中两式相加,得:
( tan ⁡ ( δ f ) − t a n ( δ r ) ) cos ⁡ ( β ) = l f + l r R (\tan(\delta_f)-tan(\delta_r))\cos(\beta)=\frac{l_f+l_r}{R} (tan(δf)tan(δr))cos(β)=Rlf+lr
在低速情况下,可以认为车辆横摆角速度 ψ ˙ \dot{\psi} ψ˙等于车辆质心角速度,即:
ψ ˙ ≈ r = V R = V ⋅ 1 R = V ( tan ⁡ ( δ f ) − tan ⁡ ( δ r ) ) cos ⁡ ( β ) l f + l r = V cos ⁡ ( β ) l f + l r ( tan ⁡ ( δ f ) − t a n ( δ r ) ) \begin{aligned} \dot{\psi}\approx r=\frac{V}{R}=V\cdot \frac{1}{R}&=V\frac{(\tan(\delta_f)-\tan(\delta_r))\cos(\beta)}{l_f+l_r}\\ &=\frac{V\cos(\beta)}{l_f+l_r}(\tan(\delta_f)-tan(\delta_r)) \end{aligned} ψ˙r=RV=VR1=Vlf+lr(tan(δf)tan(δr))cos(β)=lf+lrVcos(β)(tan(δf)tan(δr))
同样,由
{ tan ⁡ ( δ f ) cos ⁡ ( β ) − sin ⁡ ( β ) = l f R sin ⁡ ( β ) − tan ⁡ ( δ r ) cos ⁡ ( β ) = l r R \begin{cases}\tan(\delta_f)\cos(\beta)-\sin(\beta)=\frac{l_f}{R}\\\sin(\beta)-\tan(\delta_r)\cos(\beta)=\frac{l_r}{R}\end{cases} {tan(δf)cos(β)sin(β)=Rlfsin(β)tan(δr)cos(β)=Rlr
可以推出
{ l r × ( tan ⁡ ( δ f ) cos ⁡ ( β ) − sin ⁡ ( β ) ) = l f l r R l f × ( sin ⁡ ( β ) − tan ⁡ ( δ r ) cos ⁡ ( β ) ) = l f l r R \begin{cases} l_r\times(\tan(\delta_f)\cos(\beta)-\sin(\beta))=\frac{l_fl_r}{R}\\ l_f\times(\sin(\beta)-\tan(\delta_r)\cos(\beta))=\frac{l_fl_r}{R} \end{cases} {lr×(tan(δf)cos(β)sin(β))=Rlflrlf×(sin(β)tan(δr)cos(β))=Rlflr
则质心侧偏角 β \beta β的表达式为
β = tan ⁡ − 1 ( l f tan ⁡ δ r + l r tan ⁡ δ f l f + l r ) \beta=\tan^{-1}(\frac{l_f\tan\delta_r+l_r\tan\delta_f}{l_f+l_r}) β=tan1(lf+lrlftanδr+lrtanδf)
综上,即得到以质心为参考点的车辆运动学模型
{ X ˙ = V cos ⁡ ( ψ + β ) Y ˙ = V sin ⁡ ( ψ + β ) ψ ˙ = V cos ⁡ ( β ) l f + l r ( tan ⁡ ( δ f ) − t a n ( δ r ) ) β = tan ⁡ − 1 ( l f tan ⁡ δ r + l r tan ⁡ δ f l f + l r ) \begin{cases} \dot{X}=V\cos(\psi+\beta)\\ \dot{Y}=V\sin(\psi+\beta)\\ \dot{\psi}=\frac{V\cos(\beta)}{l_f+l_r}(\tan(\delta_f)-tan(\delta_r))\\ \beta=\tan^{-1}(\frac{l_f\tan\delta_r+l_r\tan\delta_f}{l_f+l_r}) \end{cases} X˙=Vcos(ψ+β)Y˙=Vsin(ψ+β)ψ˙=lf+lrVcos(β)(tan(δf)tan(δr))β=tan1(lf+lrlftanδr+lrtanδf)

1.2、阿克曼转向几何

阿克曼转向几何(Ackermann steering geometry)是一种为了解决交通工具转弯时,内外转向轮路径指向的圆心不同的几何学。

依据阿克曼转向几何设计的车辆,沿着弯道转弯时,利用四连杆的相等曲柄使内侧轮的转向角比外侧轮大大约2~4度,使四个轮子路径的圆心大致上交会于后轴的延长线上瞬时转向中心,让车辆可以顺畅的转弯。

在这里插入图片描述

汽车的横摆角速度为 ψ ˙ = V cos ⁡ ( β ) l f + l r ( tan ⁡ ( δ f ) − t a n ( δ r ) ) \dot{\psi}=\frac{V\cos(\beta)}{l_f+l_r}(\tan(\delta_f)-tan(\delta_r)) ψ˙=lf+lrVcos(β)(tan(δf)tan(δr))

假设后轮转角 δ r \delta_r δr为0;前轮转角很小,则 tan ⁡ ( δ f ) \tan(\delta_f) tan(δf)近似等于 δ f \delta_f δf;质心侧偏角 β \beta β很小,则 cos ⁡ ( β ) \cos(\beta) cos(β)近似等于1;车辆轴距 L = l f + l r L=l_f+l_r L=lf+lr

则横摆角速度 ψ ˙ = V R = V δ L \dot{\psi}=\frac{V}{R}=V\frac{\delta}{L} ψ˙=RV=VLδ

由此可以得到左右两轮平均转角表达式 δ a v e = L R \delta_{ave}=\frac{L}{R} δave=RL

也可以近似得到外侧车轮与内侧车轮转向角表达式(假设转向半径 R R R远远大于轮距 l w l_w lw):

外侧车轮转向角 δ o = L R + l w / 2 \delta_o=\frac{L}{R+l_w/2} δo=R+lw/2L

内侧车轮转向角 δ i = L R − l w / 2 \delta_i=\frac{L}{R-l_w/2} δi=Rlw/2L

内外侧转向角的差值 δ i − δ o = L l w R 2 − l w 2 / 4 \delta_i-\delta_o=\frac{Ll_w}{R^2-l_w^2/4} δiδo=R2lw2/4Llw

同样的,由于转向半径 R R R远远大于轮距 l w l_w lw,可以把 l w 2 / 4 l_w^2/4 lw2/4项忽略;

δ i − δ o ≈ L ⋅ l w R 2 = δ 2 l w L \delta_i-\delta_o\approx\frac{L\cdot l_w}{R^2}=\delta^2\frac{l_w}{L} δiδoR2Llw=δ2Llw

由此可以看出,在相同情况下,转角越大,内外侧车轮转角差值越大,这就是阿克曼转向几何。

2、纯追踪法

2.1、算法原理

纯跟踪算法(Pure Pursuit)是一种传统且经典的车辆横向运动控制算法,其基本思想是在每个控制周期,通过前方目标轨迹上的一个点,指导当前方向盘的动作,使车辆车产生向目标点的运动。

在这里插入图片描述

纯追踪算法基于自行车模型和阿克曼转向几何。如图所示, 假设前轮转角为 δ \delta δ,后轮划过的半径为 R R R,车辆轴距为 L L L,则有 tan ⁡ δ = L R \tan \delta=\frac{L}{R} tanδ=RL,该式能在车速较低的场景下对车辆的运动情况作简单的估计。

从自行车模型出发,纯跟踪算法以车后轴为切点, 车辆纵向车身为切线, 通过控制前轮转角 , 使车辆可以沿着一条经过目标路点的圆弧行驶,如下图所示:

在这里插入图片描述

根据三角形正弦定理,可知

l d sin ⁡ ( 2 α ) = R sin ⁡ ( π 2 − α ) ⇒ l d 2 sin ⁡ ( α ) cos ⁡ ( α ) = R cos ⁡ ( α ) ⇒ l d sin ⁡ ( α ) = 2 R \frac{l_d}{\sin(2\alpha)}=\frac{R}{\sin(\frac{\pi}{2}-\alpha)}\Rightarrow \frac{l_d}{2\sin(\alpha)\cos(\alpha)}=\frac{R}{\cos(\alpha)}\Rightarrow \frac{l_d}{\sin(\alpha)}=2R sin(2α)ld=sin(2πα)R2sin(α)cos(α)ld=cos(α)Rsin(α)ld=2R

由上述两式可以推出 δ ( t ) = tan ⁡ − 1 ( 2 L sin ⁡ ( α ( t ) ) l d ) \delta(t)=\tan^{-1}(\frac{2L\sin(\alpha(t))}{l_d}) δ(t)=tan1(ld2Lsin(α(t)))

在等腰三角形中,又有 sin ⁡ ( α ) = e l d l d \sin(\alpha)=\frac{e_{ld}}{l_d} sin(α)=ldeld e l d e_{ld} eld为横向误差)

继续代入,可以推出 δ ( t ) = tan ⁡ − 1 ( 2 L l d 2 e l d ( t ) ) \delta(t)=\tan^{-1}(\frac{2L}{l_d^2}e_{ld}(t)) δ(t)=tan1(ld22Leld(t))

由此,就得到了前轮转角 δ \delta δ与前视横向误差 e l d e_{ld} eld、轴距 L L L、前视距离 l d l_d ld之间的关系。

2.2、实现步骤

(1)确定车辆当前的位置(定位模块);

(2)找到规划路径上距离当前车辆最近的点 ( g x m i n , g y m i n ) (g_{xmin},g_{ymin}) (gxmin,gymin)(为下一步作准备);

(3)找到目标点 ( g x , g y ) (g_x,g_y) (gx,gy);首先定义好前视距离 l d l_d ld,以汽车后轮接地点为中心,以前视距离 l d l_d ld为半径画圆,圆弧将会与规划路径交于一点或者多点,则与(2)中定义的最近点 ( g x m i n , g y m i n ) (g_{xmin},g_{ymin}) (gxmin,gymin)距离最近的点即为目标点;

(4)将目标点转换到车辆坐标系下;

(5)利用纯跟踪算法的公式计算出到达目标点所需要的转角,并控制车辆进行转向;

(6)更新车辆实时状态;

可以看到,纯追踪算法的核心在于前视距离 l d l_d ld的选取,前视距离过小会使车辆行驶路径产生振荡,而过大则会导致车辆过弯时拐小弯。

一种比较常见的前视距离的选择方法是将其与速度相关联,令 l d l_d ld是速度的一次函数,即 l d = k v x l_d=kv_x ld=kvx,使用这种方法可以使控制适应速度的变化。

3、Stanley 法

3.1、算法原理

Stanley法又称为前轮反馈控制法(Front wheel feedback),核心在于基于前轮中心的路径跟踪偏差量对方向盘转向控制量进行计算。

在这里插入图片描述

前轮转角 δ \delta δ由需要考量三个条件:

(1)由航向误差引起的转角 δ e \delta_e δe,即当前车身方向与参考轨迹最近的点的切线方向的夹角;

(2)由横向误差 e e e引起的转角 δ y \delta_y δy,在不考虑航向误差时,横向误差越大,前轮转角应该越大。设在轨迹切线方向前 d ( t ) d(t) d(t)处轨迹切线与前轮方向线橡胶,根据几何关系,可以得到 δ y = tan ⁡ − 1 e d ( t ) = tan ⁡ − 1 k e v ( t ) \delta_y=\tan^{-1}\frac{e}{d(t)}=\tan^{-1}\frac{ke}{v(t)} δy=tan1d(t)e=tan1v(t)ke,式中, d ( t ) d(t) d(t)与车速相关,即 d ( t ) = v ( t ) k d(t)=\frac{v(t)}{k} d(t)=kv(t) k k k为比例系数,可以根据实验来调整;

(3)前轮转角有最大值 δ m a x \delta_{max} δmax和最小值 δ m i n \delta_{min} δmin,通常 δ m a x \delta_{max} δmax δ m i n \delta_{min} δmin是一对相反数;

综上,可以得到前轮转角的表达式:

δ ( t ) = δ e ( t ) + tan ⁡ − 1 ( k e ( t ) v ( t ) ) , δ ( t ) ∈ [ δ m i n , δ m a x ] \delta(t)=\delta_e(t)+\tan^-1(\frac{ke(t)}{v(t)}), \delta(t)\in[\delta_{min},\delta_{max}] δ(t)=δe(t)+tan1(v(t)ke(t)),δ(t)[δmin,δmax]

3.2、稳定性分析

使用线性自行车运动模型,可以得到横向误差的变化率为 e ˙ ( t ) = − v ( t ) sin ⁡ δ e ( t ) \dot{e}(t)=-v(t)\sin\delta_e(t) e˙(t)=v(t)sinδe(t);

根据几何关系,得 s i n δ e ( t ) = e ( t ) d ( t ) 2 + e ( t ) 2 = k e ( t ) v ( t ) 2 + ( k e ( t ) ) 2 sin\delta_e(t)=\frac{e(t)}{\sqrt{d(t)^2+e(t)^2}}=\frac{ke(t)}{\sqrt{v(t)^2+(ke(t))^2}} sinδe(t)=d(t)2+e(t)2 e(t)=v(t)2+(ke(t))2 ke(t)

因此, x ˙ ( t ) = − v ( t ) k e ( t ) v ( t 2 ) + ( k e ( t ) ) 2 = − k e ( t ) 1 + ( k e ( t ) v ( t ) ) 2 \dot{x}(t)=\frac{-v(t)ke(t)}{\sqrt{v(t^2)+(ke(t))^2}}=\frac{-ke(t)}{\sqrt{1+(\frac{ke(t)}{v(t)})^2}} x˙(t)=v(t2)+(ke(t))2 v(t)ke(t)=1+(v(t)ke(t))2 ke(t)

假设横向误差 e ( t ) e(t) e(t)很小,则分子项约等于1,则 e ˙ ≈ − k e ( t ) \dot{e}\approx-ke(t) e˙ke(t)

积分上式,得 e ( t ) = e ( 0 ) × e x p − k t e(t)=e(0)\times exp^{-kt} e(t)=e(0)×expkt,因此横向误差指数收敛于 e ( t ) = 0 e(t)=0 e(t)=0,参数 k k k决定了收敛速度,对于任意横向误差,微分方程都单调的收敛到0。

  • 3
    点赞
  • 15
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
摘要: 本文提出了一种基于RBF神经网络滑模控制车辆横向控制方法。首先,建立了车辆动力学模型和横向运动方程,然后利用RBF神经网络对车辆横向运动进行建模,得到了车辆横向运动的非线性函数关系。接着,采用滑模控制技术进行车辆横向控制,通过引入一个滑模面,将车辆横向控制问题转化为滑模面上的控制问题,并设计了控制律使车辆横向运动能够在滑模面上稳定运动。最后,利用Matlab/Simulink仿真验证了该方法的有效性和可行性。 关键词:RBF神经网络;滑模控制车辆横向控制;仿真 Abstract: This paper proposes a vehicle lateral control method based on RBF neural network sliding mode control. Firstly, the vehicle dynamic model and lateral motion equation are established, and then the RBF neural network is used to model the lateral motion of the vehicle, and the nonlinear function relationship of the lateral motion of the vehicle is obtained. Then, the sliding mode control technology is used to control the lateral motion of the vehicle. By introducing a sliding mode surface, the lateral control problem of the vehicle is transformed into a control problem on the sliding mode surface, and a control law is designed to make the lateral motion of the vehicle stable on the sliding mode surface. Finally, the effectiveness and feasibility of the method are verified by Matlab/Simulink simulation. Keywords: RBF neural network; sliding mode control; vehicle lateral control; simulation

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值