Files
modeling-app/docs/kcl/cos.md
Paul Tagliamonte e1c45bdb33 Start to rework some of our kcl docs (#3222)
* Start to rework some of our kcl docs

Signed-off-by: Paul R. Tagliamonte <paul@zoo.dev>
2024-08-06 20:27:26 -04:00

170 KiB

title, excerpt, layout
title excerpt layout
cos Compute the cosine of a number (in radians). manual

Compute the cosine of a number (in radians).

cos(num: number) -> number

Tags

  • math

Examples

const exampleSketch = startSketchOn("XZ")
  |> startProfileAt([0, 0], %)
  |> angledLine({
       angle: 30,
       length: 3 / cos(toRadians(30))
     }, %)
  |> yLineTo(0, %)
  |> close(%)

const example = extrude(5, exampleSketch)

Rendered example of cos 0

Arguments

  • num: number (REQUIRED)

Returns

number