The difference between applying a rotation matrix to a vector (points) and to a matrix (transformation)












10












$begingroup$


Suppose that the rotation matrix is defined as $mathbf{R}$. Then in order to rotate a vector and a matrix, the following expressions are, respectively, used



$mathbf{u'}=mathbf{R} mathbf{u}$



and



$mathbf{U'}=mathbf{R} mathbf{U} mathbf{R}^T$,



where $mathbf{u}$ and $mathbf{U}$ are, respectively, an arbitrary vector and an arbitrary matrix.



For me, the first one is obvious since you simply multiply the rotation matrix by the vector (for example a point coordinate in 3D) and obtain the rotated vector (rotated point coordinate in 3D). However, the second one is not clear for me and why the rotation should be multiplied from both sides and how this expression is derived.



P.S. The matrix $mathbf{U}$ can be interpreted as a stretch matrix in 3D.










share|cite|improve this question











$endgroup$












  • $begingroup$
    If you have a linear algebra textbook on hand, you might find it instructive to read about changes of basis. The matrix $R$, in this context, can be nicely thought of as a change-of-basis matrix.
    $endgroup$
    – Omnomnomnom
    Jan 4 at 13:49






  • 1




    $begingroup$
    The expression $RU$ also is a kind of "rotation of $U$," namely, it takes whatever transformation $U$ was going to perform and composes that with a subsequent rotation represented by $R.$ But this is actually giving us a new transformation within the old coordinate system, not rewriting the old transformation in a new coordinate system as we would get from $RUR^T.$
    $endgroup$
    – David K
    Jan 4 at 19:40












  • $begingroup$
    When you say "$U$ is a matrix", it makes a difference whether $U$ is merely a set of points (in which case $RU$ is already the "rotation of $U$"), or itself a transformation matrix (as in this case). Can you please edit your title/body to be more clear?
    $endgroup$
    – smci
    Jan 5 at 6:05












  • $begingroup$
    @smci Look at the P.S. note. I have mentioned that U is a stretch matrix. not a set of points.
    $endgroup$
    – Msen Rezaee
    Jan 5 at 9:04










  • $begingroup$
    Yes that's more clear now
    $endgroup$
    – smci
    Jan 5 at 9:22
















10












$begingroup$


Suppose that the rotation matrix is defined as $mathbf{R}$. Then in order to rotate a vector and a matrix, the following expressions are, respectively, used



$mathbf{u'}=mathbf{R} mathbf{u}$



and



$mathbf{U'}=mathbf{R} mathbf{U} mathbf{R}^T$,



where $mathbf{u}$ and $mathbf{U}$ are, respectively, an arbitrary vector and an arbitrary matrix.



For me, the first one is obvious since you simply multiply the rotation matrix by the vector (for example a point coordinate in 3D) and obtain the rotated vector (rotated point coordinate in 3D). However, the second one is not clear for me and why the rotation should be multiplied from both sides and how this expression is derived.



P.S. The matrix $mathbf{U}$ can be interpreted as a stretch matrix in 3D.










share|cite|improve this question











$endgroup$












  • $begingroup$
    If you have a linear algebra textbook on hand, you might find it instructive to read about changes of basis. The matrix $R$, in this context, can be nicely thought of as a change-of-basis matrix.
    $endgroup$
    – Omnomnomnom
    Jan 4 at 13:49






  • 1




    $begingroup$
    The expression $RU$ also is a kind of "rotation of $U$," namely, it takes whatever transformation $U$ was going to perform and composes that with a subsequent rotation represented by $R.$ But this is actually giving us a new transformation within the old coordinate system, not rewriting the old transformation in a new coordinate system as we would get from $RUR^T.$
    $endgroup$
    – David K
    Jan 4 at 19:40












  • $begingroup$
    When you say "$U$ is a matrix", it makes a difference whether $U$ is merely a set of points (in which case $RU$ is already the "rotation of $U$"), or itself a transformation matrix (as in this case). Can you please edit your title/body to be more clear?
    $endgroup$
    – smci
    Jan 5 at 6:05












  • $begingroup$
    @smci Look at the P.S. note. I have mentioned that U is a stretch matrix. not a set of points.
    $endgroup$
    – Msen Rezaee
    Jan 5 at 9:04










  • $begingroup$
    Yes that's more clear now
    $endgroup$
    – smci
    Jan 5 at 9:22














10












10








10


5



$begingroup$


Suppose that the rotation matrix is defined as $mathbf{R}$. Then in order to rotate a vector and a matrix, the following expressions are, respectively, used



$mathbf{u'}=mathbf{R} mathbf{u}$



and



$mathbf{U'}=mathbf{R} mathbf{U} mathbf{R}^T$,



where $mathbf{u}$ and $mathbf{U}$ are, respectively, an arbitrary vector and an arbitrary matrix.



For me, the first one is obvious since you simply multiply the rotation matrix by the vector (for example a point coordinate in 3D) and obtain the rotated vector (rotated point coordinate in 3D). However, the second one is not clear for me and why the rotation should be multiplied from both sides and how this expression is derived.



P.S. The matrix $mathbf{U}$ can be interpreted as a stretch matrix in 3D.










share|cite|improve this question











$endgroup$




Suppose that the rotation matrix is defined as $mathbf{R}$. Then in order to rotate a vector and a matrix, the following expressions are, respectively, used



$mathbf{u'}=mathbf{R} mathbf{u}$



and



$mathbf{U'}=mathbf{R} mathbf{U} mathbf{R}^T$,



where $mathbf{u}$ and $mathbf{U}$ are, respectively, an arbitrary vector and an arbitrary matrix.



For me, the first one is obvious since you simply multiply the rotation matrix by the vector (for example a point coordinate in 3D) and obtain the rotated vector (rotated point coordinate in 3D). However, the second one is not clear for me and why the rotation should be multiplied from both sides and how this expression is derived.



P.S. The matrix $mathbf{U}$ can be interpreted as a stretch matrix in 3D.







linear-algebra matrices vectors rotations






share|cite|improve this question















share|cite|improve this question













share|cite|improve this question




share|cite|improve this question








edited Jan 5 at 9:04







Msen Rezaee

















asked Jan 4 at 13:15









Msen RezaeeMsen Rezaee

306312




306312












  • $begingroup$
    If you have a linear algebra textbook on hand, you might find it instructive to read about changes of basis. The matrix $R$, in this context, can be nicely thought of as a change-of-basis matrix.
    $endgroup$
    – Omnomnomnom
    Jan 4 at 13:49






  • 1




    $begingroup$
    The expression $RU$ also is a kind of "rotation of $U$," namely, it takes whatever transformation $U$ was going to perform and composes that with a subsequent rotation represented by $R.$ But this is actually giving us a new transformation within the old coordinate system, not rewriting the old transformation in a new coordinate system as we would get from $RUR^T.$
    $endgroup$
    – David K
    Jan 4 at 19:40












  • $begingroup$
    When you say "$U$ is a matrix", it makes a difference whether $U$ is merely a set of points (in which case $RU$ is already the "rotation of $U$"), or itself a transformation matrix (as in this case). Can you please edit your title/body to be more clear?
    $endgroup$
    – smci
    Jan 5 at 6:05












  • $begingroup$
    @smci Look at the P.S. note. I have mentioned that U is a stretch matrix. not a set of points.
    $endgroup$
    – Msen Rezaee
    Jan 5 at 9:04










  • $begingroup$
    Yes that's more clear now
    $endgroup$
    – smci
    Jan 5 at 9:22


















  • $begingroup$
    If you have a linear algebra textbook on hand, you might find it instructive to read about changes of basis. The matrix $R$, in this context, can be nicely thought of as a change-of-basis matrix.
    $endgroup$
    – Omnomnomnom
    Jan 4 at 13:49






  • 1




    $begingroup$
    The expression $RU$ also is a kind of "rotation of $U$," namely, it takes whatever transformation $U$ was going to perform and composes that with a subsequent rotation represented by $R.$ But this is actually giving us a new transformation within the old coordinate system, not rewriting the old transformation in a new coordinate system as we would get from $RUR^T.$
    $endgroup$
    – David K
    Jan 4 at 19:40












  • $begingroup$
    When you say "$U$ is a matrix", it makes a difference whether $U$ is merely a set of points (in which case $RU$ is already the "rotation of $U$"), or itself a transformation matrix (as in this case). Can you please edit your title/body to be more clear?
    $endgroup$
    – smci
    Jan 5 at 6:05












  • $begingroup$
    @smci Look at the P.S. note. I have mentioned that U is a stretch matrix. not a set of points.
    $endgroup$
    – Msen Rezaee
    Jan 5 at 9:04










  • $begingroup$
    Yes that's more clear now
    $endgroup$
    – smci
    Jan 5 at 9:22
















$begingroup$
If you have a linear algebra textbook on hand, you might find it instructive to read about changes of basis. The matrix $R$, in this context, can be nicely thought of as a change-of-basis matrix.
$endgroup$
– Omnomnomnom
Jan 4 at 13:49




$begingroup$
If you have a linear algebra textbook on hand, you might find it instructive to read about changes of basis. The matrix $R$, in this context, can be nicely thought of as a change-of-basis matrix.
$endgroup$
– Omnomnomnom
Jan 4 at 13:49




1




1




$begingroup$
The expression $RU$ also is a kind of "rotation of $U$," namely, it takes whatever transformation $U$ was going to perform and composes that with a subsequent rotation represented by $R.$ But this is actually giving us a new transformation within the old coordinate system, not rewriting the old transformation in a new coordinate system as we would get from $RUR^T.$
$endgroup$
– David K
Jan 4 at 19:40






$begingroup$
The expression $RU$ also is a kind of "rotation of $U$," namely, it takes whatever transformation $U$ was going to perform and composes that with a subsequent rotation represented by $R.$ But this is actually giving us a new transformation within the old coordinate system, not rewriting the old transformation in a new coordinate system as we would get from $RUR^T.$
$endgroup$
– David K
Jan 4 at 19:40














$begingroup$
When you say "$U$ is a matrix", it makes a difference whether $U$ is merely a set of points (in which case $RU$ is already the "rotation of $U$"), or itself a transformation matrix (as in this case). Can you please edit your title/body to be more clear?
$endgroup$
– smci
Jan 5 at 6:05






$begingroup$
When you say "$U$ is a matrix", it makes a difference whether $U$ is merely a set of points (in which case $RU$ is already the "rotation of $U$"), or itself a transformation matrix (as in this case). Can you please edit your title/body to be more clear?
$endgroup$
– smci
Jan 5 at 6:05














$begingroup$
@smci Look at the P.S. note. I have mentioned that U is a stretch matrix. not a set of points.
$endgroup$
– Msen Rezaee
Jan 5 at 9:04




$begingroup$
@smci Look at the P.S. note. I have mentioned that U is a stretch matrix. not a set of points.
$endgroup$
– Msen Rezaee
Jan 5 at 9:04












$begingroup$
Yes that's more clear now
$endgroup$
– smci
Jan 5 at 9:22




$begingroup$
Yes that's more clear now
$endgroup$
– smci
Jan 5 at 9:22










4 Answers
4






active

oldest

votes


















15












$begingroup$

Here the matrix $U$ is considered not as a bunch of column vectors, but as a (matrix of the) linear map $Fcolon {Bbb R}^nto {Bbb R}^n$
$$
y=F(x)=Ux.
$$

What happens if we rotate both $y$ and $x$ by $R$? We get (since $R^TR=I$ for rotations)
$$
y=UxquadRightarrowquad Ry=RUxquadRightarrowquad Ry=underbrace{RUR^T}_{U'}RxquadRightarrowquad y'=U'x'.
$$

Thus the matrix $U'=RUR^T$ corresponds to the same linear map $F$ in the new coordinates after rotation ($x'mapsto y'$).



In general, for any change of the basis $x'=Sx$, $y'=Sy$ the corresponding change of the matrix $U$ is
$$
Sy=underbrace{SUS^{-1}}_{U'}SxquadRightarrowquad y'=U'x'.
$$

It means that the class of all similar matrices ${SUS^{-1}colon Stext{ invertible}}$ is exactly the class of all matrices that describe the same linear map in different bases.






share|cite|improve this answer











$endgroup$













  • $begingroup$
    It's more or less the same thing, but if U is symmetric, you can also look at it as a bilinear form, $U(x,y) = x^top U y$. Then if we rotate $x$ and $y$ by $R$, we get $$x^top R^top U' R y = x^top U y$$ So $R^top U' R = U$ and $U' = R U R^top$.
    $endgroup$
    – Kitegi
    Jan 6 at 16:05



















5












$begingroup$

Using your example where $U$ is a stretch matrix in 3D, if you want to "rotate" this matrix, you essentially want this stretch action to occur in a different direction / axis. Suppose you have some shape aligned to this new axis. You want to know what the $U'$ is that stretches the shape parallel to this axis. To do this, you use $R^T$ to rotate everything back to the original orientation. Then you do the original stretch transformation $U$. Then you rotate this back using $R$. So $U'=RUR^T$.



enter image description here






share|cite|improve this answer











$endgroup$













  • $begingroup$
    Thanks for your answer. But could you please give me a clearer example. I understood your point. However, I couldn't understand your example.
    $endgroup$
    – Msen Rezaee
    Jan 4 at 13:44










  • $begingroup$
    @MsenRezaee I added a picture to help illustrate the point. It is in 2D rather than 3D, but it should be simple to see how this generalises
    $endgroup$
    – John Doe
    Jan 4 at 16:06





















3












$begingroup$

One thing that may be instructive is to recall that every matrix can be represented as the linear combination of a series of dyadic/outer products between two vectors, $U = sum_i a_i otimes b_i = sum_i a_i b_i^T$ where $a_i$ and $b_i$ are a sequence of column vectors.



When changing the basis of the matrix, we are in effect applying the vector rule for changing bases to both sequences of vectors:



$$U’ = sum_i a_i’ otimes b_i’ = sum_i Ra_i (Rb_i)^T = sum_iRa_ib_i^T R^T = RUR^T$$



Hope this helps!






share|cite|improve this answer











$endgroup$









  • 2




    $begingroup$
    This is not language I'm familiar with, but wouldn't $ab^T$ always be rank $1$, so only rank $1$ matrices can be represented this way?
    $endgroup$
    – Callus
    Jan 4 at 13:38






  • 2




    $begingroup$
    @Callus I guess it was meant that any matrix could be represented as a span of dyadic matrices.
    $endgroup$
    – A.Γ.
    Jan 4 at 13:45










  • $begingroup$
    Correct, thank you for spotting that @Callus and @A.Γ.! Will update answer shortly.
    $endgroup$
    – aghostinthefigures
    Jan 4 at 13:48



















0












$begingroup$

The columns of $mathbf{U}$ tell you what happens to the coordinate vectors $hat{e}_1,hat{e}_2,hat{e}_3$. For example, if the first column is $[a,b,c]^T$, then $mathbf{U}hat{e}_1 = ahat{e}_1 + bhat{e}_2 + chat{e}_3$.



The matrix $mathbf{U}'$ is the matrix that behaves the same way on the rotated coordinate basis $hat{f}_i = mathbf{R}hat{e}_i$. This is because $mathbf{R}^T = mathbf{R}^{-1}$ so for example
$$begin{align*}
mathbf{U}'hat{f}_1 &= mathbf{R}mathbf{U}mathbf{R}^Tmathbf{R}hat{e}_1 \
&= mathbf{R}left(mathbf{U}hat{e}_1right) \
&= mathbf{R}(ahat{e}_1 + bhat{e}_2 + chat{e}_3) \
&= amathbf{R}hat{e}_1 + bmathbf{R}hat{e}_2 + cmathbf{R}hat{e}_3 \
&= ahat{f}_1 + bhat{f}_2 + chat{f}_3
end{align*}
$$






share|cite|improve this answer









$endgroup$













    Your Answer





    StackExchange.ifUsing("editor", function () {
    return StackExchange.using("mathjaxEditing", function () {
    StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
    StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
    });
    });
    }, "mathjax-editing");

    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "69"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    noCode: true, onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3061638%2fthe-difference-between-applying-a-rotation-matrix-to-a-vector-points-and-to-a%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    4 Answers
    4






    active

    oldest

    votes








    4 Answers
    4






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    15












    $begingroup$

    Here the matrix $U$ is considered not as a bunch of column vectors, but as a (matrix of the) linear map $Fcolon {Bbb R}^nto {Bbb R}^n$
    $$
    y=F(x)=Ux.
    $$

    What happens if we rotate both $y$ and $x$ by $R$? We get (since $R^TR=I$ for rotations)
    $$
    y=UxquadRightarrowquad Ry=RUxquadRightarrowquad Ry=underbrace{RUR^T}_{U'}RxquadRightarrowquad y'=U'x'.
    $$

    Thus the matrix $U'=RUR^T$ corresponds to the same linear map $F$ in the new coordinates after rotation ($x'mapsto y'$).



    In general, for any change of the basis $x'=Sx$, $y'=Sy$ the corresponding change of the matrix $U$ is
    $$
    Sy=underbrace{SUS^{-1}}_{U'}SxquadRightarrowquad y'=U'x'.
    $$

    It means that the class of all similar matrices ${SUS^{-1}colon Stext{ invertible}}$ is exactly the class of all matrices that describe the same linear map in different bases.






    share|cite|improve this answer











    $endgroup$













    • $begingroup$
      It's more or less the same thing, but if U is symmetric, you can also look at it as a bilinear form, $U(x,y) = x^top U y$. Then if we rotate $x$ and $y$ by $R$, we get $$x^top R^top U' R y = x^top U y$$ So $R^top U' R = U$ and $U' = R U R^top$.
      $endgroup$
      – Kitegi
      Jan 6 at 16:05
















    15












    $begingroup$

    Here the matrix $U$ is considered not as a bunch of column vectors, but as a (matrix of the) linear map $Fcolon {Bbb R}^nto {Bbb R}^n$
    $$
    y=F(x)=Ux.
    $$

    What happens if we rotate both $y$ and $x$ by $R$? We get (since $R^TR=I$ for rotations)
    $$
    y=UxquadRightarrowquad Ry=RUxquadRightarrowquad Ry=underbrace{RUR^T}_{U'}RxquadRightarrowquad y'=U'x'.
    $$

    Thus the matrix $U'=RUR^T$ corresponds to the same linear map $F$ in the new coordinates after rotation ($x'mapsto y'$).



    In general, for any change of the basis $x'=Sx$, $y'=Sy$ the corresponding change of the matrix $U$ is
    $$
    Sy=underbrace{SUS^{-1}}_{U'}SxquadRightarrowquad y'=U'x'.
    $$

    It means that the class of all similar matrices ${SUS^{-1}colon Stext{ invertible}}$ is exactly the class of all matrices that describe the same linear map in different bases.






    share|cite|improve this answer











    $endgroup$













    • $begingroup$
      It's more or less the same thing, but if U is symmetric, you can also look at it as a bilinear form, $U(x,y) = x^top U y$. Then if we rotate $x$ and $y$ by $R$, we get $$x^top R^top U' R y = x^top U y$$ So $R^top U' R = U$ and $U' = R U R^top$.
      $endgroup$
      – Kitegi
      Jan 6 at 16:05














    15












    15








    15





    $begingroup$

    Here the matrix $U$ is considered not as a bunch of column vectors, but as a (matrix of the) linear map $Fcolon {Bbb R}^nto {Bbb R}^n$
    $$
    y=F(x)=Ux.
    $$

    What happens if we rotate both $y$ and $x$ by $R$? We get (since $R^TR=I$ for rotations)
    $$
    y=UxquadRightarrowquad Ry=RUxquadRightarrowquad Ry=underbrace{RUR^T}_{U'}RxquadRightarrowquad y'=U'x'.
    $$

    Thus the matrix $U'=RUR^T$ corresponds to the same linear map $F$ in the new coordinates after rotation ($x'mapsto y'$).



    In general, for any change of the basis $x'=Sx$, $y'=Sy$ the corresponding change of the matrix $U$ is
    $$
    Sy=underbrace{SUS^{-1}}_{U'}SxquadRightarrowquad y'=U'x'.
    $$

    It means that the class of all similar matrices ${SUS^{-1}colon Stext{ invertible}}$ is exactly the class of all matrices that describe the same linear map in different bases.






    share|cite|improve this answer











    $endgroup$



    Here the matrix $U$ is considered not as a bunch of column vectors, but as a (matrix of the) linear map $Fcolon {Bbb R}^nto {Bbb R}^n$
    $$
    y=F(x)=Ux.
    $$

    What happens if we rotate both $y$ and $x$ by $R$? We get (since $R^TR=I$ for rotations)
    $$
    y=UxquadRightarrowquad Ry=RUxquadRightarrowquad Ry=underbrace{RUR^T}_{U'}RxquadRightarrowquad y'=U'x'.
    $$

    Thus the matrix $U'=RUR^T$ corresponds to the same linear map $F$ in the new coordinates after rotation ($x'mapsto y'$).



    In general, for any change of the basis $x'=Sx$, $y'=Sy$ the corresponding change of the matrix $U$ is
    $$
    Sy=underbrace{SUS^{-1}}_{U'}SxquadRightarrowquad y'=U'x'.
    $$

    It means that the class of all similar matrices ${SUS^{-1}colon Stext{ invertible}}$ is exactly the class of all matrices that describe the same linear map in different bases.







    share|cite|improve this answer














    share|cite|improve this answer



    share|cite|improve this answer








    edited Jan 4 at 13:40

























    answered Jan 4 at 13:25









    A.Γ.A.Γ.

    22.7k32656




    22.7k32656












    • $begingroup$
      It's more or less the same thing, but if U is symmetric, you can also look at it as a bilinear form, $U(x,y) = x^top U y$. Then if we rotate $x$ and $y$ by $R$, we get $$x^top R^top U' R y = x^top U y$$ So $R^top U' R = U$ and $U' = R U R^top$.
      $endgroup$
      – Kitegi
      Jan 6 at 16:05


















    • $begingroup$
      It's more or less the same thing, but if U is symmetric, you can also look at it as a bilinear form, $U(x,y) = x^top U y$. Then if we rotate $x$ and $y$ by $R$, we get $$x^top R^top U' R y = x^top U y$$ So $R^top U' R = U$ and $U' = R U R^top$.
      $endgroup$
      – Kitegi
      Jan 6 at 16:05
















    $begingroup$
    It's more or less the same thing, but if U is symmetric, you can also look at it as a bilinear form, $U(x,y) = x^top U y$. Then if we rotate $x$ and $y$ by $R$, we get $$x^top R^top U' R y = x^top U y$$ So $R^top U' R = U$ and $U' = R U R^top$.
    $endgroup$
    – Kitegi
    Jan 6 at 16:05




    $begingroup$
    It's more or less the same thing, but if U is symmetric, you can also look at it as a bilinear form, $U(x,y) = x^top U y$. Then if we rotate $x$ and $y$ by $R$, we get $$x^top R^top U' R y = x^top U y$$ So $R^top U' R = U$ and $U' = R U R^top$.
    $endgroup$
    – Kitegi
    Jan 6 at 16:05











    5












    $begingroup$

    Using your example where $U$ is a stretch matrix in 3D, if you want to "rotate" this matrix, you essentially want this stretch action to occur in a different direction / axis. Suppose you have some shape aligned to this new axis. You want to know what the $U'$ is that stretches the shape parallel to this axis. To do this, you use $R^T$ to rotate everything back to the original orientation. Then you do the original stretch transformation $U$. Then you rotate this back using $R$. So $U'=RUR^T$.



    enter image description here






    share|cite|improve this answer











    $endgroup$













    • $begingroup$
      Thanks for your answer. But could you please give me a clearer example. I understood your point. However, I couldn't understand your example.
      $endgroup$
      – Msen Rezaee
      Jan 4 at 13:44










    • $begingroup$
      @MsenRezaee I added a picture to help illustrate the point. It is in 2D rather than 3D, but it should be simple to see how this generalises
      $endgroup$
      – John Doe
      Jan 4 at 16:06


















    5












    $begingroup$

    Using your example where $U$ is a stretch matrix in 3D, if you want to "rotate" this matrix, you essentially want this stretch action to occur in a different direction / axis. Suppose you have some shape aligned to this new axis. You want to know what the $U'$ is that stretches the shape parallel to this axis. To do this, you use $R^T$ to rotate everything back to the original orientation. Then you do the original stretch transformation $U$. Then you rotate this back using $R$. So $U'=RUR^T$.



    enter image description here






    share|cite|improve this answer











    $endgroup$













    • $begingroup$
      Thanks for your answer. But could you please give me a clearer example. I understood your point. However, I couldn't understand your example.
      $endgroup$
      – Msen Rezaee
      Jan 4 at 13:44










    • $begingroup$
      @MsenRezaee I added a picture to help illustrate the point. It is in 2D rather than 3D, but it should be simple to see how this generalises
      $endgroup$
      – John Doe
      Jan 4 at 16:06
















    5












    5








    5





    $begingroup$

    Using your example where $U$ is a stretch matrix in 3D, if you want to "rotate" this matrix, you essentially want this stretch action to occur in a different direction / axis. Suppose you have some shape aligned to this new axis. You want to know what the $U'$ is that stretches the shape parallel to this axis. To do this, you use $R^T$ to rotate everything back to the original orientation. Then you do the original stretch transformation $U$. Then you rotate this back using $R$. So $U'=RUR^T$.



    enter image description here






    share|cite|improve this answer











    $endgroup$



    Using your example where $U$ is a stretch matrix in 3D, if you want to "rotate" this matrix, you essentially want this stretch action to occur in a different direction / axis. Suppose you have some shape aligned to this new axis. You want to know what the $U'$ is that stretches the shape parallel to this axis. To do this, you use $R^T$ to rotate everything back to the original orientation. Then you do the original stretch transformation $U$. Then you rotate this back using $R$. So $U'=RUR^T$.



    enter image description here







    share|cite|improve this answer














    share|cite|improve this answer



    share|cite|improve this answer








    edited Jan 4 at 16:06

























    answered Jan 4 at 13:28









    John DoeJohn Doe

    11.1k11238




    11.1k11238












    • $begingroup$
      Thanks for your answer. But could you please give me a clearer example. I understood your point. However, I couldn't understand your example.
      $endgroup$
      – Msen Rezaee
      Jan 4 at 13:44










    • $begingroup$
      @MsenRezaee I added a picture to help illustrate the point. It is in 2D rather than 3D, but it should be simple to see how this generalises
      $endgroup$
      – John Doe
      Jan 4 at 16:06




















    • $begingroup$
      Thanks for your answer. But could you please give me a clearer example. I understood your point. However, I couldn't understand your example.
      $endgroup$
      – Msen Rezaee
      Jan 4 at 13:44










    • $begingroup$
      @MsenRezaee I added a picture to help illustrate the point. It is in 2D rather than 3D, but it should be simple to see how this generalises
      $endgroup$
      – John Doe
      Jan 4 at 16:06


















    $begingroup$
    Thanks for your answer. But could you please give me a clearer example. I understood your point. However, I couldn't understand your example.
    $endgroup$
    – Msen Rezaee
    Jan 4 at 13:44




    $begingroup$
    Thanks for your answer. But could you please give me a clearer example. I understood your point. However, I couldn't understand your example.
    $endgroup$
    – Msen Rezaee
    Jan 4 at 13:44












    $begingroup$
    @MsenRezaee I added a picture to help illustrate the point. It is in 2D rather than 3D, but it should be simple to see how this generalises
    $endgroup$
    – John Doe
    Jan 4 at 16:06






    $begingroup$
    @MsenRezaee I added a picture to help illustrate the point. It is in 2D rather than 3D, but it should be simple to see how this generalises
    $endgroup$
    – John Doe
    Jan 4 at 16:06













    3












    $begingroup$

    One thing that may be instructive is to recall that every matrix can be represented as the linear combination of a series of dyadic/outer products between two vectors, $U = sum_i a_i otimes b_i = sum_i a_i b_i^T$ where $a_i$ and $b_i$ are a sequence of column vectors.



    When changing the basis of the matrix, we are in effect applying the vector rule for changing bases to both sequences of vectors:



    $$U’ = sum_i a_i’ otimes b_i’ = sum_i Ra_i (Rb_i)^T = sum_iRa_ib_i^T R^T = RUR^T$$



    Hope this helps!






    share|cite|improve this answer











    $endgroup$









    • 2




      $begingroup$
      This is not language I'm familiar with, but wouldn't $ab^T$ always be rank $1$, so only rank $1$ matrices can be represented this way?
      $endgroup$
      – Callus
      Jan 4 at 13:38






    • 2




      $begingroup$
      @Callus I guess it was meant that any matrix could be represented as a span of dyadic matrices.
      $endgroup$
      – A.Γ.
      Jan 4 at 13:45










    • $begingroup$
      Correct, thank you for spotting that @Callus and @A.Γ.! Will update answer shortly.
      $endgroup$
      – aghostinthefigures
      Jan 4 at 13:48
















    3












    $begingroup$

    One thing that may be instructive is to recall that every matrix can be represented as the linear combination of a series of dyadic/outer products between two vectors, $U = sum_i a_i otimes b_i = sum_i a_i b_i^T$ where $a_i$ and $b_i$ are a sequence of column vectors.



    When changing the basis of the matrix, we are in effect applying the vector rule for changing bases to both sequences of vectors:



    $$U’ = sum_i a_i’ otimes b_i’ = sum_i Ra_i (Rb_i)^T = sum_iRa_ib_i^T R^T = RUR^T$$



    Hope this helps!






    share|cite|improve this answer











    $endgroup$









    • 2




      $begingroup$
      This is not language I'm familiar with, but wouldn't $ab^T$ always be rank $1$, so only rank $1$ matrices can be represented this way?
      $endgroup$
      – Callus
      Jan 4 at 13:38






    • 2




      $begingroup$
      @Callus I guess it was meant that any matrix could be represented as a span of dyadic matrices.
      $endgroup$
      – A.Γ.
      Jan 4 at 13:45










    • $begingroup$
      Correct, thank you for spotting that @Callus and @A.Γ.! Will update answer shortly.
      $endgroup$
      – aghostinthefigures
      Jan 4 at 13:48














    3












    3








    3





    $begingroup$

    One thing that may be instructive is to recall that every matrix can be represented as the linear combination of a series of dyadic/outer products between two vectors, $U = sum_i a_i otimes b_i = sum_i a_i b_i^T$ where $a_i$ and $b_i$ are a sequence of column vectors.



    When changing the basis of the matrix, we are in effect applying the vector rule for changing bases to both sequences of vectors:



    $$U’ = sum_i a_i’ otimes b_i’ = sum_i Ra_i (Rb_i)^T = sum_iRa_ib_i^T R^T = RUR^T$$



    Hope this helps!






    share|cite|improve this answer











    $endgroup$



    One thing that may be instructive is to recall that every matrix can be represented as the linear combination of a series of dyadic/outer products between two vectors, $U = sum_i a_i otimes b_i = sum_i a_i b_i^T$ where $a_i$ and $b_i$ are a sequence of column vectors.



    When changing the basis of the matrix, we are in effect applying the vector rule for changing bases to both sequences of vectors:



    $$U’ = sum_i a_i’ otimes b_i’ = sum_i Ra_i (Rb_i)^T = sum_iRa_ib_i^T R^T = RUR^T$$



    Hope this helps!







    share|cite|improve this answer














    share|cite|improve this answer



    share|cite|improve this answer








    edited Jan 4 at 13:54

























    answered Jan 4 at 13:26









    aghostinthefiguresaghostinthefigures

    1,2301216




    1,2301216








    • 2




      $begingroup$
      This is not language I'm familiar with, but wouldn't $ab^T$ always be rank $1$, so only rank $1$ matrices can be represented this way?
      $endgroup$
      – Callus
      Jan 4 at 13:38






    • 2




      $begingroup$
      @Callus I guess it was meant that any matrix could be represented as a span of dyadic matrices.
      $endgroup$
      – A.Γ.
      Jan 4 at 13:45










    • $begingroup$
      Correct, thank you for spotting that @Callus and @A.Γ.! Will update answer shortly.
      $endgroup$
      – aghostinthefigures
      Jan 4 at 13:48














    • 2




      $begingroup$
      This is not language I'm familiar with, but wouldn't $ab^T$ always be rank $1$, so only rank $1$ matrices can be represented this way?
      $endgroup$
      – Callus
      Jan 4 at 13:38






    • 2




      $begingroup$
      @Callus I guess it was meant that any matrix could be represented as a span of dyadic matrices.
      $endgroup$
      – A.Γ.
      Jan 4 at 13:45










    • $begingroup$
      Correct, thank you for spotting that @Callus and @A.Γ.! Will update answer shortly.
      $endgroup$
      – aghostinthefigures
      Jan 4 at 13:48








    2




    2




    $begingroup$
    This is not language I'm familiar with, but wouldn't $ab^T$ always be rank $1$, so only rank $1$ matrices can be represented this way?
    $endgroup$
    – Callus
    Jan 4 at 13:38




    $begingroup$
    This is not language I'm familiar with, but wouldn't $ab^T$ always be rank $1$, so only rank $1$ matrices can be represented this way?
    $endgroup$
    – Callus
    Jan 4 at 13:38




    2




    2




    $begingroup$
    @Callus I guess it was meant that any matrix could be represented as a span of dyadic matrices.
    $endgroup$
    – A.Γ.
    Jan 4 at 13:45




    $begingroup$
    @Callus I guess it was meant that any matrix could be represented as a span of dyadic matrices.
    $endgroup$
    – A.Γ.
    Jan 4 at 13:45












    $begingroup$
    Correct, thank you for spotting that @Callus and @A.Γ.! Will update answer shortly.
    $endgroup$
    – aghostinthefigures
    Jan 4 at 13:48




    $begingroup$
    Correct, thank you for spotting that @Callus and @A.Γ.! Will update answer shortly.
    $endgroup$
    – aghostinthefigures
    Jan 4 at 13:48











    0












    $begingroup$

    The columns of $mathbf{U}$ tell you what happens to the coordinate vectors $hat{e}_1,hat{e}_2,hat{e}_3$. For example, if the first column is $[a,b,c]^T$, then $mathbf{U}hat{e}_1 = ahat{e}_1 + bhat{e}_2 + chat{e}_3$.



    The matrix $mathbf{U}'$ is the matrix that behaves the same way on the rotated coordinate basis $hat{f}_i = mathbf{R}hat{e}_i$. This is because $mathbf{R}^T = mathbf{R}^{-1}$ so for example
    $$begin{align*}
    mathbf{U}'hat{f}_1 &= mathbf{R}mathbf{U}mathbf{R}^Tmathbf{R}hat{e}_1 \
    &= mathbf{R}left(mathbf{U}hat{e}_1right) \
    &= mathbf{R}(ahat{e}_1 + bhat{e}_2 + chat{e}_3) \
    &= amathbf{R}hat{e}_1 + bmathbf{R}hat{e}_2 + cmathbf{R}hat{e}_3 \
    &= ahat{f}_1 + bhat{f}_2 + chat{f}_3
    end{align*}
    $$






    share|cite|improve this answer









    $endgroup$


















      0












      $begingroup$

      The columns of $mathbf{U}$ tell you what happens to the coordinate vectors $hat{e}_1,hat{e}_2,hat{e}_3$. For example, if the first column is $[a,b,c]^T$, then $mathbf{U}hat{e}_1 = ahat{e}_1 + bhat{e}_2 + chat{e}_3$.



      The matrix $mathbf{U}'$ is the matrix that behaves the same way on the rotated coordinate basis $hat{f}_i = mathbf{R}hat{e}_i$. This is because $mathbf{R}^T = mathbf{R}^{-1}$ so for example
      $$begin{align*}
      mathbf{U}'hat{f}_1 &= mathbf{R}mathbf{U}mathbf{R}^Tmathbf{R}hat{e}_1 \
      &= mathbf{R}left(mathbf{U}hat{e}_1right) \
      &= mathbf{R}(ahat{e}_1 + bhat{e}_2 + chat{e}_3) \
      &= amathbf{R}hat{e}_1 + bmathbf{R}hat{e}_2 + cmathbf{R}hat{e}_3 \
      &= ahat{f}_1 + bhat{f}_2 + chat{f}_3
      end{align*}
      $$






      share|cite|improve this answer









      $endgroup$
















        0












        0








        0





        $begingroup$

        The columns of $mathbf{U}$ tell you what happens to the coordinate vectors $hat{e}_1,hat{e}_2,hat{e}_3$. For example, if the first column is $[a,b,c]^T$, then $mathbf{U}hat{e}_1 = ahat{e}_1 + bhat{e}_2 + chat{e}_3$.



        The matrix $mathbf{U}'$ is the matrix that behaves the same way on the rotated coordinate basis $hat{f}_i = mathbf{R}hat{e}_i$. This is because $mathbf{R}^T = mathbf{R}^{-1}$ so for example
        $$begin{align*}
        mathbf{U}'hat{f}_1 &= mathbf{R}mathbf{U}mathbf{R}^Tmathbf{R}hat{e}_1 \
        &= mathbf{R}left(mathbf{U}hat{e}_1right) \
        &= mathbf{R}(ahat{e}_1 + bhat{e}_2 + chat{e}_3) \
        &= amathbf{R}hat{e}_1 + bmathbf{R}hat{e}_2 + cmathbf{R}hat{e}_3 \
        &= ahat{f}_1 + bhat{f}_2 + chat{f}_3
        end{align*}
        $$






        share|cite|improve this answer









        $endgroup$



        The columns of $mathbf{U}$ tell you what happens to the coordinate vectors $hat{e}_1,hat{e}_2,hat{e}_3$. For example, if the first column is $[a,b,c]^T$, then $mathbf{U}hat{e}_1 = ahat{e}_1 + bhat{e}_2 + chat{e}_3$.



        The matrix $mathbf{U}'$ is the matrix that behaves the same way on the rotated coordinate basis $hat{f}_i = mathbf{R}hat{e}_i$. This is because $mathbf{R}^T = mathbf{R}^{-1}$ so for example
        $$begin{align*}
        mathbf{U}'hat{f}_1 &= mathbf{R}mathbf{U}mathbf{R}^Tmathbf{R}hat{e}_1 \
        &= mathbf{R}left(mathbf{U}hat{e}_1right) \
        &= mathbf{R}(ahat{e}_1 + bhat{e}_2 + chat{e}_3) \
        &= amathbf{R}hat{e}_1 + bmathbf{R}hat{e}_2 + cmathbf{R}hat{e}_3 \
        &= ahat{f}_1 + bhat{f}_2 + chat{f}_3
        end{align*}
        $$







        share|cite|improve this answer












        share|cite|improve this answer



        share|cite|improve this answer










        answered Jan 4 at 13:35









        CallusCallus

        4,403922




        4,403922






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to Mathematics Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            Use MathJax to format equations. MathJax reference.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3061638%2fthe-difference-between-applying-a-rotation-matrix-to-a-vector-points-and-to-a%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Human spaceflight

            Can not write log (Is /dev/pts mounted?) - openpty in Ubuntu-on-Windows?

            File:DeusFollowingSea.jpg