1
$\begingroup$

I am doing Isometries i.e. Rotations, translations and reflections at the moment. General equations for 2 of them are "easy"

Translation: $f(x,y)=(x+a,y+b)$

Rotation about origin through the angle $\alpha$ is just $f(r,\theta)=(r,\theta+\alpha)$

However I struggle to find similiar function for a reflection in a line. For some simple cases like Reflection in line $y=x$ this is easy, $f(x,y)=(y,x)$ but I struggle to find the way for a general function $f(x)=mx+c$.

Thanks for any help

$\endgroup$
0
$\begingroup$

This is fun. If point P is given and a line $y=m x + c$, then the mirror point Q is

$$ \begin{pmatrix} x_Q \\ y_Q \end{pmatrix} =\begin{bmatrix} \frac{1-m^2}{1+m^2} & \frac{2 m}{1+m^2} \\ \frac{2 m}{1+m^2} & \frac{m^2-1}{1+m^2} \end{bmatrix} \begin{pmatrix} x_P \\ y_P \end{pmatrix} + \begin{pmatrix} -\frac{2 c m}{1+m^2} \\ \frac{2 c}{1+m^2} \end{pmatrix}$$

How

I decomposed the coordinates of point P into three vector parts

  • From the origin to the line (perpendicular to the line) $$ \begin{pmatrix} -\frac{c m}{1+m^2} \\ \frac{c}{1+m^2} \end{pmatrix}$$
  • From there move along the line and closest to P $$ \begin{pmatrix} \frac{m y_P+x_P}{1+m^2} \\ \frac{m ( m y_P+x_P)}{1+m^2} \end{pmatrix} $$
  • From the closest point move perpendicular to P $$ \begin{pmatrix} \frac{m (m x_P - y_P+c)}{1+m^2} \\ -\frac{m x_P-y_P+c}{1+m^2} \end{pmatrix} $$

You can confirm that the following is true

$$ \begin{pmatrix} x_P \\ y_P \end{pmatrix} = \begin{pmatrix} -\frac{c m}{1+m^2} \\ \frac{c}{1+m^2} \end{pmatrix} + \begin{pmatrix} \frac{m y_P+x_P}{1+m^2} \\ \frac{m ( m y_P+x_P)}{1+m^2} \end{pmatrix} + \begin{pmatrix} \frac{m (m x_P - y_P+c)}{1+m^2} \\ -\frac{m x_P-y_P+c}{1+m^2} \end{pmatrix} $$

To get to the mirror point Q flip the direction of the last part

$$ \begin{pmatrix} x_Q \\ y_Q \end{pmatrix} = \begin{pmatrix} -\frac{c m}{1+m^2} \\ \frac{c}{1+m^2} \end{pmatrix} + \begin{pmatrix} \frac{m y_P+x_P}{1+m^2} \\ \frac{m ( m y_P+x_P)}{1+m^2} \end{pmatrix} - \begin{pmatrix} \frac{m (m x_P - y_P+c)}{1+m^2} \\ -\frac{m x_P-y_P+c}{1+m^2} \end{pmatrix} $$

$\endgroup$
  • $\begingroup$ And you are 100% sure it works, Sir? Cause I will memorise it and use it in an exam next week haha. Thank You! $\endgroup$ – Scavenger23 May 5 '17 at 22:33
  • $\begingroup$ I tried it with a sample line and point and it seem to work. You can test it yourself. Download Geogebra (free) and see if the mirror operation it has yields the same result as the above. $\endgroup$ – ja72 May 6 '17 at 0:57
0
$\begingroup$

Hint: If line $l_1$ is reflected in line $l_r$ to become $l_2$ then where they intersect gives you one point of line $l_2$, $(x_0,~ y_0)$. What is the slope of $l_2$? If you can reason this out, then you can write the equation $y-y_0 = m(x-x_0)$ directly.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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