3

I have recently realized that the slope of a line depends on the coordinate system. Suppose we take the standard coordinate system and rotate it $45$ degrees (or, equivalently, $\pi / 4$ radians) counterclockwise. Then, lines of slope $1$ become lines of slope $0$. So, in general, if we rotate a coordinate system $x$ radians counterclockwise, where $x \in [0,2\pi)$, what is the new slope $m'$ of a line that formerly had slope $m$? I want a formula for that function. Also, just to clarify, I am considering lines with undefined slope as having slope $\infty$, the unsigned infinity.

user107952
  • 20,508

1 Answers1

2

Well, the most natural way to find slope is to two a pair of points $(x_1,y_1),(x_2,y_2)$, and find the ratio in changes of their $y$- and $x$-coordinates. Rotations will preserve lines; that is, if $P,Q$ are on a line (containing the origin) and $R$ is a rotation, then $R(P),R(Q),$ and the origin all lie on the same line..

The rotation matrix $$ R_\theta := \begin{bmatrix} \cos \theta & - \sin \theta \\ \sin \theta & \cos \theta \end{bmatrix} $$ rotates $\mathbb{R}^2$ counterclockwise $\theta$ radians about the origin. So let's find $R_\theta$ as it acts on points $(x_i,y_i)$. We will let $(x_i',y_i')$ denote the afterimage of the transformation. $$ \begin{bmatrix} x_i' \\ y_i' \end{bmatrix} = \begin{bmatrix} \cos \theta & - \sin \theta \\ \sin \theta & \cos \theta \end{bmatrix} \begin{bmatrix} x_i \\ y_i \end{bmatrix} = \begin{bmatrix} x_i \cos \theta-y_i \sin \theta \\ x_i \sin \theta + y_i \cos \theta \end{bmatrix} $$ Therefore, if $\ell,\ell'$ are the lines before and after (respectively) the transformation, $$\begin{align*} \text{slope of } \ell' &= \frac{y_2' - y_1'}{x_2' -x_1'} \\ &= \frac{x_2 \sin \theta + y_2 \cos \theta - (x_1 \sin \theta + y_1 \cos \theta)}{x_2 \cos \theta-y_2 \sin \theta - (x_1 \cos \theta-y_1 \sin \theta)}\\ &= \frac{(x_2-x_1) \sin \theta + (y_2-y_1) \cos \theta }{(x_2-x_1) \cos \theta+ (y_1 - y_2) \sin \theta }\\ &= \frac{\Delta x \sin \theta + \Delta y \cos \theta }{\Delta x \cos \theta - \Delta y \sin \theta } \end{align*} $$ up to your cosmetic preference for writing it, and with the convention that $\alpha/0$ represents an undefined slope (a vertical line, slope $\infty$, however you choose to interpret it).

I would wonder if one can explicitly get the slope of $\ell$ into this equation. If we notationally let $m$ represent that slope, up to it being well-defined, then dividing the top and bottom by $\Delta x$ would give $$ \text{slope of } \ell' = \frac{ \sin \theta +m \cos \theta }{ \cos \theta - m \sin \theta } $$ which is something, though it feels unsatisfying to me for some reason.


To help verify and visualize this, I made a Desmos demo. (Mostly as a sanity check to ensure my formula worked.)

PrincessEev
  • 43,815
  • It’s nicer (I think) if you divide through by $\cos\theta$ and think in terms $\tan\theta$. – Ted Shifrin Aug 15 '23 at 23:33
  • Any two points are colinear, so under any injective transformation at all (linear or otherwise), the image of two colinear points will again be colinear. Did you mean "colinear with the origin," perhaps? Or did you mean any three colinear points will have colinear images? – Cameron Buie Aug 15 '23 at 23:36
  • At least the visual I had in my head when thinking about this, I meant with the origin. Thanks for pointing out that out, that oversight was especially silly. I wonder if that simplifies the calculations a bit. (Probably not since one can think of $(0,0)$ as one of the $(x_i,y_i)$ so it should just get to the same answer.) – PrincessEev Aug 16 '23 at 03:10