@ -80,7 +80,7 @@ fn decagon(@radius) {
|
||||
|
||||
// Start the decagon sketch at this point.
|
||||
startOfDecagonSketch = startSketchOn(XY)
|
||||
|> startProfile(at = [(cos(0)*radius), (sin(0) * radius)])
|
||||
|> startProfile(at = [(cos(0deg)*radius), (sin(0deg) * radius)])
|
||||
|
||||
// Use a `reduce` to draw the remaining decagon sides.
|
||||
// For each number in the array 1..10, run the given function,
|
||||
|
@ -89,7 +89,7 @@ sketch001 = startSketchOn(XY)
|
||||
|
||||
sketch002 = clone(sketch001)
|
||||
|> translate(x = 0, y = 0, z = 20)
|
||||
|> rotate(axis = [0, 0, 1.0], angle = 45)
|
||||
|> rotate(axis = [0, 0, 1.0], angle = 45deg)
|
||||
|
||||
loft([sketch001, sketch002])
|
||||
```
|
||||
@ -180,7 +180,7 @@ clonedMountingPlate = clone(mountingPlate)
|
||||
|
||||
// Create a helix around the Z axis.
|
||||
helixPath = helix(
|
||||
angleStart = 0,
|
||||
angleStart = 0deg,
|
||||
ccw = true,
|
||||
revolutions = 4,
|
||||
length = 10,
|
||||
@ -208,7 +208,7 @@ sketch001 = startSketchOn(XY)
|
||||
sketch002 = clone(sketch001)
|
||||
|> translate( z = 30)
|
||||
|> revolve(
|
||||
angle = 360,
|
||||
angle = 360deg,
|
||||
axis = Y,
|
||||
)
|
||||
```
|
||||
@ -230,7 +230,7 @@ exampleSketch = startSketchOn(XY)
|
||||
|> line(end = [-2, 0])
|
||||
|> close()
|
||||
|
||||
example001 = revolve(exampleSketch, axis = Y, angle = 180, tagEnd = $end01)
|
||||
example001 = revolve(exampleSketch, axis = Y, angle = 180deg, tagEnd = $end01)
|
||||
|
||||
// example002 = clone(example001)
|
||||
// |> translate(x = 0, y = 20, z = 0)
|
||||
|
@ -43,7 +43,7 @@ helix(
|
||||
```kcl
|
||||
// Create a helix around the Z axis.
|
||||
helixPath = helix(
|
||||
angleStart = 0,
|
||||
angleStart = 0deg,
|
||||
ccw = true,
|
||||
revolutions = 5,
|
||||
length = 10,
|
||||
@ -66,7 +66,7 @@ helper001 = startSketchOn(XZ)
|
||||
|> line(end = [0, 10], tag = $edge001)
|
||||
|
||||
helixPath = helix(
|
||||
angleStart = 0,
|
||||
angleStart = 0deg,
|
||||
ccw = true,
|
||||
revolutions = 5,
|
||||
length = 10,
|
||||
@ -85,7 +85,7 @@ springSketch = startSketchOn(XY)
|
||||
```kcl
|
||||
// Create a helix around a custom axis.
|
||||
helixPath = helix(
|
||||
angleStart = 0,
|
||||
angleStart = 0deg,
|
||||
ccw = true,
|
||||
revolutions = 5,
|
||||
length = 10,
|
||||
@ -112,7 +112,7 @@ part001 = startSketchOn(XY)
|
||||
|> extrude(length = 10)
|
||||
|
||||
helix(
|
||||
angleStart = 0,
|
||||
angleStart = 0deg,
|
||||
ccw = true,
|
||||
revolutions = 16,
|
||||
cylinder = part001,
|
||||
|
@ -27,7 +27,7 @@ abs(@input: number): number
|
||||
### Examples
|
||||
|
||||
```kcl
|
||||
myAngle = -120
|
||||
myAngle = -120deg
|
||||
|
||||
sketch001 = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|
@ -30,7 +30,7 @@ cos(@num: number(Angle)): number(_)
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> angledLine(
|
||||
angle = 30,
|
||||
angle = 30deg,
|
||||
length = 3 / cos(30deg),
|
||||
)
|
||||
|> yLine(endAbsolute = 0)
|
||||
|
@ -30,7 +30,7 @@ max(@input: [number; 1+]): number
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> angledLine(
|
||||
angle = 70,
|
||||
angle = 70deg,
|
||||
length = max([15, 31, 4, 13, 22])
|
||||
)
|
||||
|> line(end = [20, 0])
|
||||
|
@ -30,7 +30,7 @@ min(@input: [number; 1+]): number
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> angledLine(
|
||||
angle = 70,
|
||||
angle = 70deg,
|
||||
length = min([15, 31, 4, 13, 22])
|
||||
)
|
||||
|> line(end = [20, 0])
|
||||
|
@ -34,7 +34,7 @@ cartesian (x/y/z grid) coordinates.
|
||||
```kcl
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> line(end = polar(angle = 30, length = 5), tag = $thing)
|
||||
|> line(end = polar(angle = 30deg, length = 5), tag = $thing)
|
||||
|> line(end = [0, 5])
|
||||
|> line(end = [segEndX(thing), 0])
|
||||
|> line(end = [-20, 10])
|
||||
|
@ -34,7 +34,7 @@ pow(
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> angledLine(
|
||||
angle = 50,
|
||||
angle = 50deg,
|
||||
length = pow(5, exp = 2),
|
||||
)
|
||||
|> yLine(endAbsolute = 0)
|
||||
|
@ -30,7 +30,7 @@ sin(@num: number(Angle)): number(_)
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> angledLine(
|
||||
angle = 50,
|
||||
angle = 50deg,
|
||||
length = 15 / sin(135deg),
|
||||
)
|
||||
|> yLine(endAbsolute = 0)
|
||||
|
@ -30,7 +30,7 @@ sqrt(@input: number): number
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> angledLine(
|
||||
angle = 50,
|
||||
angle = 50deg,
|
||||
length = sqrt(2500),
|
||||
)
|
||||
|> yLine(endAbsolute = 0)
|
||||
|
@ -30,7 +30,7 @@ tan(@num: number(Angle)): number(_)
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> angledLine(
|
||||
angle = 50,
|
||||
angle = 50deg,
|
||||
length = 50 * tan((1/2): number(rad)),
|
||||
)
|
||||
|> yLine(endAbsolute = 0)
|
||||
|
File diff suppressed because one or more lines are too long
@ -30,7 +30,7 @@ units::toDegrees(@num: number(Angle)): number(deg)
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> angledLine(
|
||||
angle = 50,
|
||||
angle = 50deg,
|
||||
length = 70 * cos(units::toDegrees((PI/4): number(rad))),
|
||||
)
|
||||
|> yLine(endAbsolute = 0)
|
||||
|
@ -30,8 +30,8 @@ units::toRadians(@num: number(Angle)): number(rad)
|
||||
exampleSketch = startSketchOn(XZ)
|
||||
|> startProfile(at = [0, 0])
|
||||
|> angledLine(
|
||||
angle = 50,
|
||||
length = 70 * cos(units::toRadians(45)),
|
||||
angle = 50deg,
|
||||
length = 70 * cos(units::toRadians(45deg)),
|
||||
)
|
||||
|> yLine(endAbsolute = 0)
|
||||
|> close()
|
||||
|
Reference in New Issue
Block a user