# S.O.S. Mathematics CyberBoard

Your Resource for mathematics help on the web!
 It is currently Thu, 23 May 2013 03:18:29 UTC

 All times are UTC [ DST ]

 Page 1 of 1 [ 4 posts ]
 Print view Previous topic | Next topic
Author Message
 Post subject: Derive a single MatrixPosted: Wed, 18 Aug 2010 19:40:08 UTC
 S.O.S. Newbie

Joined: Wed, 18 Aug 2010 19:35:33 UTC
Posts: 2
Hi all,

I am revising for an exam resit which takes place next week and I'm really stuck on a question from a past exam paper. The question is:

Derive a single matrix to undertake the following collective 2D transformations. A Scaling by a factor of 2 in both X and Y directions followed by a translation by 2 in the X direction and 3 in the Y direction.

Any advice regarding this would be much appreciated as I am pulling out what's left of my hair trying to figure it out.

I think I need to do this first:

Scaling by 2 in both X and Y directions =

X' = Sx * X Y' = Sy * Y

Translation by 2 in X and 3 in Y directions would follow as =

X' = X + tx Y' = Y + ty

Scaling Matrix would be:

|X'| |2 0| |X|
|Y'|=|0 2|* |Y|

Translation Matrix would be:

|X'| |2 0| |X|
|Y'|=|0 3|* |Y|

And now to combine the two matrices in some way?

Many thanks.

Top

 Post subject: Posted: Thu, 19 Aug 2010 05:50:20 UTC
 Member of the 'S.O.S. Math' Hall of Fame

Joined: Mon, 23 Feb 2009 23:20:33 UTC
Posts: 1049
Usually, two transformation matrices are combined into one simply by multiplying them together.

Your scaling matrix works. Your translation matrix does not, and in fact it can't be done with a 2x2 matrix. You need a 3x3 matrix, and you need to add to the vector another component.

Scaling is a linear transformation, but translation is not. Therefore, in order to complete a translation, you will need to use homogeneous coordinates. Instead of writing the vector as (x,y), you need (x,y,1).

Have a look at this and this, then post again with another attempt.

Top

 Post subject: Posted: Thu, 19 Aug 2010 12:17:35 UTC
 S.O.S. Newbie

Joined: Wed, 18 Aug 2010 19:35:33 UTC
Posts: 2
Thank you for taking the time to reply to my enquiry aswoods, I really appreciate it.

Would I be correct in saying that the translation matrix would be like this:

| X' | |2 0 0| | X |
| Y' | |0 3 0| | Y |
| 1 | |0 0 1| | 1 |

If so, how do I now derive a single matrix to undertake the scaling and the translation?

Cheers again for the help so far mate.

Top

 Post subject: Posted: Thu, 19 Aug 2010 14:16:48 UTC
 Member of the 'S.O.S. Math' Hall of Fame

Joined: Mon, 23 Feb 2009 23:20:33 UTC
Posts: 1049
You need more practice with matrix multiplication! If you multiply that matrix with the vector (x,y,1), you get (2x,3y,1) -- which is obviously not what you want. You want the result to be (2x+2, 2y+3, 1).

The articles I linked to say that scaling by a factor of k looks like this:

Translation by (p,q) looks like this:

Multiply them both out to confirm that this works.

Now, to combine them you can multiply the matrices. If you do A first, then B, then you need it to look like this: B(Av) because you are applying A first, to get Av, then applying B to get B(Av). So the matrix which does both in one go is BA. (If you did B first, then A, it would be AB.)

You will find that the resulting matrix BA (when A is the scaling, and B is the translation) is pretty simple.

Multiply out the right-hand side to check that it works.

Also, check if you are supposed to use homogeneous coordinates in the exam. Maybe they have something different in mind.

Top

 Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending
 Page 1 of 1 [ 4 posts ]

 All times are UTC [ DST ]

#### Who is online

Users browsing this forum: No registered users

 You cannot post new topics in this forumYou cannot reply to topics in this forumYou cannot edit your posts in this forumYou cannot delete your posts in this forum

Search for:
 Jump to:  Select a forum ------------------ High School and College Mathematics    Algebra    Geometry and Trigonometry    Calculus    Matrix Algebra    Differential Equations    Probability and Statistics    Proposed Problems Applications    Physics, Chemistry, Engineering, etc.    Computer Science    Math for Business and Economics Advanced Mathematics    Foundations    Algebra and Number Theory    Analysis and Topology    Applied Mathematics    Other Topics in Advanced Mathematics Other Topics    Administrator Announcements    Comments and Suggestions for S.O.S. Math    Posting Math Formulas with LaTeX    Miscellaneous