# Rotating 2D Vectors

This topic is 3917 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hello, I've been trying to understand the math behind rotating 2D vectors for some time now and I can't seem to figure it out. I've been reading up on Sine and Cosine, and I feel like I've learned more about them, but it still doesn't help me with this specific issue. I don't like using things without understanding them, so hopefully someone can post an explanation. If you also know of any good books/sources that explain this, I'd appreciate if you posted them. The formula: x' = cos(theta)*x - sin(theta)*y y' = sin(theta)*x + cos(theta)*y Thanks

##### Share on other sites
Here is a PDF which seems to explain the derivation of a rotation matrix pretty well. I just googled "derivation rotation matrix" to find it, and there is a lot more.

##### Share on other sites
I am not sure how much you understand about sin and cos but I am a pretty dumb guy myself and it took me a while before I got this concept.

Think about a Cartesian coordinate system where you can plot a point at (x,y).

Now imagine a unit circle whose radius is 1. Cos is similar to "x" and Sin is similar to "y". The Cos and Sin functions give you the x,y coordinate on the edge of the unit circle.

So as you can imagine, if you continue to increase the angle input for Cos and Sin, the new points x1 and x2 will draw a circle as expected which leads into rotation. Sorry, I hope that makes sense.

##### Share on other sites
The pdf smitty presented you with is a good explanation. However I would highly recommend you purchase the following book.

"3D Math Primer for Graphics and Game Development"
By: Fletcher Dunn and Ian Parberry
# ISBN-10: 1556229119
# ISBN-13: 978-1556229114

You can purchase the book at amazon if you follow the link below.
http://www.amazon.com/Primer-Graphics-Development-Wordware-Library/dp/1556229119/ref=sr_1_1?ie=UTF8&s=books&qid=1201635348&sr=8-1

Chapter 7 and 8 would be of especial interest to you I believe.

##### Share on other sites
Wow, thanks for the fast responses. All of the information provided is great!

1. 1
Rutin
31
2. 2
3. 3
4. 4
5. 5

• 13
• 15
• 11
• 10
• 14
• ### Forum Statistics

• Total Topics
632962
• Total Posts
3009498
• ### Who's Online (See full list)

There are no registered users currently online

×