Numerical Analysis Computer Programming
Numerical Analysis Computer Programming
Ramanasri Institute
WEBSITE: MATHEMATICSOPTIONAL.COM
CONTACT: 8750706262/6363 1
2017
1. Explain the main steps of the Gauss-Jordan method and apply this method to find the inverse of the matrix
2 6 6
2 8 6 . [10 Marks]
2 6 8
2. Write the Boolean expression z( y z)( x y z) in the simplest form using Boolean postulate rules. Mention
the rules used during simplification. Verify your result by constructing the truth table for the given
expression and for its simplest form. [10 Marks]
3. For given equidistant values u1, u0 , u1 and u2 a values is interpolated by Lagrange’s formula. Show that it may
y( y 2 1) 2 x( x 2 1) 2
be written in the form ux yu0 u1 u0 , where x y 1 . [15 Marks]
3! 3!
b 3h
4. Derive the formula a ydx [( y0 yn ) 3( y1 y2 y4 y5 ... yn1 ) 2( y3 y6 yn3 )]. Is there any
8
3
restriction on n ? State that condition. What is the error bounded in the case of Simpson’s rule?
8
[20 Marks]
5. Write an algorithm in the form of a flow chart for Newton-Raphson method. Describe the cases of failure of
this method. [15 Marks]
2016
6. (i) 4096 (ii) 0.4375 (iii) 2048.0625
Convert the following decimal numbers to univalent binary and hexadecimal numbers: (10 marks)
7. Let f ( x ) e2x cos3x for x [0,1] . Estimate the value of f (0.5) Using Lagrange interpolating
polynomial of degree 3 over the nodes x 0, x 0.3, x 0.6 and x 1 .Also compute the error bound
over the interval [0,1] and the actual error E(0.5) (20 marks)
1
8. For an integral f ( x )dx show that the two point Gauss quadrature rule is given by
1
1 4
1 1 x
f ( x )dx f 3 f 3 using this rule estimate 2xe dx (15 marks)
1 2
9. Let A, B, C be Boolean variable denote complement A, A B of is an expression for A OR B and
B. A is an expression for AANDB .Then simplify the following expression and draw a block diagram
of the simplified expression using AND and OR gates.
A.( A B,C ).( A B C ).( A B C ).( A B C ). (15 marks)
2015
10. Find the principal (or canonical) disjunctive normal form in three variables p, q, r for the Boolean
expression ( p q ) r ( p q ) r . Is the given Boolean expression a contradiction or a
tautology? (10 Marks)
11. Find the Lagrange interpolating polynomial that fits the following data:
2014
14. Apply Newton-Raphson method to determine a root of the equation cos x xex 0 correct up to
four decimal places. (10 Marks)
1
dx
15. Use five subintervals to integrate 2
using trapezoidal rule. (10 Marks)
01 x
16. Use only AND and OR logic gates to construct a logic circuit for the Boolean expression z xy uv
(10 Marks)
17. Solve the system of equations
2x1 x2 7
x1 2x2 x3 1
x 2 2x 3 1
using Gauss-Seidel iteration method (perform three iterations) (15 Marks)
dy
18. Use Runge-Kutta formula of fourth order to find the value of y at x 0.8, where x y,
dx
y(0.4) 0.41 . Take the step length h 0.2 (20 Marks)
19. Draw a flowchart for Simpson’s one-third rule. (15 Marks)
20. For any Boolean variables x and y, show that x xy x . (15 Marks)
2013
21. In an examination, the number of students who obtained marks between certain limits were given
in the following table:
Marks 30-40 40-50 50-60 60-70 70-80
No. of students 31 42 51 35 31
2012
25. Use Newton-Raphson method to find the real root of the equation 3x cos x 1 correct to four
decimal places (12 Marks)
dy
26. Provide a computer algorithm to solve an ordinary differential equation f ( x , y) in the interval
dx
[ a,b] for n number of discrete points, where the initial value is y(a) , using Euler’s method.
(15 Marks)
27. Solve the following system of simultaneous equations, using Gauss-Seidel iterative method :
3x 20 y z 18
20x y 2z 17 (20 Marks)
2x 3 y 20z 25
dy
28. Find at x 0.1 from the following data:
dx
x: 0.1 0.2 0.3 0.4
(20 Marks)
y : 0.9975 0.9900 0.9776 0.9604
29. In a certain examination, a candidate has to appear for one major & two major subjects .The rules
for declaration of results are marks for major are denoted by M1 and for minors by M 2 and M 3 .If
the candidate obtains 75% and above marks in each of the three subjects, the candidate is declared
to have passed the examination in first class with distinction. If the candidate obtains 60% and
above marks in each of the three subjects, the candidate is declared to have passed the
examination in first class. If the candidate obtains 50% or above in major, 40% or above in each of
the two minors and an average of 50% or above in all the three subjects put together, the
candidate is declared to have passed the examination in second class. All those candidates, who
have obtained 50% and above in major and 40% or above in minor, are declared to have passed the
examination. If the candidate obtains less than 50% in major or less than 40% in anyone of the two
minors, the candidate is declared to have failed in the examinations. Draw a flow chart to declare
the results for the above. (20 Marks)
2010
2
35. Find the positive root of the equation 10xe x 1 0 correct up to 6 decimal places by using
Newton-Raphson method. Carry out computations only for three iterations. (12 Marks)
36. (i) Suppose a computer spends 60 per cent of its time handling a particular type of
computation when running a given program and its manufacturers make a change that
improves its performance on that type of computation by a factor of 10. If the program
takes 100 sec to execute, what will its execution time be after the change?
(ii) If A B AB ' A ' B, find the value of x y z. (6+6=12 Marks)
37. Given the system of equations
2x 3 y 1
2x 4 y z 2
2 y 6z Aw 4
4 z Bw C
2009
40. (i) The equation x 2 ax b 0 has two real roots and . Show that the iterative method
( ax k b)
given by : x k 1 , k 0,1,2... is convergent near x , if
xk
(ii) Find the values of two valued Boolean variables A, B,C, D by solving the following
simultaneous equations:
A AB 0
AB AC
AB AC CD CD
where x represents the complement of x (6+6=12 Marks)
41. (i) Realize the following expressions by using NAND gates only :
g (a b c)d(a e) f where x represents the complement of x
(ii) Find the decimal equivalent of (357.32)8 (6+6=12 Marks)
42. Develop an algorithm for Regula-Falsi method to find a root of f ( x ) 0 starting with two initial
iterates x 0 and x1 to the root such that sign f ( x0 ) sign f ( x1 ) . Take n as the maximum number
of iterations allowed and epsilon be the prescribed error. (30 Marks)
43. Using Lagrange interpolation formula, calculate the value of f (3) from the following table of values
of x and f ( x ) :
x 0 1 2 4 5 6 (15 Marks)
f (x ) 1 14 15 5 6 19
44. Find the value of y(1.2) using Runge-Kutta fourth order method with step size h 0.2 from the
initial value problem: y ' xy, y(1) 2 (15 Marks)
2008
45. Find the smallest positive root of equation xex cos x 0 using Regula-Falsi method. Do three
iterations. (12 Marks)
46. State the principle of duality
2007
49. Use the method of false position to find a real root of x 3 5x 7 0 lying between 2 and 3 and
correct to 3 places of decimals. (12 Marks)
50. Convert:
(i) 46655 given to be in the decimal system into one in base 6.
(ii) (11110.01)2 into a number in the decimal system. (6+6=12 Marks)
51. (i) Find from the following table, the area bounded by the x - axis and the curve y f ( x )
between x 5.34 and x 5.40 using the trapezoidal rule:
x 5.34 5.35 5.36 5.37 5.38 5.39 5.40
(15 Marks)
f ( x ) 1.82 1.85 1.86 1.90 1.95 1.97 2.00
(ii) Apply the second order Runge-Kutta method to find an approximate value of y at x 0.2
taking h 0.1, given that y satisfies the differential equation and the initial condition
y ' x y, y(0) 1 (15 Marks)
2006
1
2
52. Evaluate I e x dx by the Simpson’s rule
0
b
x
f ( x )dx f ( x0 ) 4 f ( x1 ) 2 f ( x2 ) 4 f ( x3 ) ..... 2 f ( x2n2 ) 4 f ( x2n1 ) f ( x2n ) with
3
a
2005
56. Use appropriate quadrature formulae out of the Trapezoidal and Simpson’s rules to numerically
1
dx
integrate 2
with h 0.2 . Hence obtain an approximate value of . Justify the use of
01 x
2004
60. The velocity of a particle at distance from a pint on it s path is given by the following table:
S(meters) 0 10 20 30 40 50 60
V (m/sec) 47 58 64 65 61 52 38
1 rd
Estimate the time taken to travel the first 60 meters using Simpson’s rule. Compare the result
3
3 th
with Simpson’s rule. (12 Marks)
8
61. (i) If ( AB,CD)16 ( x )2 ( y)8 ( z )10 then find x , y & z
(ii) In a 4-bit representation, what is the value of 1111 in signed integer form, unsigned integer
form, signed 1’s complement form and signed 2’s complement form? (6+6=12 Marks)
x
62. How many positive and negative roots of the equation e 5sin x 0 exist? Find the smallest
positive root correct to 3 decimals, using Newton-Raphson method. (10 Marks)
63. Using Gauss-Siedel iterative method, find the solution of the following system:
4 x y 8z 26
5x 2 y z 6 up to three iterations. (15 Marks)
x 10 y 2z 13
weights and residues. Use five decimal places for computation. (12 Marks)
65. (i) Convert the following binary number into octal and hexa decimal system:
101110010.10010
(ii) Find the multiplication of the following binary numbers: 11001.1 and 101.1 (6+6=12 Marks)
1 1
66. Find the positive root of the equation 2e x using Newton-Raphson method correct
x 2 x 1
to four decimal places. Also show that the following scheme has error of second order:
1 a
xn1 xn 1 2 (30 Marks)
2 xn
1 rd b
1
67. Draw a flow chart and algorithm for Simpson’s rule for integration 2
dx correct to 106
3 a 1 x
(30 Marks)
2002
68. Find a real root of the equation f ( x ) x 3 2x 5 0 by the method of false position. (12 Marks)
69. (i) Convert 100.8510 into its binary equivalent.
(ii) Multiply the binary numbers 1111.012 and 1101.112 and check with its decimal
equivalent (4+8=12 Marks)
70. (i) Find the cubic polynomial which takes the following values:
y(0) 1, y(1) 0, y(2) 1 & y(3) 10 . Hence , or otherwise, obtain y(4)
dy
(ii) Given: y x where y(0) 2, using the Runge-Kutta fourth order method, find y(0.1) and
dx
y(0.2) . Compare the approximate solution with its exact solution. e0.1 1.10517, e0.2 1.2214 .
(10+20=30 Marks)
71. Draw a flow chart to examine whether a given number is a prime. (10 Marks)
2001
72. Show that the truncation error associated with linear interpolation of f ( x ), using ordinates at x 0
1
and x1 with x0 x x1 is not larger in magnitude than M 2 ( x1 x0 )2 where M 2 max f ''( x )
8
2 t 2
in x0 x x1 . Hence show that if f ( x ) e
0
dt, the truncation error corresponding to linear
( x1 x0 )2
interpolation of f ( x ) in x0 x x1 cannot exceed . (12 Marks)
2 2 e
2000
76. (i) Using Newton-Raphson method, show that the iteration formula for finding the reciprocal
x p 1 Nxi
of the pth root of N is xi 1 i
p
(ii) Prove De Morgan’s Theorem ( p q)' p '.q ' (6+6=12 Marks)
1
dx
77. (i) Evaluate 1 x 2 , by subdividing the interval (0, 1) into 6 equal parts and using Simpson’s one-
0
third rule. Hence find the value of and actual error, correct to five places of decimals
(ii) Solve the following system of linear equations, using Gauss-elimination method:
x1 6x 2 3x3 6
2x1 3x 2 3x3 117 (15+15=30 Marks)
4 x1 x2 2x3 283
1999
b
78. Obtain the Simpson’s rule for the integral I f ( x )dx and show that this rule is exact for polynomials of
a
degree n 3 . In general show that the error of approximation for Simpson’s rule is given by
(b a )5 iv
R f ( ), 0,2 .
2880
1
dx
Apply this rule to the integral and show that R 0.008333. (20 Marks)
01 x
du
79. Using fourth order classical Runge-Kutta method for the initial value problem 2tu2 ,u(0) 1, with
dt
h 0.2 on the interval [0, 1], calculate u(0.4) correct to six places of decimal. (20 Marks)
1997
83. Apply that fourth order Runge-Kutta method to find a value of y correct to four places of decimals
dy
at x 0.2, when y ' x y, y(0) 1 (20 Marks)
dx
84. Show that the iteration formula for finding the reciprocal of N is xn1 xn 2 N xn , n 0, 1...
(20 Marks)
85. Obtain the cubic spline approximation for the function given in the tabular form below:
x 0 1 2 3
and M 0 0, M3 0 (20 Marks)
f ( x ) 1 2 33 244
1996
86. Describe Newton-Raphson method for finding the solutions of the equation f ( x ) 0 and show
that the method has a quadratic convergence. (20 Marks)
87. The following are the measurements t made on a curve recorded by the oscillograph representing
a change of current i due to a change in the conditions of an electric current:
t 1.2 2.0 2.5 3.0
i 1.36 0.58 0.34 0.20
Applying an appropriate formula interpolate for the value of i when t 1.6 (20 Marks)
dy dz
88. Solve the system of differential equations xz 1, xy for x 0.3 given that y 0
dx dx
and z 1 when x 0, using Runge-Kutta method of order four (20 Marks)
1995
89. Find the positive root of log e x cos x nearest to five places of decimal by Newton-Raphson
method. (20 Marks)
3.4
3 rd
90. Find the value of f ( x ) dx from the following data using Simpson’s rule for the interval
1.6 8
1 th
(1.6, 2.2) and rule for (2.2, 3.4) :
8
1994
x 2 x 3 0.3x
91. Find the positive root of the equation e x 1 x e correct to five decimal places.
2 6
(20 Marks)
92. Fit the following four points by the cubic splines.
i 0 1 2 3
xi 1 2 3 4
yi 1 5 11 8
Use the end conditions Use the end conditions y "0 y "3 0
Hence compute (i) y(1.5)
(ii) y '(2) (20 Marks)
93. Find the derivative of f ( x ) at x 0.4 from the following table:
1993
94. Find correct to 3 decimal places the two positive roots of 2ex 3x 2 2.5644 (20 Marks)
3
4
95. Evaluate approximately x dx Simpson’s rule by taking seven equidistant ordinates. Compare it
3
with the value obtained by using the trapezoidal rule and with exact value. (20 Marks)
dy
96. Solve xy for x 1.4 by Runge-Kutta method, initially x 1, y 2 (Take h 0.2 ) (20 Marks)
dx
1992
97. Compute to 4 decimal placed by using Newton-Raphson method, the real root of x 2 4sin x 0 .
(20 Marks)
dy
98. Solve by Runge-Kutta method x y with the initial conditions x0 0, y0 1 correct up to 4
dx
decimal places, by evaluating up to second increment of y (Take h 0.1 ) (20 Marks)
99. Fit the natural cubic spline for the data.