W Randolph Franklin home page
... (old version)
ComputerGraphicsFall2009/ home page Login


Homework 6 Solutions (Answers in BLUE)

This has lots of little math questions based on the lecture. They mostly require thinking, not just plugging in.

1. (1 pt) Write the 4x4 homogeneous matrix for a projection onto the

  viewplane {$x+2y+3z=6$} with the center of projection at (0,0,0).


  x/6+1/3y+z/2=1 {$\begin{pmatrix}1&0&0&0\\0&1&0&0\\0&0&1&0\\1/6&1/3&1/2&0 \end{pmatrix}$} 

2. (1 pt) Write the 4x4 homogeneous matrix for a projection onto the

  viewplane {$z=0$} with the center of projection at (-1,0,0).

  COP and Viewplane are on the same plane. It is not possible

3. (1 pt) Write the 4x4 homogeneous matrix for a uniform scale by 3

  followed by a 3D translation by (1,1,1).

  {$\begin{pmatrix}3&0&0&1\\0&3&0&1\\0&0&3&1\\0&0&0&1 \end{pmatrix}$} 

4. (2 pt) Write the 4x4 homogeneous matrix for a 3D translation by

  (1,1,1) followed by a uniform scale by 3.

  Matrix=Scale(p+translate)  {$\begin{pmatrix}3&0&0&3\\0&3&0&3\\0&0&3&3\\0&0&0&1 \end{pmatrix}$} 

5. (1 pt) Normalize the 3D Cartesian vector (1,2,3).

    {$\hat{a}=\left(\frac{1}{\sqrt{14}},\frac{2}{\sqrt{14}},\frac{3}{\sqrt{14}}\right)$}.

6. (2 pt) Write the vector equation for rotating points by

  {$180^\circ$} about the axis (3,0,4).

  {$${\begin{eqnarray}p'& =& (a \cdot p) \, a + (p - (a \cdot p)  a)\cos \theta+ (a \times p)\, \sin \theta\\ &=& p \cos \theta + (a \cdot p)\,  a (1-\cos \theta) + (a \times p) \,\sin \theta\end{eqnarray}} $$} substitute for {$\theta = 180$} a=(1,2,3) p=-p+a.p(2a)    

7. (1 pt) What does the point (0,2,0) rotate to?

  Substitute in the above equation p= (0,-2,0)

8. (1 pt) If {$a=(4,5,6)$} then write {$a\cdot p a$} as a matrix

  depending on {$a$} times {$p$}.

  subsitute in {$$\left(\begin{array}{ccc} {a_1} ^2 & a_1 a_2  &  a_1 a_3 \\  a_1 a_2   & {a_2} ^2  &   a_2 a_3 \\  a_1 a_3   &  a_2 a_3  &  {a_3} ^2 \\ \end{array}\right) $$} to get {$$\left(\begin{array}{ccc} 16&20&24\\  20&25&30\\  24&30&36\\ \end{array}\right) $$}

9. (1 pt) Write {$a\times p$} ditto.

Subsitute in this matrix {$$\left(\begin{array}{ccc} 0 & - a_3 & a_2 \\ a_3 & 0 & - a_1 \\ - a_2 & a_1 & 0 \\ \end{array}\right) $$} to get {$$\left(\begin{array}{ccc} 0 & -6 & 5 \\ 6 & 0 & -4 \\ - 5 & 4 & 0 \\ \end{array}\right) $$}

10. This

  {$M=\begin{pmatrix}.6&0&.8\\0&\color{red}{0}&0\\.8&0&-.6\end{pmatrix} $}
  is not a rotation matrix.


  a. (1 pt) Give 2 rules for being a rotation matrix that it violates.

       1.) The determinant should be '1' 2.) The second column should have a non-zero element 	

  b. (1 pt) Change {$m_{2,2}$}, highlighted in red above, to make
    {$M$} a rotation matrix.
       {$$ \color{blue}{p}' = \color{blue}{M_{2,2}}=-1 $$}

11. (2 pt) This

  {$M=\begin{pmatrix}-1&0&0\\0&1&0\\0&0&-1\end{pmatrix} $} is a
  rotation matrix.  What are the normalized axis and angle of
  rotation?

     Subsititute in {$$\color{blue}{\theta  = \arccos \left({\frac{m_{11}+m_{22}+m_{33}-1}{2}}\right)}$$} {$\theta$}=180

   Normalized axis can be found knowing the angle and the roation matrix or by finding the eigenvalues. Normalized axis is 'y' axis.