CS 520 Advanced Computer Graphics


Homework 1
Due Feb. 2, 2009 ( Mon )

  1. ( 20 points ) Suppose vectors A = ( 1, 2, 3, 0 )T, and B = ( 3, 2, 1, 0 )T. Make use of the Math utility programs at
      /pool/u/class/cs520/VrMath
    to find the following.
    1. A.B
    2. AxB
    3. A+B
    4. The angle between A and B
    5. Find the composite matrix M of the resultant transformation of:
      1. rotation about x-axis by 30 degrees,
      2. magnification about y-axis by a factor of 2,
      3. translation by vector A above.
    6. Find M-1 of e.
    7. Check that M.M-1 is the identity matrix.

  2. ( 10 points ) Write a program that finds the knot vector ( u0, ..., un-1 ) of a B-spline. It asks for "number of control points" and "degree of spline" as inputs and prints out the knot vector.

  3. ( 10 points ) Write a program that plots all the blending functions of degree 3 ( m = 4 ) on the same screen.

  4. ( 30 points ) Write a program that uses B-splines and some control points to generate a profile and then use the profile and surface of revolution to generate a graphic chess piece like the one shown in class notes. ( You can choose any chess piece. You can gain extra credit by doing more than one piece. )

    Make a demo to the instructor before or after a class or during the office hours. Progams must be able to be compiled and run in the machines of the lab.