1 | module math |
2 | |
3 | fn JS.Math.acos(x f64) f64 |
4 | |
5 | fn JS.Math.asin(x f64) f64 |
6 | |
7 | fn JS.Math.atan(x f64) f64 |
8 | |
9 | fn JS.Math.atan2(y f64, x f64) f64 |
10 | |
11 | // acos calculates inverse cosine (arccosine). |
12 | [inline] |
13 | pub fn acos(a f64) f64 { |
14 | return JS.Math.acos(a) |
15 | } |
16 | |
17 | // asin calculates inverse sine (arcsine). |
18 | [inline] |
19 | pub fn asin(a f64) f64 { |
20 | return JS.Math.asin(a) |
21 | } |
22 | |
23 | // atan calculates inverse tangent (arctangent). |
24 | [inline] |
25 | pub fn atan(a f64) f64 { |
26 | return JS.Math.atan(a) |
27 | } |
28 | |
29 | // atan2 calculates inverse tangent with two arguments, returns the angle between the X axis and the point. |
30 | [inline] |
31 | pub fn atan2(a f64, b f64) f64 { |
32 | return JS.Math.atan2(a, b) |
33 | } |