MATLAB: Calculating sin and cos functions

MATLABsine and cosine functions

Hello, i calculated the value of sin(45) in Matlab, the result was sin(45)=0.8509 and for cosin i got cos(45)= 0.5253. From general mathematics we know that sin(45)=cos(45) then why Matlab is giving different results??

Best Answer

  • Those functions work in radians not degrees, try this
    cosd(45)
    sind(45)