Starting from:

$25

CS70-Disc 05b Solved

1           Interpol Warning
(1)   Linear Equations.

Let P(x) = a3x3+a2x2+a1x1+a0, and take four points into the equation, we have

 

Thus, solving the linear equation, we obtain  So the P(x) = 5x3 + 1x2 + −3x1 + 2.

(2)   Lagrange Interpolation.

 

The final P(x) is equal to:

1 ∗ ∆−1 + 2 ∗ ∆0 + 5 ∗ ∆1 + 40 ∗ ∆2 = 5x3 + 1x2 + −3x1 + 2

which is same as method one.

1

2           Secrets in the United Nations
(a)    Here are two cases:

(1)   n countries =⇒ n points could solve the coefficient of n-1 degree polynomial.

(2)   m counties + Secretary General =⇒ give Secretary General n - m points, then the situation is same as case (1).

So design a polynomial of degree n and produce n + (n - m) number of points, first part of n points attributes to each country and second part of (n - m) points attributes Secretary General.

(b)   Devine one polynomial degree of n for each country and Secretary General, and n polynomial degree of k-1 for all countries.

(1)   For each country and Secretary General, the scheme shall be the same. And denotes that polynomial as P(x). Say each country shall have one point value, first corresponding to P(1), sec to P(2), etc.

(2)   But for each country to obtain its attributed point value, design a polynomial degree of k-1 and generate k points for each representative, denoted as Q(x). We could set Q(0) = P(i), i is the order of that country.

3           Erasure Warm-Up
(1)   Minimum q : 7

(2)   Maximum degree of polynomial : 3 Page 2

More products