0% found this document useful (0 votes)
35 views

Paractice Problem _Math Methods I_ (1)

The document presents a series of mathematical problems focused on numerical methods, including error calculations, series expansions, derivative approximations, and root-finding techniques. It covers various topics such as the Maclaurin series, Taylor series, the Stefan-Boltzmann law, and methods like bisection, Newton-Raphson, and secant methods for solving equations. Each problem requires specific computations and interpretations of results, emphasizing the application of numerical analysis in engineering and mathematical contexts.

Uploaded by

abdulrafaykamal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
35 views

Paractice Problem _Math Methods I_ (1)

The document presents a series of mathematical problems focused on numerical methods, including error calculations, series expansions, derivative approximations, and root-finding techniques. It covers various topics such as the Maclaurin series, Taylor series, the Stefan-Boltzmann law, and methods like bisection, Newton-Raphson, and secant methods for solving equations. Each problem requires specific computations and interpretations of results, emphasizing the application of numerical analysis in engineering and mathematical contexts.

Uploaded by

abdulrafaykamal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 12

Problem 1

Suppose that you have the task of measuring the lengths of a bridge and a rivet and come up with
9999 and 9 cm, respectively. If the true values are 10,000 and 10 cm, respectively, compute (a) the
true error and (b) the true percent relative error for each case.

Problem 2

In mathematics, functions can often be represented by infinite series. For example, the exponential
function can be computed using
𝑥2 𝑥3 𝑥𝑛
ex = 1 + x + + + ---------
2! 3! 𝑛!

Thus, as more terms are added in sequence, the approximation becomes a better and better estimate
of the true value of ex. Given equation is called a Maclaurin series expansion. Starting with the
simplest version, ex = 1, add terms one at a time to estimate e0.5. After each new term is added,
compute the true and approximate percent relative errors. Note that the true value is e0.5 = 1.648721.
Add terms until the absolute value of the approximate error estimate 𝜀𝑎 falls below a prespecified
error criterion es conforming to three significant figures.

Problem 3

Use forward and backward difference approximations of O(h) and a centered difference
approximation of O(h2) to estimate the first derivative of

𝑓(𝑥) = − 0.1𝑥 4 − 0.15 𝑥 3 − 0.5 𝑥 2 − 0.25 𝑥 + 1.25

at x = 0.5 using a step size h = 0.5. Repeat the computation using ℎ = 0.25 . Note that the
derivative can be calculated directly as

𝑓 ′ (𝑥) = − 0.4 𝑥 3 − 0.45 𝑥 2 − 1.0 𝑥 2 − 0.25

and can be used to compute the true value as 𝑓’ (0.5) = − 0.9125.

Problem 4

The Maclaurin series expansion for 𝑠𝑖𝑛 (𝑥) is

𝑥3 𝑥5 𝑥7
𝑠𝑖𝑛 𝑥 = 1 − + − + −−−−−
3! 5! 7!
Starting with the simplest version, sin x = 1, add terms one at a time to estimate 𝑠𝑖𝑛 (𝜋/3). After
each new term is added, compute the true and approximate percent relative errors. Use your pocket
calculator to determine the true value. Add terms until the absolute value of the approximate error
estimate falls below an error crite rion conforming to two significant figures.
Problem 5

Use zero- through third-order Taylor series expansions to predict 𝑓 (3) for

𝑓(𝑥) = 25 𝑥 3 − 6 𝑥 2 + 7 𝑥 − 88

using a base point at 𝑥 = 1. Compute the true percent relative error et for each approximation.

Use forward and backward difference approximations of 𝑂(ℎ) and a centered difference
approximation of 𝑂(ℎ2 ) to estimate the first derivative of the function examined. Evaluate the
derivative at 𝑥 = 2 using a step size of ℎ = 0.2. Compare your results with the true value of the
derivative. Interpret your results on the basis of the remainder term of the Taylor series expansion.

Problem 6
The Stefan-Boltzmann law can be employed to estimate the rate of radiation of energy H from a
surface, as in

𝐻 = 𝐴𝑒𝜎𝑇 4

where H is in watts, A = the surface area (m2), e = the emissivity that characterizes the emitting
properties of the surface (dimension less), 𝜎 = a universal constant called the Stefan-Boltzmann
constant (= 5.67 × 10−8 𝑊 𝑚−2 𝐾 −4 ), and T = absolute temperature (K). Determine the error
of H for a steel plate with A = 0.15 m2, e = 0.90, and 𝑇 = 650 ± 20. Compare your results with
the exact error. Repeat the computation but with 𝑇 = 650 ± 40. Interpret your results.

Problem 7
a) Use Bisection method to solve the problem with initial guess of [10, 16]. to determine the
drag coefficient c needed for a parachutist of mass m = 68.1 kg to have a velocity of 40
m/s after free falling for time t = 10 s. Note: The acceleration due to gravity is 9.81 m/s2.
𝑔𝑚 𝑐
𝑣(𝑡) = (1 − 𝑒 −(𝑚)𝑡 )
𝑐
b) For a parachutist with a drag coefficient c = 15 kg/s, compute the mass m so that the
velocity is v = 36 m/s at t = 10 s. Use the false-position method to determine m to a level
of es = 0.1%.
c) Use bisection to determine the drag coefficient needed so that an 82-kg parachutist has a
velocity of 36 m/s after 4 s of free fall. Note: The acceleration of gravity is 9.81 m/s2. Start
with initial guesses of xl = 3 and xu = 5 and iterate until the approximate relative error falls
below 2%. Also perform an error check by substituting your final answer into the original
equation.
Problem 8
1) Determine the roots of 𝑓(𝑥) = − 0.5𝑥 2 + 2.5 𝑥 + 4.5
a) Using the quadratic formula.
b) Using three iterations of the bisection method to determine the highest root. Employ initial
guesses of xl = 5 and xu = 10. Compute the estimated error 𝜀𝑎 and the true error 𝜀𝑡 after
each iteration.
2) Determine the real root of 𝑓(𝑥) = 5𝑥 3 − 5𝑥 2 + 6 𝑥 − 2
a) Using the quadratic formula.
b) Using three iterations of the bisection method to determine the highest root. Employ initial
guesses of xl = 0 and xu = 1 and iterate until the estimated error 𝜀𝑎 falls below a level of
10%.
Problem 9

Find the positive real root of

𝑓(𝑥) = 𝑥 4 − 8 𝑥 3 − 35 𝑥 2 + 450 𝑥 − 1001

using the false-position method. Use initial guesses of xl = 4.5 and xu = 6 and perform five
iterations. Compute both the true and approximate errors based on the fact that the root is 5.60979.
Also perform the computation to within 𝜀𝑠 = 1.0%.

Problem 10
As depicted in Fig., the velocity of water, v (m/s), discharged from a cylindrical tank through a
long pipe can be computed as

√2𝑔𝐻
𝑣 = √2𝑔𝐻 tanh ( 𝑡)
2𝐿

where g = 9.81 m/s2, H = initial head (m), L = pipe length (m), and t = elapsed time (s). Determine
the head needed to achieve v = 5 m/s in 2.5 s for a 4-m-long pipe

a) By using bisection
b) With false position.

Employ initial guesses of xl = 0 and xu = 2 m with a stopping criterion of 𝜀𝑠 = 1%. Check you
results.

Problem 11
Water is flowing in a trapezoidal channel at a rate of Q = 20 m3/s. The critical depth y for such a
channel must satisfy the equation
𝑄2
0= 1− 𝐵
𝑔𝐴3𝑐
where g = 9.81 m/s2, Ac = the cross-sectional area (m2), and B = the width of the channel at the
surface (m). For this case, the width and the cross-sectional area can be related to depth y by

𝑦2
𝐵 = 3 + 𝑦 𝑎𝑛𝑑 𝐴𝑐 = 3𝑦 +
2
Solve for the critical depth using (a) bisection, and (b) false position. Use initial guesses of xl =
0.5 and xu = 2.5, and iterate until the approximate error falls below 1% or the number of iterations
exceeds 5.

Problem 12
You are designing a spherical tank (Fig.) to hold water for a small village in a developing country.
The volume of liquid it can hold can be computed as
[3𝑅 − ℎ]
𝑉 = 𝜋ℎ2
3
where V = volume (m3), h = depth of water in tank (m), and R = the tank radius (m).

If R = 3 m, to what depth must the tank be filled so that it holds 30 m3?


a) Use three iterations of the false-position method to determine your answer. Determine the
approximate relative error after each iteration. Employ initial guesses of 0 and R.
b) Use three iterations of the Newton Raphson method to determine your answer. Determine
the approximate relative error after each iteration. Note that an initial guess of R will always
converge.
Problem 13

The saturation concentration of dissolved oxygen in freshwater can be calculated with the equation

1.575701 × 105 6.642308 × 107 1.243800 × 1010


𝑙𝑛 𝑜𝑠𝑓 = − 139.34411 + − +
𝑇𝑎 𝑇𝑎 2 𝑇𝑎 3
2 8.621949 × 1011

𝑇𝑎 4
where osf = the saturation concentration of dissolved oxygen in freshwater at 1 atm (mg/L) and Ta
= absolute temperature (K). Remember that Ta = T + 273.15, where T = temperature (°C).
According to this equation, saturation decreases with increasing temperature. For typical natural
waters in temperate climates, the equation can be used to determine that oxygen concentration
ranges from 14.621 mg/L at 0°C to 6.413 mg/L at 40°C. Given a value of oxygen concentration,
this formula and the bisection method can be used to solve for temperature in °C.

a) If the initial guesses are set as 0 and 40 0C, how many bisection iterations would be required
to determine temperature to an absolute error of 0.05 0C?
b) Develop and test a bisection program to determine T as a function of a given oxygen
concentration to a prespecified absolute error as in (a). Given initial guesses of 0 and 40
0
C, test your program for an absolute error = 0.05 0C and the following cases: osf = 8, 10,
and 12 mg/L.
Problem 14

Use the Newton-Raphson method to estimate the root of 𝑓(𝑥) = −𝑒 −𝑥 − 𝑥, employing an initial
guess of x0 = 0.

Use the secant method to estimate the root of 𝑓(𝑥) = −𝑒 −𝑥 − 𝑥. Start with initial estimates of
𝑥−1 = 0 and 𝑥0 = 1.0.

Use the false-position and secant methods to estimate the root of 𝑓(𝑥) = 𝑙𝑛 𝑥 . Start the
computation with values of 𝑥𝑙 = 𝑥𝑖−1 = 0.5 and 𝑥𝑢 = 𝑥𝑖 = 5.0

Problem 15

Determine the highest real root of

𝑓(𝑥) = 2𝑥 3 − 11.7𝑥 2 + 17.7𝑥 − 5


1. Newton-Raphson method (three iterations, x0 = 3).
2. Secant method (three iterations, x-1 = 3, x0 = 4).
3. Compute the approximate percent relative errors for your solutions.
Problem 16

Locate the first positive root of

𝑓(𝑥) = 𝑠𝑖𝑛 𝑥 + 𝑐𝑜𝑠(1 + 𝑥 2 ) − 1


where x is in radians. Use four iterations of the secant method with initial guesses of

a) 𝑥𝑖−1 = 1.0 𝑎𝑛𝑑 𝑥𝑖 = 3.0


b) 𝑥𝑖−1 = 1.5 𝑎𝑛𝑑 𝑥𝑖 = 2.5
c) 𝑥𝑖−1 = 1.5 𝑎𝑛𝑑 𝑥𝑖 = 2.25
to locate the root.
Problem 17

Determine the roots of the following simultaneous nonlinear equations using Newton-Raphson
method:

𝑦 = − 𝑥 2 + 𝑥 + 0.75

𝑦 + 5𝑥𝑦 = 𝑥 2

Employ initial guesses of 𝑥 = 𝑦 = 1.2 and discuss the results.

Problem 18

For the set of equations

2𝑥2 + 5𝑥3 = 9

2𝑥1 + 𝑥2 + 𝑥3 = 9

3𝑥1 + 𝑥2 = 10

a) Compute the determinant.


b) Use Cramer’s rule to solve the x’s.
Problem 19

Three masses are suspended vertically by a series of identical springs where mass 1 is at the top
and mass 3 is at the bottom. If g = 9.81 m/s2 , m1 = 2 kg, m2 = 3 kg, m3 = 2.5 kg, and the k’s = 10
kg/s2 , solve for the displacements x.

Hint: Generate three equations for each mass. Then convert the equation into unknown variable
x’s and then solve those equations.

Problem 20
Solve the following set of equations with LU decomposition:

3𝑥1 − 2𝑥2 + 𝑥3 = −10

2𝑥1 + 6𝑥2 − 4𝑥3 = 44

2𝑥1 − 2𝑥2 + 5𝑥3 = −26

Problem 21

Determine ‖𝐴‖𝑒 , ‖𝐴‖1 , and ‖𝐴‖∞ for


8 2 −10
[𝐴] = [−91 3 1 ]
5 −1 6
Scale the matrix by making the maximum element in each row equal to one.
Problem 22

Consider vectors:

⃗⃗
𝐴⃗ = 2𝑖⃗ − 3𝑗⃗ + 𝑎𝑘

⃗⃗
⃗⃗ = 2𝑏 + 𝑗⃗ − 4𝑘
𝐵

⃗⃗
𝐶⃗ = 3𝑖⃗ + 𝑐 𝑗⃗ + 2 𝑘

Vector 𝐴⃗ is perpendicular to 𝐵
⃗⃗ as well as to 𝐶⃗. It is also known that 𝐵
⃗⃗ . 𝐶⃗ = 2. Use any method to
solve the three unknowns, a, b, and c.
Problem 23

Determine the matrix inverse based on the LU decomposition.


0.8 −0.4 𝑥1 41
[−0.4 0.8 −0.4] {𝑥2 } = { 25 }
−0.4 0.8 𝑥3 105
Problem 24

Figure shows three reactors linked by pipes. As indicated, the rate of transfer of chemicals through
each pipe is equal to a flow rate (Q, with units of cubic meters per second) multiplied by the
concentration of the reactor from which the flow originates (c, with units of milligrams per cubic
meter). If the system is at a steady state, the transfer into each reactor will balance the transfer out.
Develop mass balance equations for the reactors and solve the three simultaneous linear algebraic
equations for their concentrations.

Problem 25
The Lower Colorado River consists of a series of four reservoirs as shown in Fig. Mass balances
can be written for each reservoir and the following set of simultaneous linear algebraic equations
results:
13.442 0 0 0 𝑐1 750.5
−13.442 12.252 0 0 𝑐2 300
[ ] {𝑐 } = { }
0 −12.252 12.377 0 3 102
0 0 −12.377 11.797 𝑐4 30
here the right-hand-side vector consists of the loadings of chloride to each of the four lakes and c1,
c2, c3, and c4 = the resulting chloride concentrations for Lakes Powell, Mead, Mohave, and Havasu,
respectively.

a) Use the matrix inverse to solve the concentrations in each of the four lakes.
b) How much must the loading to Lake Powell be reduced in order for the chloride
concentration of Lake Havasu to be 75?
c) Using the column-sum norm, compute the condition number and how many suspect digits
would be generated by solving this system.

Problem 26

A peristaltic pump delivers a unit flow (Q1) of a highly viscous fluid. The network is depicted in
Fig. Every pipe section has the same length and diameter. The mass and mechanical energy balance
can be simplified to obtain the flow in every pipe. Solve the following system of equations to
obtain the flow in every pipe.

𝑄3 + 2𝑄4 − 2𝑄2 = 0

𝑄5 + 2𝑄6 − 2𝑄4 = 0

3𝑄7 − 2𝑄6 = 0

𝑄1 = 𝑄2 + 𝑄3

𝑄3 = 𝑄4 + 𝑄5

𝑄5 = 𝑄6 + 𝑄7
Problem 27

Use Newton’s interpolating polynomial to determine y at x = 3.5 to the best possible accuracy.
Compute the finite divided differences as and order your points to attain optimal accuracy and
convergence.

𝑥 0 1 2.5 3 5 6
𝑓(𝑥) 2 5.4375 7.3516 7.5625 9.1875 12

Problem 28

𝑥 0 1 2 3 4 5
𝑓(𝑥) 0 0.5 0.8 0.9 0.941176 0.961538

𝑥2
Note that the values in the table were generated with the function 𝑓(𝑥) = (1+ 𝑥 2 ).

a) Determine the correct value analytically.


b) Use the bisection method to find value at 𝑓(𝑥) = 0.85 .
c) Use False Position method to find value of x at 𝑓(𝑥) = 0.85.
d) Use Newton Raphson method to find value of x at 𝑓(𝑥) = 0.85.
e) Use Secant method to find value of x at 𝑓(𝑥) = 0.85.
f) Calculate the true and approximate error.
g) Discuss the results.
Problem 29

Use the portion of the given steam table for superheated H2O at 200 MPa to

a) Find the corresponding entropy s for a specific volume v of 0.108 m3 /kg with linear
interpolation,
b) Find the same corresponding entropy using newton interpolation,
3
𝑣 (𝑚 ⁄𝑘𝑔) 0.10377 0.11144 0.1254
𝑘𝐽
𝑠 ( ⁄𝑘𝑔. 𝐾 ) 6.4147 6.5453 6.7664
Problem 30
The specific volume of a superheated steam is listed on steam tables for various temperatures.
For example, at a pressure of 3000 lb/in2, absolutely:
3
𝑣 (𝑚 ⁄𝑘𝑔) 700 720 740 760 780
3
𝑣 (𝑚 ⁄𝑘𝑔) 0.0977 0.12184 0.14060 0.15509 0.16643

Determine v at T = 750 0F.

Problem 31

Evaluate the following integral:


𝜋⁄
1. ∫0 2(6 + 3 cos 𝑥) 𝑑𝑥
3
2. ∫0 (1 − 𝑒 −2𝑥 ) 𝑑𝑥
4
3. ∫−2(1 − 𝑥 − 4𝑥 3 + 2𝑥 5 ) 𝑑𝑥
2 2
4. ∫1 (𝑥 + 2⁄𝑥) 𝑑𝑥
5
5. ∫−3(4𝑥 − 3)3 𝑑𝑥
3
6. ∫0 𝑥 3 𝑒 𝑥 𝑑𝑥
1
7. ∫0 142𝑥 𝑑𝑥
a) Analytically.
b) Single application of the trapezoidal rule.
c) multiple-application trapezoidal rule, with n = 2 and 4.
d) single application of Simpson’s 1/3 rule
e) multiple-application Simpson’s 1/3 rule, with n = 4.
f) single application of Simpson’s 3/8 rule.
g) multiple-application Simpson’s rule, with n = 5.
h) For each of the numerical estimates (b) through (g), determine the percent relative error
based on (a).
Problem 32

The function 𝑓(𝑥) = 2𝑒 −1.5𝑥 can be used to generate the following table of unequally spaced data:

𝑥 0 0.05 0.15 0.25 0.35 0.475 0.6


𝑓(𝑥) 2 1.8555 1.5970 1.3746 1.1831 0.9808 0.8131
Evaluate the integral from a = 0 to b = 0.6 using (a) analytical means, (b) the trapezoidal rule, and
(c) a combination of the trapezoidal and Simpson’s rules; employ Simpson’s rules wherever
possible to obtain the highest accuracy. For (b) and (c), compute the percent relative error.

Problem 33

Evaluate the integral of the following tabular data with (a) the trapezoidal rule and (b) Simpson’s
rules:

𝑥 -2 0 2 4 6 8 10
𝑓(𝑥) 35 5 -10 2 5 3 20

Problem 34

The following data was collected for a cross-section of a river (y = distance from bank, H = depth,
and U = velocity).

𝑦, 𝑚 0 1 3 5 7 8 9 10
𝐻, 𝑚 0 1 1.5 3 3.5 3.2 2 0
𝑈, 𝑚/𝑠 0 0.1 0.12 0.2 0.25 0.3 0.15 0

Use numerical integration to compute the (a) average depth, (b) cross-sectional area, (c) average
velocity, and (d) the flow rate. Note that the cross-sectional area (Ac) and the flow rate (Q) can be
computed as
𝑦 𝑦

𝐴𝑐 = ∫ 𝐻(𝑦) 𝑑𝑦 𝑄 = ∫ 𝐻(𝑦)𝑈(𝑦) 𝑑𝑦
0 0

Problem 35

The total mass of a variable density rod is given by


𝐿

𝑚 = ∫ 𝜌(𝑥)𝐴𝑐 (𝑥) 𝑑𝑥
0

where m = mass, 𝜌(𝑥) density, Ac(x) = cross-sectional area, x = distance along the rod, and L =
the total length of the rod. The following data have been measured for a 10-m length rod.
Determine the mass in kilograms to the best possible accuracy.
𝑥, 𝑚 0 2 3 4 6 8 10
𝜌, 𝑔/𝑐𝑚3 4.00 3.95 3.89 3.80 3.60 3.41 3.30
𝐴𝑐 , 𝑐𝑚2 100 103 106 110 120 133 150

You might also like