Problem
S-1. Suppose everything is exactly as in Example
, except that the sphere is centered at
(while still being of radius 3). For the
same
, what is the brightness of the pixel there?
Problem
S-2. Using Phong shading, find the brightness of the pixel
at
on the viewplane
as seen from
the viewpoint
, if the surface is the
sphere of radius 5 centered at
and the
light source is in the direction
.
Problem
S-3. Suppose everything is exactly as in Example
,
except that the object is a plane piece of paper with equation
. For
as before, what is the
brightness of the pixel there? Does it depend on the choice of
? (For the normal, there isn't any ``outward'' direction; instead,
choose the direction that is on the same side of the paper as the
light source.)
Problem
S-4. Let the viewpoint be at the origin, let the viewplane
be the
plane, and let
s
. Suppose the object is the sphere of
radius 10 centered at
. What is the
brightness of the pixel at
? (Or is it
in shadow?)
Problem
S-5. In Example
, consider the same
ray but suppose the sphere is shiny (specular reflection). Find
parametric equations for the reflected ray.
Method: For the reflected ray, think separately about its
direction and about a point through which it goes; then use the
point-direction parametric form of a line. For the direction,
first find a direction vector for the incoming ray. A fact,
perhaps to be derived later in the course, is
that the matrix of a reflection in a mirror through the origin
with unit normal
n (as a column vector) is
n n
;
note that the column times a row is
; and so a
column vector
v has reflected image
n n
v
v
n n
v
v
n
n
v
v
n
v
n. Use this information
to reflect the path direction vector in the mirror
through the origin with appropriate normal, obtaining the direction
of the reflected ray. (Since this part of the calculation is
with vectors rather than points, you don't have to worry about
where the mirror is, but only the direction of its normal.)