The Gateway to Computer Science Excellence
First time here? Checkout the FAQ!
x
+16 votes
1.5k views

A polynomial $p(x)$ is such that $p(0) = 5, p(1) = 4, p(2) = 9$ and $p(3) = 20$. The minimum degree it should have is

  1. $1$
  2. $2$
  3. $3$
  4. $4$
asked in Set Theory & Algebra by Veteran (59.6k points)
edited by | 1.5k views

3 Answers

+31 votes
Best answer
Lets take $p(x) =  ax +b$
Now, $p(0) = 5 \implies b = 5.$

$p(1) = 4 \implies a + b = 4, a = -1$
$p(2) = 9 \implies 4a + b = 9 \implies -4 + 5 = 9$, which is false. So, degree $1$ is not possible.

Let $p(x) =$ $ax^{2}$ $+$ $bx$ $+$ $c$

$p(0) = 5 \implies c = 5$
$p(1) = 4 \implies a + b + c = 4 => a + b = -1 \quad \to(1)$
$p(2) = 9 \implies 4a + 2b + c = 9 => 2a + b = 2 \quad \to (2)$

$(2) - (1) \implies a = 3, b = -1 - 3 = -4$

$p(3) = 20 \implies 9a + 3b + c = 20, 27 -12 + 5 = 20$, equation holds.  

So, degree $2$ also will suffice.
answered by Veteran (363k points) 1 flag:
✌ Edit necessary (tusharp “P(2) in ax+b is 2a+ b”)

edited by
+33

One more very nice explanation:

http://math.stackexchange.com/a/675137/309722

For a linear polynomial $p$, you'll always have $p(n+1) - p(n)$ the same. If you write down a table
 

1      2   3     4   5
p(1) p(2) p(3) p(4) p(5)


which in your case would be this:
 

0    1    2    3   
5    4    9    20


and then write the differences $p(2) - p(1)$, $p(3) - p(2)$, etc in a row beneath, you'd get (again in your case)
 

0    1    2    3   
5    4    9    20
  -1    5   11


That new row is called the "first differences". For a linear function, the entries would all be the same. You can also write down second differences:
 

0    1    2    3   
5    4    9    20
  -1    5   11
     6    6
For a quadratic function, these second differences will all be the same. 
Your values actually all the same, so your function can be expressed as a quadratic.
+1
nice explanation !!! :)
+1
Thanks @SachinBhai
0

@SachinMIttal1 this solution fails for https://gateoverflow.in/2245/gate1997_4-4#viewbutton

IS there any special case for this to work

0
awesome.......
0
@Arjun Sir Why degree 1 is not possible ?
+1
he explained the same case that you just decalred "failed"
0
awesome explanation @sachin sir
+1
one calculation mistake in P(2) of 1 degree. P(2) = 2a+b = 9 => -2+5 =9 false.
+1 vote
(b) is the answer. we can take a generalized quadratic equation ax2 +bx+c and verify.
answered by Loyal (7.7k points)
+1 vote
Since value of P(x) seems to be decreasing b/w 0 and 1 and then 1 to 2 it is increasing. So, there must be atleast two roots (may be both real and both imaginary). Because polynomials are smooth and continous on real numbers. So, there has to be one U-turn.
answered by (173 points)
Answer:

Related questions



Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true

42,599 questions
48,599 answers
155,652 comments
63,718 users