Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

I'm working on building tetris now in Java and am at the point of rotations...

I originally hardcoded all of the rotations, but found that linear algebra was the better way to go.

I'm trying to use a rotation matrix to rotate my pieces, and found I need a good understanding of trigonometry.

That being said, the way I visualize sin and cos is on the bottom part of the picture... a circle drawn on a graph... but images online show the sin cos relationship as the above picture... two waves that are "90 degrees" away from each other...

enter image description here

So, my questions are:

1) I can't seem to visualize how they are 90 degree apart. I can't see how those angles are formed in the above graph from sin and cos.

2) It's said that the relationship is Sin X = Cos (90 - x), and that sin is opposite/hypotenuse and cos = adjacent/hypotenuse... but what exactly does that mean? What do the quotients of these mean in relation to an angle? Let's say x = 45 degrees, adjacent = 5 inches, hypotenuse = 5 inches, and opposite = 4 inches... so sin would be 5"/9" = .55 inches... What does this .55 inches mean in relation to the angle? How is it helpful?

Thank you!!

share|improve this question
    
Damn trig101. Did you try wiki of Khan academy? –  Koba Apr 15 '13 at 19:28
    
@GitGud lol I forgot about the pythagorean theorem... –  Growler Apr 15 '13 at 19:45
    
@Growler I'm sure most people here would like to help you but can't due to the high need of visual aid, at least that's what's keeping me from posting somethings which might be helpful. How do you make these drawings? –  Git Gud Apr 15 '13 at 19:47
    
@GitGud The top graph was copied from online... the bottom one was drawn in MS Paint. I guess if you could just explain the last part of my question What does this .55 inches mean in relation to the angle? How is it helpful?... You don't need to draw anything I suppose. Btw, I fixed the angle lengths above to fit pythagorean theorem –  Growler Apr 15 '13 at 19:50
    
@GitGud given the above lengths... sin = o/h (3/5), cos = a/h (4/5), tan = o/a (3/4)... so sin is the angle of 3/5? Doesn't an angle have to be in degrees? does that mean that sin = 3/5 degrees? That's what I'm struggling with –  Growler Apr 15 '13 at 19:59

2 Answers 2

up vote 2 down vote accepted

In your $345$ triangle, you have $\sin x = \frac 35$ and $\cos x = \frac 45$. This gives $x \approx 36.87^\circ$. Can you see where the first two come from the diagram? The $90^\circ$ offset between sine and cosine comes from the fact that we measure horizontally for the cosine and vertically for the sine. While it is true that $\sin x = \cos (90^\circ -x)$ the $90^\circ$ offset is better expressed $\sin x = \cos x - 90^\circ$. This version has $x$ increasing in the same direction on both sides of the equation.

2) opposite is the side opposite the angle. In your diagram, the $3$ side is opposite angle $x$, the $4$ side is adjacent, and $5$ is the hypotenuse. As I said, this gives $\sin x=\frac 35 = 0.6$ It has no units. The $3$ and $5$ have units of length (say, inches) but when you divide them the quotient has no units. The trig functions result in unitless numbers. The $0.6$ gives you one way to construct the angle, though the fact that $\tan x = \frac 34$ is easier to see. You start going east $4$ units, then north $3$ units, and you have constructed the angle.

share|improve this answer
    
Nice answer! I'm still confused how you're getting x from those... I looked online and they said that that you can rearrange sin(x) = a into x = sin^-1(a) to get the angle? Why would getting the -1 power of sin get you the angle in degrees? –  Growler Apr 15 '13 at 20:35
    
And... You said that cosine is measured horizontally and sine is measured vertically - so in this gif http://www.butlercc.edu/mathematics/math_courses/ma140/SineCosine.gif... sin would be the waves going upward and cosine would be the waves going to the right? –  Growler Apr 15 '13 at 20:42
    
@Growler: $\sin^{-1} x$ is not $\frac 1{\sin x}$ but the angle whose sine is $x$. It is also called $\arcsin x$ It can be confusing notation. To get $x \approx 36.87^\circ$ I used my calculator. –  Ross Millikan Apr 15 '13 at 20:42
    
@Growler: regarding the .gif, no, you have it backwards. Note that the wave going upward shows the horizontal position of the green dot, so that is the cosine wave. The wave going left shows the vertical position of the green dot, so that is the sine wave. 0 degrees is rightward, and cosine 0=1. When the red segment is pointing right, the upward wave is at the extreme right end of its travel. –  Ross Millikan Apr 15 '13 at 20:45
    
Okay, thanks for all of your help! Never thought I'd end up finding trig useful in my life haha. Once I understand this I may come back with questions on Rotation Matrices (en.wikipedia.org/wiki/Rotation_matrix) –  Growler Apr 15 '13 at 20:47

You have a lot of errors that need to be corrected (which may be the source of your confusion) -- but to address the specific question you asked, consider taking your diagram with the circle and rotating the whole thing 90 degrees and see how the expressions of $sin x$ and $cos x$ compare in the two pictures. Also consider a reflection of your diagram with the circle. (e.g. across the line $y=x$)

share|improve this answer
    
If you're referring to the errors in the sides not fitting the pythagorean theorem, I've corrected those. Which other errors did you see? –  Growler Apr 15 '13 at 20:50
    
@Growler: Honestly, nearly every numerical calculation is wrong. e.g. in the picture with the circle, the angle is not 45 degrees, and $\sin x = 3/5$ and $\cos x = 4/5$. Later when you list the sides of a 45-degree right triangle, the side lengths you list aren't those of a right triangle, and your expression for $\sin$ doesn't agree with the side lengths you did list. –  Hurkyl Apr 15 '13 at 21:04
    
okay I was just throwing random numbers up there for pictoral concept sake- wasn't actually checking the validity of the numbers. But I guess that's always good to do –  Growler Apr 15 '13 at 22:03

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.