public final class Clothoid extends Object
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright (c) 2013-2018 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
Modifier and Type | Method and Description |
---|---|
static OTSLine3D |
clothoid(OTSPoint3D start,
Direction startDirection,
double startCurvature,
double endCurvature,
Length length,
Length endElevation,
int numSegments)
Approximate a clothoid.
|
static OTSLine3D |
clothoid(OTSPoint3D start,
Direction startDirection,
double endCurvature,
Length length,
Length endElevation,
int numSegments)
Approximate a clothoid with curvature 0 at start.
|
static OTSLine3D |
clothoid(OTSPoint3D start,
Direction startDirection,
LinearDensity endCurvature,
Length length,
Length endElevation,
int numSegments)
Approximate a clothoid with curvature 0 at start.
|
static OTSLine3D |
clothoid(OTSPoint3D start,
Direction startDirection,
LinearDensity startCurvature,
LinearDensity endCurvature,
Length length,
Length endElevation,
int numSegments)
Approximate a clothoid.
|
static void |
main(String[] args)
Demonstrate / test the clothoid methods.
|
public static OTSLine3D clothoid(OTSPoint3D start, Direction startDirection, double endCurvature, Length length, Length endElevation, int numSegments) throws OTSGeometryException
start
- OTSPoint3D; starting point of the clothoidstartDirection
- Direction; start direction of the clothoidendCurvature
- double; curvature at the end of the clothoid [1/m]length
- Length; length of the clothoidendElevation
- Length; elevation at end of the clothoidnumSegments
- int; number of segments used to approximate (the number of points is one higher than this)OTSGeometryException
- if the number of segments is too lowpublic static OTSLine3D clothoid(OTSPoint3D start, Direction startDirection, double startCurvature, double endCurvature, Length length, Length endElevation, int numSegments) throws OTSGeometryException
start
- OTSPoint3D; starting point of the clothoidstartDirection
- Direction; start direction of the clothoidstartCurvature
- double; curvature at the start of the clothoid [1/m]endCurvature
- double; curvature at the end of the clothoid [1/m]length
- Length; length of the clothoidendElevation
- Length; elevation at end of the clothoidnumSegments
- int; number of segments used to approximate (the number of points is one higher than this)OTSGeometryException
- if the number of segments is too lowpublic static OTSLine3D clothoid(OTSPoint3D start, Direction startDirection, LinearDensity endCurvature, Length length, Length endElevation, int numSegments) throws OTSGeometryException
start
- OTSPoint3D; starting point of the clothoidstartDirection
- Direction; start direction of the clothoidendCurvature
- LinearDensity; curvature at the end of the clothoidlength
- Length; length of the clothoidendElevation
- Length; elevation at end of the clothoidnumSegments
- int; number of segments used to approximate (the number of points is one higher than this)OTSGeometryException
- if the number of segments is too lowpublic static OTSLine3D clothoid(OTSPoint3D start, Direction startDirection, LinearDensity startCurvature, LinearDensity endCurvature, Length length, Length endElevation, int numSegments) throws OTSGeometryException
start
- OTSPoint3D; starting point of the clothoidstartDirection
- Direction; start direction of the clothoidstartCurvature
- double; curvature at the start of the clothoid [1/m]endCurvature
- double; curvature at the end of the clothoid [1/m]length
- Length; length of the clothoidendElevation
- Length; elevation at end of the clothoidnumSegments
- int; number of segments used to approximate (the number of points is one higher than this)OTSGeometryException
- if the number of segments is too lowpublic static void main(String[] args) throws OTSGeometryException
args
- String[]; the command line arguments (not used)OTSGeometryException
- if the number of segments is too lowCopyright © 2014–2018 Delft University of Technology. All rights reserved.