Add a parabolic segment to an existing sketch.
parabolic(
@sketch: Sketch,
end: Point2d,
endAbsolute?: Point2d,
coefficients?: [number; 3],
interior?: Point2d,
interiorAbsolute?: Point2d,
tag?: tag,
): Sketch
Arguments
Name | Type | Description | Required |
---|---|---|---|
sketch | Sketch | Which sketch should this path be added to? | Yes |
end | Point2d | Where should the path end? Relative to the start point. Incompatible with interiorAbsolute or endAbsolute . | Yes |
endAbsolute | Point2d | Where should this segment end? Requires interiorAbsolute . Incompatible with interior or end . | No |
coefficients | [number; 3] | The coefficients [a, b, c] of the parabolic equation y = ax^2 + bx + c. Incompatible with interior . | No |
interior | Point2d | A point between the segment's start and end that lies on the parabola. Incompatible with coefficients or interiorAbsolute or endAbsolute . | No |
interiorAbsolute | Point2d | Any point between the segment's start and end. Requires endAbsolute . Incompatible with coefficients or interior or end . | No |
tag | tag | Create a new tag which refers to this segment. | No |
Returns
Sketch
- A sketch is a collection of paths.
Examples
exampleSketch = startSketchOn(XY)
|> startProfile(at = [0, 0])
|> parabolic(end = [10, 0], coefficients = [2, 0, 0])
|> close()