Game Development Reference

In-Depth Information

Applying Equation (6.19) and solving for cos 3
θ
gives us

p
′

−

q

−

q

2

−

q

cos 3

θ

=

=

=

.

(6.22)

3

2

m

p

3

27

′

3

−

−

2

3

Since

, thereby guaranteeing that

the right side of Equation (6.22) is always less than 1 in absolute value. The in-

verse cosine is thus defined, and we can solve for
θ
to arrive at

′ >

0

, Equation (6.16) implies that

q

′

<−

p

′

D

′

1
cos

3

−

q

−

1

θ

=

.

(6.23)

−

p

′

3

Therefore, one solution to Equation (6.9) is given by

x

=

2

mθ

cos

=

2

−

p θ

′

cos

.

(6.24)

1

(

)

(

)

Since

cos 3

θ k

+

2

=

cos 3

θ

for any integer
k
, we can write

′

1

−

q

2

π

−

1

θ

=

cos

−

k

.

(6.25)

k

3

3

′

3

−

p

Distinct values of cos
θ
are generated by choosing three values for
k
that are

congruent to 0, 1, and 2 modulo 3. Using

=±

1

, we can express the remaining

k

two solutions to Equation (6.9) as

2

π

′

x

=−

2

p θ

cos

+

2

3

2

π

′

.

(6.26)

x

=−

2

p θ

cos

−

3

3

6.1.3 Quartic Polynomials

A quartic equation having the form

4

3

2

t

++++=

at

bt

ct

d

0

(6.27)

(where again we have performed any necessary division to produce a leading

coefficient of 1) can be shifted to eliminate the cubic term by making the

substitution

Search Nedrilad ::

Custom Search