二维旋转矩阵

二维旋转矩阵
二维旋转是绕着某一个点进行旋转。如上图所示,蓝色线绕着O点旋转θ\theta角度到绿色线。
假设蓝色线为ll绿色线为ll'
x=rcosϕx=rcos(ϕ+θ)=rcosϕcosθrsinϕsinθ=xcosθysinθx=rcos\phi \quad x'=rcos(\phi+\theta)=rcos\phi cos\theta-rsin\phi sin\theta=xcos\theta-ysin\thetay=sinϕy=rsin(ϕ+θ)=rsinϕcosθ+rcosϕsinθ=xsinθ+ycosθy=sin\phi \quad y'=rsin(\phi+\theta)=rsin\phi cos\theta+rcos\phi sin\theta=xsin\theta+ycos\theta

写成矩阵的形式是:
[xy]=[cosθsinθsinθcosθ][xy]\left[\begin{array}{l} x^{\prime} \\ y^{\prime} \end{array}\right]=\left[\begin{array}{ll} \cos \theta & -\sin \theta \\ \sin \theta & \cos \theta \end{array}\right] *\left[\begin{array}{l} x \\ y \end{array}\right]

相关文章: