sincosd

Compute the sine and cosine of x expressed in degrees.

Base.Math.sincosdFunction
sincosd(x)

Simultaneously compute the sine and cosine of x, where x is in degrees.

Julia 1.3

This function requires at least Julia 1.3.

source

Methods

julia> methods(sincosd, (Any,), [Base, Base.Math, Base.MathConstants, Base.MPFR])# 2 methods for generic function "sincosd" from Base.Math:
 [1] sincosd(::Missing)
     @ special/trig.jl:1254
 [2] sincosd(x)
     @ special/trig.jl:1250

Examples

Real Numbers

julia> sincosd(0)
(0.0, 1.0)

julia> sincosd(-0.0)
(-0.0, 1.0)

julia> sincosd(45)
(0.7071067811865476, 0.7071067811865476)

julia> sincosd(90)
(1.0, 0.0)

julia> sincosd(180)
(0.0, -1.0)

Complex

julia> sincosd(0+0im)
(0.0 + 0.0im, 1.0 - 0.0im)

Tips

See Also

Extended Inputs

Tech Notes

  • sincosd(::Real): by pure julia
  • sincosd(::BigFloat): by MPFR

Version History

Introduced in Julia v1.3 (2019)