主要内容

路径更光滑的样条

使用立方样条插值平稳的车辆路径

  • Library:
  • Automated Driving Toolbox

  • 路径更光滑的样条block

描述

The路径更光滑的样条block generates a smooth vehicle path, consisting of a sequence of discretized poses, by fitting the input reference path poses to a cubic spline. Given the input reference path directions, the block also returns the directions that correspond to each pose.

Use this block to convert a C1-continuous path to a C2- 连续路径。C1- 连续路径包括路径计划者返回的Dubins或Reeds-Shepp路径。有关这些路径类型的更多详细信息,请参见C1-Continuous and C2-Continuous Paths

您可以使用the returned poses and directions with a vehicle controller, such as the横向控制器斯坦利block.

端口

输入

expand all

Reference poses of the vehicle along the path, specified as anM-by-3 matrix of [x,y,θ]向量, whereM是姿势的数量。

xyspecify the location of the vehicle in meters.θspecifies the orientation angle of the vehicle in degrees.

Data Types:single|双倍的

车辆沿着路径的参考指示,指定为M-1列矢量为1S(正向运动)和–1(反向运动)。M是参考方向的数量。每个元素避难所对应于RefPoses输入端口。

Data Types:single|双倍的

Output

expand all

Discretized poses of the smoothed path, returned as anN-by-3 matrix of [x,y,θ]向量。Nis the number of poses specified in the数量的输出poses范围。

xyspecify the location of the vehicle in meters.θspecifies the orientation angle of the vehicle in degrees.

值中的值姿势are of the same data type as the values in theRefPoses输入端口。

每个输出姿势的车辆行驶指示姿势,作为一个N-1列矢量为1S(正向运动)和–1(反向运动)。Nis the number of poses specified in the数量的输出poses范围。

值中的值Directionsare of the same data type as the values in the避难所输入端口。

您可以使用Directions指定车辆的参考路径。您也可以使用Directions,连同暨长度曲率,为车辆生成参考速度轮廓。看到速度剖面块和Simulink的自动停车代客万博1manbetx例子。

每个输出姿势的累积路径长度姿势,作为一个N-1 by-1实值列向量。Nis the number of poses specified in the数量的输出poses范围。单位为米。

您可以使用暨长度,连同Directions曲率,为车辆生成参考速度轮廓。看到速度剖面块和Simulink的自动停车代客万博1manbetx例子。

Dependencies

To enable this port, select the显示暨长度和曲率输出端口范围。

Signed path curvatures at each output pose in姿势,作为一个N-1 by-1实值列向量。Nis the number of poses specified in the数量的输出poses范围。Units are in radians per meter.

您可以使用曲率,连同Directions暨长度,为车辆生成参考速度轮廓。看到速度剖面块和Simulink的自动停车代客万博1manbetx例子。

Dependencies

To enable this port, select the显示暨长度和曲率输出端口范围。

Parameters

expand all

光滑的姿势数量要在姿势output port, specified as a positive integer. To increase the granularity of the returned poses, increase this parameter value.

姿势之间的最小分离,以米为单位,指定为正真实标量。如果欧几里得x,y)两个姿势之间的距离小于此值,然后块仅使用以下姿势之一进行插值。

块的示例时间(以秒为单位)指定为-1or as a positive real scalar. The default of-1means that the block inherits its sample time from upstream blocks.

Select this parameter to enable the暨长度曲率output ports.

  • 代码生成- 使用生成的C/C ++代码模拟模型。您第一次运行模拟,Simulink万博1manbetx®为该块生成C/C ++代码。只要模型不更改,就可以重复使用C代码以进行后续模拟。此选项需要额外的启动时间。

  • 解释执行— Simulate the model using the MATLAB®interpreter. This option shortens startup time. In解释执行模式,您可以调试块的源代码。

More About

expand all

算法

  • The path-smoothing algorithm interpolates a parametric cubic spline that passes through all input reference pose points. The parameter of the spline is the cumulative chord length at these points.[1]

  • The tangent direction of the smoothed output path approximately matches the orientation angle of the vehicle at the starting and goal poses.

参考

[1]Floater, Michael S. "On the Deviation of a Parametric Cubic Spline Interpolant from Its Data Polygon."计算机辅助几何设计。卷。25,第3期,2008年,第148-156页。

[2] Lepetic, Marko, Gregor Klancar, Igor Skrjanc, Drago Matko, and Bostjan Potocnik. "Time Optimal Path Planning Considering Acceleration Limits."机器人技术和自主系统。卷。45, Numbers 3–4, 2003, pp. 199–210.

Extended Capabilities

C/C ++代码生成
Generate C and C++ code using Simulink® Coder™.

Version History

Introduced in R2019a