أخر الاخبار

Example Two Dimension Rotation

Example Two Dimension Rotation


 Example 1 / rotate the line P1(1,6) and P2(5,1) anticlockwise 90 degrees.

sol//



Example 2 /Rotate the square (3,2),(5,2),(3,4),(5,4) counterclockwise with Ǿ =45 around the point (3,2).

sol //

    TX=3 , TY=2   Translation

    Point(3,2)                                       

    X1new =X1-TX=3-3=0

    Y1new Y1-TY=2-2=0           (0,0)                                       

  Point(5,2)

    X2new =X1-TX=5-3=2

    Y2new Y1-TY=2-2=0   (2,0)

 Point(5,4)

    X3new =X1-TX=5-3=2

    Y3new Y1-TY=4-2=2    (2,2)

 Point(3,4)

    X4new =X1-TX=3-3=0

    Y4new Y1-TY=4-2=2   (0,2)

Rotation :  Ǿ =45

sin(45)=0.85 , cos(45)=0.52

XP2=XP1*cos Ǿ -YP1* sin Ǿ

YP2=YP1*cos Ǿ +XP1* sin Ǿ

point(0,0)

X1new=0*0.52-0*0.85=0

Y1new=0*0.52+0*0.85=0     (0,0)

point(2,0)

X2new=2*0.52-0*0.85=1.04

Y2new=0*0.52+2*0.85=1.7    (1.04,1.7)

point(2,2)

X3new=2*0.52-2*0.85=-0.66

Y3new=2*0.52+2*0.85=2.74    (-0.66,2.74)

point(0,2)

X4new=0*0.52-2*0.85=-1.7

Y4new=2*0.52+0*0.85=1.04    (-1.7,1.04)

Back Translation

 TX=3 ,TY=2

 Point(0,0)                                       

    X1new =X1+TX=0+3=3

    Y1new Y1+TY=0+2=2         (3,2)                                       

  Point(1.04,1.7)

     X2new =X1+TX=1.04+3=4.04

    Y2new Y1+TY=1.7+2=3.7    (4.04,3.7)

 Point(-0.66,2.74)

    X3new =X1+TX=-0.66+3=2.34

    Y3new Y1+TY=2.74+2=4.74    (2.34,4.74)

 Point(-1.7,1.04)

     X4new =X1+TX=-1.7+3=1.3

    Y4new Y1+TY=1.04+2=3.04   (1.3,3.04)



Example 3/: Performa counterclockwise 45 rotation of triangle A (2, 3), B (5,5) and C(4,3) about point (2,3).

sol //

  TX=2 , TY=3   Translation

    Point(2,3)                                       

    X1new =X1-TX=2-2=0

    Y1new Y1-TY=3-3=0           (0,0)                                       

  Point(4,3)

    X2new =X1-TX=4-2=2

    Y2new Y1-TY=3-3=0   (2,0)

 Point(5,5)

    X3new =X1-TX=5-2=3

    Y3new Y1-TY=5-3=2    (3,2)

Rotation :  Ǿ =45

sin(45)=0.85 , cos(45)=0.52

XP2=XP1*cos Ǿ -YP1* sin Ǿ

YP2=YP1*cos Ǿ +XP1* sin Ǿ

point(0,0)

X1new=0*0.52-0*0.85=0

Y1new=0*0.52+0*0.85=0     (0,0)

point(3,2)

X2new=3*0.52-2*0.85=-0.14

Y2new=2*0.52+3*0.85=3.59    (-0.14,3.59)

 point(2,0)

X3new=2*0.52-0*0.85=-1.04

Y3new=0*0.52+2*0.85=1.7    (1.04,1.7)

Back Translation

 TX=2 ,TY=3

 Point(0,0)                                       

    X1new =X1+TX=0+2=2

    Y1new Y1+TY=0+3=3        (2,3)                                       

  Point(-0.14,3.59)

     X2new =X1+TX=-0.14+2=1.86

    Y2new Y1+TY=3.59+3=6.59    (1.86,6.59)

  Point(1.04,1.7)

     X2new =X1+TX=1.04+2=3.04

    Y2new Y1+TY=1.7+3=4.7    (3.04,4.7)



 Example 4 /- Rotate the object defined by (43,88), (84,50),(66,72) in rotating at anticlockwise by angle 53 then scale it with scaling factor Sx=1, Sy=2 where (43,88) is the fixed point?

sol//

Rotation :  Ǿ =53

sin(53)=0.8 , cos(53)=0.6

XP2=XP1*cos Ǿ -YP1* sin Ǿ

YP2=YP1*cos Ǿ +XP1* sin Ǿ

point(43,88)

X1new=43*0.6-88*0.8=-44.6

Y1new=88*0.6+43*0.8=87.2    (-44.6,87.2)

point(84,50)

X2new=84*0.6-50*0.8=10.4

Y2new=50*0.6+84*0.8=97.2    (10.4,97.2)

point(66,72)

X3new=66*0.6-72*0.8=-18

Y3new=72*0.6+66*0.8=96    (-18,96)

TX=43 , TY=88   Translation

    Point(-44.6,87.2)                                       

    X1new =X1-TX=10.4-43=-32.6

    Y1new Y1-TY=97.2-88=9.2          (-32.6,9.2)  

 Point(10.4,97.2)                                       

    X2new =X1-TX=-44.6-43=-87.6

    Y2new Y1-TY=87.2-88=-0.8           (-87.6,-0.8)  

 Point(-44.6,87.2)                                       

    X1new =X1-TX=-44.6-43=-87.6

    Y1new Y1-TY=87.2-88=-0.8           (-87.6,-0.8)  

 Point(-18,96)                                       

    X1new =X1-TX=-18-43=-61

    Y1new Y1-TY=96-88=8          (-61,8)  

Scaling    SX=1 , SY=2

Point(-87.6,-0,8)

X1new=-87.6*1=-87.6

Y1new=-0.8*2=-1.6    (-87.6,-1.6)

Point(-32.6,9.2)

X2new=-32.6*1=-32.6

Y2new=9.2*2=18.4    (-32.6,18.4)

Point(-61,8)

X3new=-61*1=-61

Y3new=8*2=-16   (-61,16)

Back Translation  TX=43 , TY=88

Point (-87.6,-1.6)

X1new=-87.6+43=-44.6

Y1new=-1.6+88=86.4     (-44.6,86.4)

Point  (-32.6,18.4)

X2new=-32.6+43=10.4

Y2new=18.4+88=106.4     (10.4,106.4)

Point (-61,16)

X3new=-61+43=-18

Y3new=16+88=104    (-18,104)



Example 5/ Rotate the object defined by (44,68), (104,66),(70,102) in rotating at counter-clockwise by angle 37 degrees after scaling with scale factor Sx=3, Sy=2 where (44,68) is the fixed point?

sol//


  TX=44 , TY=68   Translation

    Point(44,68)                                       

    X1new =X1-TX=44-44=0

    Y1new Y1-TY=68-68=0           (0,0)                                       

  Point(104,66)

    X2new =X1-TX=104-44=60

    Y2new Y1-TY=66-68=-2   (60,-2)

 Point(70,102)

    X3new =X1-TX=70-44=26

    Y3new Y1-TY=102-68=34    (26,34)

Scaling  SX=3 , SY=2

Point(0.0)

X1new=0*3=0

Y1new =0*2=0  (0,0)

Point(60.-2)

X2new=60*3=180

Y2new =-2*2=-4  (180,-4)

Point(26.34)

X3new=26*3=78

Y3new =34*2=68  (78,68)

Back Translation TX=44, TY=68

point(0,0)

X1new=0+44=44

Y1new=0+68=68  (44,68)

point(180,-4)

X2new=180+44=224

Y2new=-4+68=64  (224,64)

point(78,68)

X1new=78+44=122

Y1new=68+68=136  (122,136)

Rotation :  Ǿ =37

sin(37)=0.6 , cos(37)=0.8

XP2=XP1*cos Ǿ -YP1* sin Ǿ

YP2=YP1*cos Ǿ +XP1* sin Ǿ 

Point( 44,68)

X1new=44*0.8-68+0.6=-5.6

Y1new=68*0.8+44*0.6=80.8  (-5.6,80.8)

Point( 224,64)

X2new=224*0.8-64+0.6=140.8

Y2new=64*0.8+224*0.6=185.6  (140.8,185.6)

Point( 122,136)

X1new=122*0.8-136+0.6=16

Y1new=136*0.8+122*0.6=182  (16,182)




 

تعليقات



حجم الخط
+
16
-
تباعد السطور
+
2
-