Skip to content

Geometric Transformation for Convex Hull Reorientation

Problem Statement:

Reorient a convex hull (specifically a 3D rectangular prism defined by its vertices) in a global coordinate system such that:

  1. The origin of the local coordinate system remains invariant (no translation of the origin).
  2. A specific vector in the local frame, representing the recurrence mapping from Cin(0,0) to Cout(0,0) and defined as [00k]\begin{bmatrix} 0 \\ 0 \\ k \end{bmatrix}, is mapped to the vector [0k0]\begin{bmatrix} 0 \\ k \\ 0 \end{bmatrix} in the global frame.
  3. All coordinates of the transformed vertices of the convex hull are non-negative.

The original rectangular prism is defined by the vertices: v0: (0, 0, 0) v1: (m, 0, 0) v2: (m, 0, k) v3: (0, 0, k) v4: (0, n, k) v5: (0, n, 0) v6: (m, n, 0) v7: (m, n, k)

Solution:

The required transformation can be achieved by a single rotation matrix that is a result of two sequential rotations: a -90 degree rotation around the x-axis followed by a -90 degree rotation around the y-axis.

1. Rotation around the x-axis by -90 degrees (Rx(90)R_x(-90^\circ)):

The rotation matrix is:

Rx(90)=[1000cos(90)sin(90)0sin(90)cos(90)]=[100001010]R_x(-90^\circ) = \begin{bmatrix} 1 & 0 & 0 \\ 0 & \cos(-90^\circ) & -\sin(-90^\circ) \\ 0 & \sin(-90^\circ) & \cos(-90^\circ) \end{bmatrix} = \begin{bmatrix} 1 & 0 & 0 \\ 0 & 0 & 1 \\ 0 & -1 & 0 \end{bmatrix}

2. Rotation around the y-axis by -90 degrees (Ry(90)R_y(-90^\circ)):

The rotation matrix is:

Ry(90)=[cos(90)0sin(90)010sin(90)0cos(90)]=[001010100]R_y(-90^\circ) = \begin{bmatrix} \cos(-90^\circ) & 0 & \sin(-90^\circ) \\ 0 & 1 & 0 \\ -\sin(-90^\circ) & 0 & \cos(-90^\circ) \end{bmatrix} = \begin{bmatrix} 0 & 0 & -1 \\ 0 & 1 & 0 \\ 1 & 0 & 0 \end{bmatrix}

3. Combined Rotation Matrix (RR):

The combined rotation is obtained by multiplying the second rotation matrix by the first:

R=Ry(90)Rx(90)=[001010100][100001010]=[010001100]R = R_y(-90^\circ) \cdot R_x(-90^\circ) = \begin{bmatrix} 0 & 0 & -1 \\ 0 & 1 & 0 \\ 1 & 0 & 0 \end{bmatrix} \begin{bmatrix} 1 & 0 & 0 \\ 0 & 0 & 1 \\ 0 & -1 & 0 \end{bmatrix} = \begin{bmatrix} 0 & 1 & 0 \\ 0 & 0 & 1 \\ 1 & 0 & 0 \end{bmatrix}

4. Verification of Synthesis Vector Mapping:

Applying the rotation matrix RR to the synthesis vector [00k]\begin{bmatrix} 0 \\ 0 \\ k \end{bmatrix}:

R[00k]=[010001100][00k]=[00+10+0k00+00+1k10+00+0k]=[0k0]R \begin{bmatrix} 0 \\ 0 \\ k \end{bmatrix} = \begin{bmatrix} 0 & 1 & 0 \\ 0 & 0 & 1 \\ 1 & 0 & 0 \end{bmatrix} \begin{bmatrix} 0 \\ 0 \\ k \end{bmatrix} = \begin{bmatrix} 0 \cdot 0 + 1 \cdot 0 + 0 \cdot k \\ 0 \cdot 0 + 0 \cdot 0 + 1 \cdot k \\ 1 \cdot 0 + 0 \cdot 0 + 0 \cdot k \end{bmatrix} = \begin{bmatrix} 0 \\ k \\ 0 \end{bmatrix}

The synthesis vector is mapped as required.

5. Transformation of Vertices:

Applying the rotation matrix RR to each vertex of the original prism:

v0: (0, 0, 0) -> v0’ = (0,0,0)(0, 0, 0) v1: (m, 0, 0) -> v1’ = (0,0,m)(0, 0, m) v2: (m, 0, k) -> v2’ = (0,k,m)(0, k, m) v3: (0, 0, k) -> v3’ = (0,k,0)(0, k, 0) v4: (0, n, k) -> v4’ = (n,k,0)(n, k, 0) v5: (0, n, 0) -> v5’ = (n,0,0)(n, 0, 0) v6: (m, n, 0) -> v6’ = (n,0,m)(n, 0, m) v7: (m, n, k) -> v7’ = (n,k,m)(n, k, m)

6. Positive Coordinate Constraint:

Assuming the dimensions m,n,km, n, k are positive, all the transformed vertices have non-negative coordinates.

Conclusion:

The single rotation matrix that achieves the desired reorientation, maps the synthesis vector (0,0,k)(0, 0, k) to (0,k,0)(0, k, 0), keeps the origin invariant, and results in all non-negative coordinates for the transformed rectangular prism is:

R=[010001100]R = \begin{bmatrix} 0 & 1 & 0 \\ 0 & 0 & 1 \\ 1 & 0 & 0 \end{bmatrix}

This rotation corresponds to a specific reorientation of the coordinate axes. The original x-axis becomes the new z-axis, the original y-axis becomes the new x-axis, and the original z-axis becomes the new y-axis.