This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

robotics.DubinsPathSegment

Dubins path segment connecting two poses

Description

The DubinsPathSegment object holds information for a Dubins path segment that connects two poses as a sequence of three motions. The motion options are:

  • Straight

  • Left turn at maximum steer

  • Right turn at maximum steer

Creation

To generate a DubinsPathSegment object, use the connect function with a robotics.DubinsConnection object:

dubPathSegObj = connect(connectionObj,start,goal) connects the start and goal pose using the specified connection type object.

To specifically define a path segment:

dubPathSegObj = robotics.DubinsPathSegment(connectionObj,start,goal,motionLengths,motionTypes) specifies the Dubins connection type, the start and goal poses, and the corresponding motion lengths and types. These values are set to the corresponding properties in the object.

Properties

expand all

This property is read-only.

Minimum turning radius of the robot, specified as a positive scalar in meters. This value corresponds to the radius of the turning circle at the maximum steering angle of the robot.

Data Types: double

This property is read-only.

Initial pose of the robot at the start of the path segment, specified as an [x, y, Θ] vector. x and y are in meters. Θ is in radians.

Data Types: double

This property is read-only.

Goal pose of the robot at the end of the path segment, specified as an [x, y, Θ] vector. x and y are in meters. Θ is in radians.

Data Types: double

This property is read-only.

Length of each motion in the path segment, in world units, specified as a three-element numeric vector. Each motion length corresponds to a motion type specified in MotionTypes.

Data Types: double

This property is read-only.

Type of each motion in the path segment, specified as a three-element string cell array. Valid values are:

Motion TypeDescription
"S"Straight
"L"

Left turn at the maximum steering angle of the vehicle

"R"

Right turn at the maximum steering angle of the vehicle

Each motion type corresponds to a motion length specified in MotionLengths.

Example: {"R" "S" "R"}

Data Types: cell

This property is read-only.

Length of the path segment, specified as a positive scalar in meters. This length is just a sum of the elements in MotionLengths.

Data Types: double

Object Functions

interpolateInterpolate poses along path segment
showVisualize path segment

Examples

collapse all

Create a DubinsConnection object.

dubConnObj = robotics.DubinsConnection;

Define start and goal poses as [x y theta] vectors.

startPose = [0 0 0];
goalPose = [1 1 pi];

Calculate a valid path segment to connect the poses.

[pathSegObj, pathCosts] = connect(dubConnObj,startPose,goalPose);

Show the generated path.

show(pathSegObj{1})

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using MATLAB® Coder™.

Introduced in R2018b