Introduction

SmoothCurves.jl

Create parameterized smooth curves, e.g. usable for mobile robot path following.

This library provides a few elementary curve types,

Clothoid
LineSegment
ArcSegment

and the possibility to chain them together as PolyCurve. All curves implement the Curve interface:

smax
point
startpoint
endpoint
dpoint
length
dlength
curvature
dcurvature
tangentangle
radialangle

Additionally, Construction methods which generate smooth curves from given polygon paths are provided.

using SmoothCurves

# Define Polygon points
points = [
    [0, 0],
    [4, 0],
    [2, 2],
    [7, 3],
    [8, 1],
    [6, -2]
]

dmax = 0.5
C = construction.curve(dmax, points)

Besides the $x(s), y(s)$ coordinates, many other quantities are available.

svec = [0:0.01:smax(C);]
ϕ = tangentangle.(C, svec)
θ = radialangle.(C, svec)
κ = curvature.(C, svec)
dκ = dcurvature.(C, svec)
0 5 10 15 -2 -1 0 1 2 s tangentangle 0 5 10 15 -3 -2 -1 0 1 2 3 s radialangle 0 5 10 15 -2 0 2 4 s curvature 0 5 10 15 -6 -3 0 3 6 s dcurvature