mixed_num/float_impl/
f64_impl.rs

1use super::*;
2
3impl MixedSin for f64
4{
5    #[inline(always)]
6    fn mixed_sin(&self) -> Self {
7        return libm::sin(*self);
8    }
9    #[inline(always)]
10    fn mixed_sincos(&self) -> (Self, Self) 
11        where Self: Sized
12    {
13        return libm::sincos(*self);
14    }   
15    #[inline(always)]
16    fn mixed_asin(&self) -> Self {
17        return libm::asin(*self);
18    }
19}
20
21impl MixedSinh for f64
22{
23    #[inline(always)]
24    fn mixed_sinh(&self) -> Self {
25        return libm::sinh(*self);
26    }
27    #[inline(always)]
28    fn mixed_asinh(&self) -> Self {
29        return libm::asinh(*self);
30    }
31}
32
33impl MixedCos for f64
34{
35    #[inline(always)]
36    fn mixed_cos(&self) -> Self {
37        return libm::cos(*self);
38    }
39    #[inline(always)]
40    fn mixed_acos(&self) -> Self {
41        return libm::acos(*self);
42    }
43}
44
45impl MixedCosh for f64
46{
47    #[inline(always)]
48    fn mixed_cosh(&self) -> Self {
49        return libm::cosh(*self);
50    }
51    #[inline(always)]
52    fn mixed_acosh(&self) -> Self {
53        return libm::acosh(*self);
54    }
55}
56
57impl MixedTrigonometry for f64
58{ 
59}
60
61impl MixedTan for f64
62{
63    #[inline(always)]
64    fn mixed_tan(&self) -> Self {
65        return libm::tan(*self);
66    }
67}
68
69impl MixedTanh for f64
70{
71    #[inline(always)]
72    fn mixed_tanh(&self) -> Self {
73        return libm::tanh(*self);
74    }
75    #[inline(always)]
76    fn mixed_atanh(&self) -> Self {
77        return libm::atanh(*self);
78    }
79}
80
81impl MixedCbrt for f64
82{
83    #[inline(always)]
84    fn mixed_cbrt(&self) -> Self {
85        return libm::cbrt(*self);
86    }
87}
88
89impl MixedAtan for f64
90{
91    #[inline(always)]
92    fn mixed_atan(&self) -> Self {
93        return libm::atan(*self);
94    }
95    #[inline(always)]
96    fn mixed_atan2(&self, other:Self) -> Self {
97        return libm::atan2(*self,other);
98    }
99    #[inline(always)]
100    fn mixed_atan2_poly(&self, other:Self) -> Self {
101        return trigonometry::atan::atan2(*self, other);
102    }
103}
104
105impl MixedSqrt for f64
106{
107    #[inline(always)]
108    fn mixed_sqrt(&self) -> Self {
109        return libm::sqrt(*self);
110    }
111
112    #[inline(always)]
113    fn mixed_niirf(&self) -> Self {
114        return trigonometry::sqrt::niirf(*self, 2);
115    }
116}
117
118impl MixedCeil for f64
119{
120    #[inline(always)]
121    fn mixed_ceil(&self) -> Self {
122        return libm::ceil(*self);
123    }
124}
125impl MixedFloor for f64
126{
127    #[inline(always)]
128    fn mixed_floor(&self) -> Self {
129        return libm::floor(*self);
130    }
131}
132
133impl MixedExp for f64
134{
135    #[inline(always)]
136    fn mixed_exp(&self) -> Self {
137        return libm::exp(*self);
138    }
139}
140impl MixedExp10 for f64
141{
142    #[inline(always)]
143    fn mixed_exp10(&self) -> Self {
144        return libm::exp10(*self);
145    }
146}
147
148impl MixedExp2 for f64
149{
150    #[inline(always)]
151    fn mixed_exp2(&self) -> Self {
152        return libm::exp2(*self);
153    }
154}
155
156impl MixedPow for f64
157{
158    #[inline(always)]
159    fn mixed_pow(&self, power:f64) -> Self {
160        return libm::pow(*self, power);
161    }
162}
163
164impl Mixedlog for f64
165{
166    #[inline(always)]
167    fn mixed_log(&self) -> Self {
168        return libm::log(*self);
169    }
170}
171
172impl Mixedlog10 for f64
173{
174    #[inline(always)]
175    fn mixed_log10(&self) -> Self {
176        return libm::log10(*self);
177    }
178}
179
180impl Mixedlog2 for f64
181{
182    #[inline(always)]
183    fn mixed_log2(&self) -> Self {
184        return libm::log2(*self);
185    }
186}