Why is it important to convert angle units when using trigonometric functions?

I was hit by this in a 3D programming class. I was using the OpenGL library which expects radians. I was getting the most bizarre results in a sphere rotation demo that I wrote. I was initializing OpenGL with degrees, but the library used radians. The values I was using looked good, but were way too large when interpreted as radians. The rotation matrix in the library was not written to catch that error. It took a while, but I eventually caught it.
  • #1
fog37
1,568
108
TL;DR Summary
Trig functions and their input argument
Hello,

Periodic trigonometric functions, like sine and cosine, generally take an angle as input to produce an output. Functions do that: given an input they produce an output.

Angles are numerically given by real numbers and can be expressed either in radians or degrees (just two different units). We know that ##\pi/4## and ##45^\circ## are the exact same angle even if they numerically different. How can I clearly explain that the function ##sin(x)## produces the same numerical result, i.e. ##sin(\pi/4) = sin(45^\circ)## even if, numerically, the inputs are the same?

A function, in general, produced a different numerical output if he input is provided a different unit. For example, the circumference ##C=2\pi r## will be different in ##r## is expressed either in ##cm## or ##m##. But the trig functions don't...

Thanks!
 
Mathematics news on Phys.org
  • #2
fog37 said:
A function, in general, produced a different numerical output if he input is provided a different unit. For example, the circumference ##C=2\pi r## will be different in ##r## is expressed either in ##cm## or ##m##. But the trig functions don't...
cm and m aren't really different units except inasmuch as the "centi" simply means 1/100th.

A 10cm circumference is the same length as a .1m circumference, just expressed in a more readable way.
 
  • Like
Likes fog37
  • #3
I think these can be demonstrated by the definition of 45 degrees as 1/8 of 360 degrees (degrees in a circle) just as ##\pi/4## is 1/8 of ##2\pi## radians (radians in a circle).

Hence the sin of this angle however it is represented must have the same value.
 
  • Like
Likes fog37
  • #4
DaveC426913 said:
cm and m aren't really different units except inasmuch as the "centi" simply means 1/100th.

A 10cm circumference is the same length as a .1m circumference, just expressed in a more readable way.
True. I guess I should have used meters and yards.
 
  • #5
jedishrfu said:
I think these can be demonstrated by the definition of 45 degrees as 1/8 of 360 degrees (degrees in a circle) just as ##\pi/4## is 1/8 of ##2\pi## radians (radians in a circle).

Hence the sin if this angle however it is represented must have the same value.
Yes, the sine function is, in the context of a right triangle, a ration between one side and the hypotenuse.

What remains difficult to explain is that, conceptually the two angle measurements are the same but they are numerically different. The sine function seems to know that, under the hood, and produce the same output...
 
  • #6
Its also true that you can use a unit circle to geometrically compute the sin and cos of an angle. The fact that the angle is basically 1/8 of the circle is the same as saying its 45 degrees or ##\pi/4##.

With respect to the sin() on your calculator always coming up with the same value that's just good programming on the calculator programmer's part. He/she likely converted all degree values to radians prior to computing the sin() via some mathematical series calculation which insures a good value for the sine.
 
  • #7
There is no function ##sin() ## where ##sin(\pi/4) = sin(45^{\circ})##. There are two different functions, one which expects a radian input and another which expects a degree input. You will see this if you ever give the wrong input to a function. If we use subscripts to distinguish between the two functions, then you can say that ##sin_{radian}(\pi/4) = sin_{degree}(45^{\circ})##
 
  • #8
ON the calculator you must choose what form of angular measure you will be using. Some famous and not-so-famous mistakes have been made someone put in the wrong input value.

I recall drawing a rosette plot for work in Java and using sin / cos to compute x,y values (polar coords to x,y coords) for the angular data. Instead of getting a nice squiggly circle, I got this mass of tangled lines.

It was then that I realized I forgot to convert my degree values into radian values since the sin()/cos() expected radian values. My 360 degree value was interpretted as 360 radians which is roughly circling the circle 60 times before plotting my x,y value.

Some of the famous ones:

https://www.bbc.com/news/magazine-27509559
 
  • Like
Likes FactChecker
  • #9
jedishrfu said:
ON the calculator you must choose what form of angular measure you will be using. Some famous and not-so-famous mistakes have been made someone put in the wrong input value.

I recall drawing a rosette plot for work in Java and using sin / cos to compute x,y values (polar coords to x,y coords) for the angular data. Instead of getting a nice squiggly circle, I got this mass of tangled lines.

It was then that I realized I forgot to convert my degree values into radian values since the sin()/cos() expected radian values. My 360 degree value was interpretted as 360 radians which is roughly circling the circle 60 times before plotting my x,y value.

Some of the famous ones:

https://www.bbc.com/news/magazine-27509559
I can second that. When you see wild scattered results from some geometry that you expected to be smooth, it is a good idea to look for degrees being input to a trig function that thinks it is radians.
 
  • Haha
Likes jedishrfu

1. What are the basic trigonometric functions?

The basic trigonometric functions are sine (sin), cosine (cos), tangent (tan), cotangent (cot), secant (sec), and cosecant (csc).

2. How are trigonometric functions related to right triangles?

Trigonometric functions are used to relate the sides and angles of right triangles. The sine function is the ratio of the opposite side to the hypotenuse, the cosine function is the ratio of the adjacent side to the hypotenuse, and the tangent function is the ratio of the opposite side to the adjacent side.

3. What is the input for trigonometric functions?

The input for trigonometric functions can be either an angle measure (in radians or degrees) or a ratio of sides in a right triangle.

4. How do you find the value of a trigonometric function?

The value of a trigonometric function can be found using a calculator or by using trigonometric tables. Alternatively, you can use the unit circle to find the values of trigonometric functions for specific angles.

5. What is the range of values for trigonometric functions?

The range of values for trigonometric functions is from -1 to 1. However, the range can vary depending on the input and the type of trigonometric function (sine, cosine, tangent, etc.).

Similar threads

Replies
2
Views
1K
Replies
2
Views
1K
Replies
1
Views
1K
  • Calculus and Beyond Homework Help
Replies
2
Views
97
  • Introductory Physics Homework Help
Replies
29
Views
923
Replies
5
Views
2K
Replies
1
Views
1K
  • Precalculus Mathematics Homework Help
Replies
2
Views
1K
Back
Top