From 5d3ad39df8d16569a89a5e6bf62b48a5628b46be Mon Sep 17 00:00:00 2001 From: Jeffrey Sarnoff Date: Tue, 1 Feb 2022 22:59:37 -0500 Subject: [PATCH] more trig in float.jl (#37) * Update float.jl * more trig functions --- src/float.jl | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/src/float.jl b/src/float.jl index 17df3e5..a2d022c 100644 --- a/src/float.jl +++ b/src/float.jl @@ -117,12 +117,19 @@ Base.inv(x::StaticFloat64{N}) where {N} = fdiv(one(x), x) static(exponent(M)) end -for f in (:sin, :cos, :tan, :asin, :atan, :acos, - :sinh, :cosh, :tanh, :asinh, :acosh, :atanh, - :exp, :exp2, :exp10, :expm1, :log, :log2, :log10, :log1p, - :cbrt) +for f in (:rad2deg, :deg2rad, :cbrt, + :mod2pi, :rem2pi, :sinpi, :cospi, + :exp, :exp2, :exp10, :expm1, + :log, :log2, :log10, :log1p, + :sin, :cos, :tan, :sec, :csc, :cot, + :asin, :acos, :atan, :asec, :acsc, :acot, + :sind, :cosd, :tand, :secd, :cscd, :cotd, + :asind, :acosd, :atand, :asecd, :acscd, :acotd, + :sinh, :cosh, :tanh, :sech, :csch, :coth, + :asinh, :acosh, :atanh, :asech, :acsch, :acoth, + ) @eval @generated function (Base.$f)(::StaticFloat64{M}) where {M} Expr(:call, Expr(:curly, :StaticFloat64, $f(M))) end -end \ No newline at end of file +end