Numerical Methods


Question 1
Consider p(s) = s^{3}+a_{2}s^{2}+a_{1}s+a_{0} with all real coefficients. It is known that its derivative {p}'(s) has no real roots. The number of real roots of {p}(s) is
A
0
B
1
C
2
D
3
GATE EC 2018   Engineering Mathematics
Question 1 Explanation: 
If p(s) has "r" real roots, then p^{\prime}(s) will have atleast "r-1^{\prime \prime} real roots.
Question 2
Starting with x = 1, the solution of the equation x^{3}+x=1, after two iterations of Newton-Raphson's method (up to two decimal places) is _________.
A
0.68
B
0.84
C
0.96
D
1
GATE EC 2017-SET-1   Engineering Mathematics
Question 2 Explanation: 
\begin{aligned} f(x)&=x^{3}+x-1 \\ f(1)&=1 \\ f^{\prime}(x)&=3 x^{2}+1 \\ f(1)&=4 \end{aligned}
By Newton-Raphson method.
\begin{aligned} x_{i+1}&=x_{i}-\frac{f\left(x_{i}\right)}{f^{\prime}\left(x_{i}\right)}\\ \text{For }x_{0}&=1, \quad x_{1}=x_{0}-\frac{f\left(x_{0}\right)}{f^{\prime}\left(x_{0}\right)}=1-\frac{1}{4}=0.75 \\ \text{For }x_{1}&=0.75 \\ x_{2} &=x_{1}-\frac{f\left(x_{1}\right)}{f^{\prime}\left(x_{1}\right)}=0.75-\frac{f(0.75)}{f^{\prime}(0.75)} \\ &=0.75-\frac{0.171875}{2.6875}=0.686 \end{aligned}


Question 3
Consider the first order initial value problem

y'=y+2x-x^{2},y(0)=1,(0\leq x\leq \infty )

with exact solution y(x)=x^{2}+e^{x}. For x = 0.1, the percentage difference between the exact solution and the solution obtained using a single iteration of the second-order Runge-Kutta method with step-size h = 0.1 is __________
A
0.06
B
0.012
C
0.6
D
0.12
GATE EC 2016-SET-3   Engineering Mathematics
Question 3 Explanation: 
\begin{aligned} \frac{d y}{d x} &=y+2 x-x^{2} \\ y(0) &=1 \quad \quad 0 \leq x \leq \infty \\ f(x, y) &=y+2 x-x^{2} \\ x_{0}=0 ; y_{0}=1 ; h &=0.1 \\ k_{1} &=h f\left(x_{0}, y_{0}\right) \\ &=0.1\left(1+2 \times 0-0^{2}\right)=0.1 \\ k_{3} &=h /\left(x_{0}+h_{1} y_{0}+k_{1}\right) \\ &=0.1\left(\left(y_{0}+k_{1}\right)+2\left(x_{0}+h\right)-\left(x_{0}+h\right)^{2}\right) \\ &\left.=0.1(11+0.1)+2(0.1)-(0.1)^{2}\right) \\ &=0.129\\ y_{1} &=y_{0}+\frac{1}{2}\left(k_{1}+k_{2}\right) \\ &=1+\frac{1}{2}(0.1+0.129) \\ &=1.1145 \\ \text { Exact solution } y(x) &=x^{2}+e^{x} \\ &=(0.1)^{2}+e^{0.1} \\ &=1.1152 \\ \text { Error } &=1.1152-1.1145=0.00069 \\ \% \text { error } &=0.06 \% \end{aligned}
Question 4
The ordinary differential equation
\frac{dx}{dt}=-3x+2, \; with \; x(0)=1
is to be solved using the forward Euler method. The largest time step that can be used to solve the equation without making the numerical solution unstable is ________
A
0.6
B
1.2
C
1.8
D
2.4
GATE EC 2016-SET-2   Engineering Mathematics
Question 4 Explanation: 
\frac{d y}{d x}=-3 y+2, \quad y(0)=1
If |1-3 h| \lt 1, then solution of differential equation is stable.
\begin{array}{c} -1 \lt 1-3 h \lt 1 \\ -2 \lt -3 h \lt 0 \\ 0 \lt h \lt \frac{2}{3} \\ h_{\max }=\frac{2}{3}=0.66 \end{array}
Question 5
The Newton-Raphson method is used to solve the equation f (x) = x^{3}- 5x^{2} + 6x- 8 = 0 . Taking the initial guess as x = 5, the solution obtained at the end of the first iteration is __________.
A
2.05
B
2.5
C
4.29
D
5.25
GATE EC 2015-SET-3   Engineering Mathematics
Question 5 Explanation: 
\begin{aligned} f(x) &=x^{3}-5 x^{2}+6 x-8 \\ x_{0} &=5 \\ f^{\prime}(x) &=3 x^{2}-10 x+6 \\ x_{1} &=x_{0}-\frac{f\left(x_{0}\right)}{f^{\prime}\left(x_{0}\right)} \\ &=5-\frac{f(5)}{f^{\prime}(5)} \\ &=5-\frac{5^{3}-5 \times 5^{2}+6 \times 5-8}{3 \times 5^{2}-10 \times 5+6} \\ &=5-\frac{22}{31}=5-0.7097 \\ &=4.2903 \end{aligned}


There are 5 questions to complete.