Angel and Shreiner: Interactive Computer Graphics, Seventh
Edition
Chapter 4 Solutions
4.1 If the scaling matrix is uniform then
RS =RS(α, α, α) = αR=SR
Consider Rx(θ), if we multiply and use the standard trigonometric
4.4 Translation
T=
1 0 x
0 1 y
0 0 1
Rotation
cos θsin θ0
0 0 1
1
The general form of a homogeneous coordinate transformation matrix for
working with two dimensional graphics is
a b c
4.5 There are 12 degrees of freedom in the three–dimensional affine
transformation. Consider a point p= [x, y, z, 1]Tthat is transformed to
In two dimensions, there are 6 degrees of freedom in Mbut pand phave
only xand ycomponents. Hence if we know 3 points both before and after
4.6 The signs on the sine terms in the rotation matrices must all be
changed. You can check this result by noting that a positive 90 degree
rotation about z in a right–handed system brings the positive x axis to the
4.7 It is easy to show by simply multiplying the matrices that the
concatenation of two rotations yields a rotation and that the concatenation
of two translations yields a translation. If we look at the product of a
rotation and a translation, we find that the left three columns of RT are
2
4.8 A simple sequence can be obtained by considering a square centered at
4.9 If we do a translation by -h we convert the problem to reflection about
a line passing through the origin. From m we can find an angle by which
4.10 We can start with a rotation about any of the axes. The next rotation
can be about either of the other two axes and the third can be either
4.11 The most sensible place to put the shear is second so that the instance
transformation becomes I=TRHS. We can see that this order makes
sense if we consider a cube centered at the origin whose sides are aligned
4.12 A plane can be described by the equation ax +by +cz +d= 0.If we
define the two homogeneous coordinate column matrices
4.13 A vertex in a three-dimensional system is a location. It has no other
4.14
R=Rz(θz)Ry(θy)Rx(θx) =
cos θycos θzcos θzsin θxsin θycos θxsin θzcos θxcos θzsin θy+ sin θxsin θz0
3
4.15 Points, vectors and scalars.
4.16 Consider the homogeneous recurrence
y(k) + an1y(k1) + +a0y(kn) = 0,
i=0
where the constants {ci}are determined by the initial conditions. A
virtually identical result holds for linear differential equations. We can
regard the sequences {zi(k)}i= 1, .., n as basis vectors and thus the
i=0
Thus {u(k)}acts as a point and any solution is another point that is
obtained by adding a vector to it.
4.18 It would seem that the matrix R=Rx(45)Ry(45) would be correct
but it is not. After the first rotation by 45 degrees, the resulting side view
4.19 One test is to use the first three vertices to find the equation of the
plane ax +by +cz +d= 0. Although there are four coefficients in the
4
4.20 If they are collinear, one vertex is a linear combination of the other
two and the determinant of the matrix
x1x2x3
4.21 Although we will have the same number of degrees of freedom in the
objects we produce, the class of objects will be very different. For example
4.23 The vector a=u×vis orthogonal to uand v. The vector b=u×ais
4.24 The determinant of the matrix is 1 + θ2. Repeated multiplications by
this matrix increase the determinant so the resulting operation becomes
further and further from a rotation matrix causing the point to become
further and further from the origin. One remedy is to use the matrix
1θ0 0
5
4.26 Using the notation sin θx=sx, cos θx=cx,and likewise for θyand θz,
we find
cyczcyszsy0
czsxsy+cxszsxsysz+czczsxcy0
4.30 Possible reasons include (1) object-oriented systems are slower, (2)
users are often comfortable working in world coordinates with higher-level
4.31 (a) ¿1 (b) ¿0 and ¡1
4.32 Expanding repeatedly as in the hint
P=α1P1+α2P2+=α1P1+ (α2+α1α1)P2+
6
7