# How to combine a rotation matrix and a stretch matrix into a single matrix for easy Fourier Transform

For full disclosure, this is related to homework. I have to find the Fourier Transform of a function that I've boiled down to the following.

I have a function $f(x,y)$ that I can think of as another function $g(x,y)$ plus a stretch and rotation. (For example, think of turning a circle into an ellipse). So, I have a stretch matrix of:

$$\pmatrix{ \frac{1}{A}& 0\\\ 0& \frac{1}{B}}$$

And I have the standard rotation matrix:

$$\pmatrix{ \cos \theta& -\sin \theta\\\ \sin \theta& \cos \theta}$$

I know that for computing the Fourier transform, $f(Ax)$ is the same as $\frac{1}{det A} F(A^{-T}u)$. So, if I can combine the stretch and rotation into one matrix A, I'm home free. How can I combine these two matrices?

Thanks!