Files
modeling-app/docs/kcl-std/functions/std-math-sin.md
Jonathan Tran 851ea28bd3 Change trig functions to return number with Default units (#7425)
* Change trig functions to return number with Default units

* Update docs

* Update output
2025-06-11 00:24:48 +00:00

78 KiB

title, subtitle, excerpt, layout
title subtitle excerpt layout
sin Function in std::math Compute the sine of a number. manual

Compute the sine of a number.

sin(@num: number(Angle)): number

Arguments

Name Type Description Required
num number(Angle) A number. Yes

Returns

number - A number.

Examples

exampleSketch = startSketchOn(XZ)
  |> startProfile(at = [0, 0])
  |> angledLine(angle = 50, length = 15 / sin(135deg))
  |> yLine(endAbsolute = 0)
  |> close()

example = extrude(exampleSketch, length = 5)

Rendered example of sin 0