Interested in advertising on Derpibooru? Click here for information!
Techy Cutie Pony Collection!

Help fund the $15 daily operational cost of Derpibooru - support us financially!

Description

Derpy gets rotated by a rotation matrix

safe2283060 artist:notadeliciouspotato220 derpibooru exclusive43034 derpy hooves59802 pegasus544070 pony1712702 g42124838 cute280524 derpabetes4052 equation102 eye clipping through hair20399 featured image1304 female1913759 hi243 mare815252 math1006 math joke17 matrix (mathematics)3 open mouth257865 open smile39980 rotation168 signature50808 simple background646046 smiling431912 solo1504926 speech bubble45336 spread wings105872 waving4764 white background179809 whoooooah2
Source

Comments

Syntax quick reference: **bold** *italic* ||hide text|| `code` __underline__ ~~strike~~ ^sup^ ~sub~

Detailed syntax guide

xbi
Fine Arts - Two hundred uploads with a score of over a hundred (Safe/Suggestive)
Da Magicks! - Merited Fine Arts badge with only their own art
The Power of Love - Given to a publicly verified artist with an image under their artist’s tag that has reached 1000 upvotes
A Really Hyper Artist - 500+ images under their artist tag
Best Artist - Providing quality, Derpibooru-exclusive artwork
A Really Classy Artist - 250+ images under their artist tag
An Artist Who Rocks - 100+ images under their artist tag
Artist -

generic facts about vectors, matrices, coordinate systems

A 2×2 matrix like:
⎡ a  b ⎤  
⎣ c  d ⎦  
describes how some point with coordinates [x, y] is transformed into the new point [x’, y’]:
x' = a⋅x + b⋅y  
y' = c⋅x + d⋅y  
This transformation can also be understood as a combination of two column vectors, [a, c] and [b, d], scaled by the coefficients x and y, respectively:
⎡x'⎤   ⎡a⎤     ⎡b⎤  
⎢  ⎥ = ⎢ ⎥⋅x + ⎢ ⎥⋅y  
⎣y'⎦   ⎣c⎦     ⎣d⎦ 
This also can be seen as calculating a vector with coordinates x and y, but within a coordinate system defined by the vectors [a, c] and [b, d], instead of the usual coordinate system defined by [1, 0] and [0, 1].

Derpy rotation matrix

Now, let’s talk about this specific matrix with column vectors [cos(φ), sin(φ)] and [-sin(φ), cos(φ)]. The first is the vector [1, 0] rotated by an angle φ, and the second is the vector [0, 1] rotated by the same angle. These rotated vectors come from the definitions of sine and cosine, either as coordinates on a unit circle or as ratios in a right triangle.
When you combine these rotated vectors with coefficients x and y:
⎡x'⎤   ⎡cos(φ)⎤     ⎡-sin(φ)⎤  
⎢  ⎥ = ⎢      ⎥⋅x + ⎢       ⎥⋅y  
⎣y'⎦   ⎣sin(φ)⎦     ⎣ cos(φ)⎦

you get a vector [x, y] in a coordinate system that is a rotated version of the standard coordinate system defined by the vectors [1, 0] and [0, 1]. Because it’s defined by almost the same pair of vectors, but both rotated by φ.
——

It’s not me rotating around you. It’s you who is rotating inside me.

Alternative way, which gives exactly the same expressions: let’s define the new coordinate system defined by vector [x, y] and its orthogonal friend [-y, x]. Let’s calculate coordinates in default coordinate system of vector with coordinates [cos(φ), sin(φ)] in this new coordinate system:
[x,y]⋅cos(φ) + [-y,x]⋅sin(φ) = 
[x⋅cos(φ)-y⋅sin(φ), y⋅cos(φ)+x⋅sin(φ)] =
[x', y']

x' = x⋅cos(φ)-y⋅sin(φ)
y' = x⋅sin(φ)+y⋅cos(φ)
This is actually the rotation of vector with coordinates [1, 0] in this new coordinate system [x,y];[-y,x]. Which is also the rotation of the vector with coordinates [x,y] in the original coordinate system. Because vector with coordinates [1,0] in the new coordinate system is vector with coordinates [x,y] in the original coordinate system.