3D transformations 
FCC Graficación CAD/CAM3D TransformationsContents1. Translation2. Scaling3. Rotation4. Other Transformations1. TranslationxyzTxTzTy(x,y,z))',','(zyx110001000100011'''zyxTTTzyxTzzTyyTxxzyxzyxTPP'SPP'2. Scaling110000000000001'''zyxSSSzyxSzzSyySxxzyxzyxxyz(x,y,z) ) ' , ' , ' ( z y x ∴scaling uniform-non Otherwise,scaling UniformzyxSSSxyz),,(FFFzyxxyzxyzxyz.1000100010001 and,1000000000000,1000100010001where]][][['11FFFzyxFFFxxxTSSSSxxxTPTSTPRelative Scaling3. Rotation2D Rotation)','(yx),(yxqrr ) ' , ' ( y x ) , ( y x qrr),(RRyxRotation about z-axis is implicit !!!)',','('zyxP),,(zyxPqrrxyzzzyxyyxx'cossin'sincos'∴11000010000cossin00sincos1'''zyxzyxPRPZ'By symmetry,xyz10000cossin00sincos00001where,'XXRPRPxyz10000cos0sin00100sin0coswhere,'YYRPRPcossin'sincos''zyzzyyxxcossin''sincos'zxzyyzxxxyzu(x1, y1, z1)(x2, y2, z2)Rotation about an arbitrary axisBasic idea1. Translatethe object so thatthe rotation axis passes through the origin.2. Rotatethe object so thatthe rotation axis coincides with one of the coordinate axis.3. Perform the specified rotation.4. R-15. T-1TR1,,,,),,(),,(222222121212121212cbaVzcVybVxazyxVzzzyyyxxxcbaVVuzzyyxxVzyxStep 1: Translationxyzu = (a, b, c)(x1, y1, z1)(x2, y2, z2)u1000100010001111zyxTStep 2: Aligning uwith z-axisxyzu = (a, b, c)a(0, b, c) = u'(0, 0, 1) = uzxyzu''= (a, 0, d)da100000000001)(dcdbdbdcRx)(1000'sinsin|||'|'22bucbuuuuucbuuuuuuxzyxzxzxz uxdcuuuucbbbcbzz|||'|'cossinsin2222 dxyzu''= (a, 0, d)dauy(0, 0, 1) = uzbxyzaaudauuuuuuuuuuuyzyxzyzyzsin)(1000''sinsin|||''|''∴100000001000)(daadRyduuuuzz|||''|''cos≡1≡1111)()()()(yxxyRRRRRR∴In Step 2,for later useStep 3: Rotate about z-axis by a given anglexyzq1000010000cossin00sincos)(zRStep 4: [R-1] = [Rx(a)-1][Ry(b)-1]Step 5: [T-1]∴In summary,PTRRRRRTPxyzyx)()()()()('1114. Concatenation Thesuccessiveapplicationofanumberoftransformationscanbeachievedwithasingletransformationmatrix,theconcatenationofthesequence.SupposetwotransformationsT1andT2aretobeappliedsuccessively.ThesameeffectcanbeachievedbytheapplicationofasingletransformationT3,whichissimplytheproductofthematricesT1andT2.Thatis:The point (x, y, z) is transformed into (x’, y’, z’) by T1:[ x’ y’ z’ 1 ] = [ x y z 1 ] T1(1)The point (x’’, y’’, z’’) is generated by applying T2:[ x’’ y’’ z’’ 1 ] = [ x’ y’ z’ 1 ] T2(2)Substituting (1) in (2) gives:[ x’’ y’’ z’’ 1 ] = ([ x y z 1 ] T1)T2 = [ x y z 1 ] (T1T2)Theorderofapplicationofthetransformationsmustbepreservedwhenthetransformationmatricesaremultipliedtogether.