Reflection.decomposed
- Reflection.decomposed()[source]
Decompose the Transformation into its components.
- Returns
compas.geometry.Scale
– The scale component of the current transformation.compas.geometry.Shear
– The shear component of the current transformation.compas.geometry.Rotation
– The rotation component of the current transformation.compas.geometry.Translation
– The translation component of the current transformation.compas.geometry.Projection
– The projection component of the current transformation.
Examples
>>> from compas.geometry import Scale, Translation, Rotation >>> trans1 = [1, 2, 3] >>> angle1 = [-2.142, 1.141, -0.142] >>> scale1 = [0.123, 2, 0.5] >>> T1 = Translation.from_vector(trans1) >>> R1 = Rotation.from_euler_angles(angle1) >>> S1 = Scale.from_factors(scale1) >>> M = T1 * R1 * S1 >>> S, H, R, T, P = M.decomposed() >>> S1 == S True >>> R1 == R True >>> T1 == T True