Similar Posts

Subscribe
Notify of
3 Answers
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
PWolff
10 months ago

The trigonometric functions usually take angles in the “bogen dimension” (“radant”). (angle in arc size = distance divided by radius)

1 full circle = 2 Pi radiant = 360°

You can also convert degrees to Radiant.

—-

If you cannot use the built-in functions:

cos(x) = 1 – x^2 / (1 * 2) + x^4 / (1 * 2 * 3 * 4) – x^6 / (1 * 2 * 3 * 4 * 5 * 6) +- …

This series converges pretty fast.

(x in sheet size)

tunik123
10 months ago

In C you would write cos(x*pi/180) with pi = 3.1415926 (usw).

Or are you looking for a function that only calculates the cosine with basic calculations? It’ll be a bit more difficult.