# Rotating a line around a point in space with rotation matrix

#### erepo

I'm asked to find the eqn of a line that has been rotated around a point Q(x0,y0)
where the eqn of the original line is ax+by+c=0
Is it acceptable to treat the line as the point P(a,b) to ultimately find point R (the end location of P) and ignore the point c (simply adding it back in at the end of the work) I ask this as my lecturer told us all we should follow 5 steps.
1. Move the point Q to the origin so we can use the rotation matrix and hence subtract Q from P which we will call P'.
2. Then turn the point P' into a column matrix.
3.Multiply by the rotational matrix
4. Turn the new column vector into a coordinate R'
5. Turn R' into R (our desired point) by adding Q to R'

I am extremely confused as to what to do once we have ascertained this point R, as I end up with no points without a coefficient of x or y when I convert R into an eqn with the coordinates as coefficients of x and y in an eqn of form ?x+?y=0 I know the answer has similar points as simply constants.

So is my understanding of the principles ok or am I misinterpreting something along the way.

#### HallsofIvy

MHF Helper
I'm asked to find the eqn of a line that has been rotated around a point Q(x0,y0)
where the eqn of the original line is ax+by+c=0
Is it acceptable to treat the line as the point P(a,b) to ultimately find point R (the end location of P) and ignore the point c (simply adding it back in at the end of the work) I ask this as my lecturer told us all we should follow 5 steps.
1. Move the point Q to the origin so we can use the rotation matrix and hence subtract Q from P which we will call P'.
2. Then turn the point P' into a column matrix.
3.Multiply by the rotational matrix
4. Turn the new column vector into a coordinate R'
5. Turn R' into R (our desired point) by adding Q to R'

I am extremely confused as to what to do once we have ascertained this point R, as I end up with no points without a coefficient of x or y when I convert R into an eqn with the coordinates as coefficients of x and y in an eqn of form ?x+?y=0 I know the answer has similar points as simply constants.

So is my understanding of the principles ok or am I misinterpreting something along the way.

What do you mean "I know the answer has similar points as simply constants"? The problem asks you to find a line. Since you are given the initial line as an equation, ax+ by+ c= 0, I suspect the answer must be given the same way- that is, as an equation in x and y. You cannot "treat the line as a point", because a line is not a point. You can, however, write any point on the line as, say, (x, c/b- ax/b) and transform that. The resulting point will, of course, have the variables x and y in it. That gives you the equation for the line.

• erepo

#### erepo

Ok that's nailed the concept I wasn't understanding. So am I right in saying that when the matrix multiplication is done I should find values of (c/b-ax/b) popping up again? I.E y reappears? Otherwise I'm not seeing how y would reappear.

#### erepo

At the moment I don't understand what to do with the final point to turn in into a line. Do I substitute the points into the original eqn? If someone can clarify this for me I will have this question done completed I think. I have tried this method and at the moment I can't get the right answer. The desired answer is (a cos t − b sin t)x + (a sin t + b cos t)y
= c + a(x0(cos t − 1) + y0 sin t) − b(x0 sin t + y0(1 − cos t) )

wheret=theta but i don't know how to type theta and x0 y0 are x and y with a subscript of zero Ie the same points from the coordinate Q

For some reason my answer would be correct if the rotation matrix was [cost sint]
[-sint cost]
hope it helps u help me XD

Last edited: