CS4620 PA6 Animation

Out: Friday November 13, 2015

Due: Friday November 20, 2015 at 11:59pm

Written Problem 1 - Interpolating in 2D

Below are pictures of a square object (rotated by 45 degrees and with its edges marked so you can tell them apart) under three pairs of linear transformations. Each small cell has size 0.5 (e.g. both vertical and horizontal coordinates range from -1.5 to 1.5). For each pair (keeping in mind that transformations are with respect to initial figure):
  1. Write the 2x2 transformation matrices for each pose; call them $M_{0}$ and $M_{1}$.
  2. Write the matrix $M_{0.5}^{\text{lin}}$ by linearly interpolating elementwise halfway between $M_0$ and $M_1$.
  3. Write each of these two poses in the form $M_i = R_iS_i$, where $R_i$ is a rotation and $S_i$ is a symmetric matrix with positive entries on the diagonal.
  4. Use this decomposition to interpolate a matrix $M_{0.5}^{\text{pol}}$ that is halfway between $M_0$ and $M_1$.
  5. Draw the two intermediate states of the object (you can export a PDF and draw on it if you want).
a6anim_fig.png

Written Problem 2 - Interpolating 3D Rotations

Be sure to use the egl.math.Quat class to convert between quaternions and rotation matrices.
  1. Write down the quaternion $q_1$ that corresponds to the identity rotation and the quaternion $q_2$ that corresponds to a rotation of 180 degrees around the y axis.
  2. Using the formula for spherical linear interpolation, generate the quaternion $q_3$ that is one-sixth of the way from $q_1$ to $q_2$. What are the axis and angle of the rotation $q_3$ represents?
  3. Convert $q_3$ to a 3x3 rotation matrix $M(q_3)$. Verify that starting with the identity and applying this matrix 6 times results in the rotation corresponding to $q_2$.