Project Work - CM
Project Work - CM
Project Work - CM
where V = volume (𝑚3 ), h = depth of water in tank (m), and R = the tank radius (m).
If R = 3 m, what depth must the tank be filled to so that it holds 30 𝑚3 ? 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.
3) The outflow concentration from a reactor is measured at a few times over a 24-hr period:
𝑡 (ℎ𝑟) 0 1 5.5 10 12 14 16 18 20 24
𝑐 (𝑚𝑔⁄𝐿) 1 1.5 2.3 2.1 4 5 5.5 5 3 1.2
The flow rate for the outflow in 𝑚3 ⁄𝑠 can be computed with the following equation:
2𝜋
𝑄(𝑡) = 20 + 10 ( (𝑡 − 10))
24
se the best numerical integration method to determine the flow weighted average
concentration leaving the reactor over the 24-hr period,
𝑡
∫0 𝑄(𝑡)𝑐(𝑡)𝑑𝑡
𝑐̅ = 𝑡
∫0 𝑄(𝑡)𝑑𝑡
4
4) Develop a MATLAB program to test the computation of ∫−2(1 − 𝑥 − 4𝑥 3 + 2𝑥 5 )𝑑𝑥 using
Simpson’s 1/3 and Simpson’s 3/8th rule.
5) The following system of equations is designed to determine concentrations (the c’s in
g/𝑚3 ) in a series of coupled reactors as a function of the amount of mass input to each
reactor (the right-hand sides in g/day),
15𝑐1 − 3𝑐2 − 𝑐3 = 3300
−3𝑐1 + 18𝑐2 − 6𝑐3 = 1200
−4𝑐1 − 𝑐2 + 12𝑐3 = 2400
a) Determine the matrix inverse using MATLAB.
b) Determine the solution using MATLAB.
c) Determine how much the rate of mass input to reactor 3 must be increased to induce
a 10 g/𝑚3 rise in the concentration of reactor 1. (d) How much will the concentration
in reactor 3 be reduced if the rate of mass input to reactors 1 and 2 is reduced by 700
and 350 g/day, respectively.
6) Assuming that drag is proportional to the square of velocity, we can model the velocity of
a falling object like a parachutist with the following differential equation
𝑑𝑣 𝑐𝑑
= 𝑔 − ( ) 𝑣2
𝑑𝑡 𝑚
where v is velocity (m/s), t = time (s), g is the acceleration due to gravity (9.81 𝑚⁄𝑠 2 ), 𝑐𝑑
= a second-order drag coefficient (kg/m), and m = mass (kg). Solve for the velocity and
distance fallen by a 90-kg object with a drag coefficient of 0.225 kg/m. If the initial height
is 1 km, determine when it hits the ground. Obtain your solution with (a) Euler’s method
and (b) the fourth-order RK method.
7) Determine the temperatures along a 1-m horizontal rod described by the heat-conduction
equation (Eq. 30.1). Assume that the right boundary is insulated and that the left boundary
(x = 0) is represented by
𝜕𝑇
−𝑘 ′ = | = ℎ(𝑇𝑎 − 𝑇𝑏 )
𝜕𝑥 𝑥=0
here 𝑘 ′ is coefficient of thermal conductivity (W/m · °C), h = convective heat transfer
coefficient (W/m2 · °C), 𝑇𝑎 = ambient temperature (°C), and T0 = temperature of the
rod at x = 0 (°C). Solve for temperature as a function of time using a spatial step of ∆𝑥 =
10−5 𝑚
1 𝑐m and the following parameter values: 𝑘 ′ = 2 × = 10 W/m · °C, h = 25 W/𝑚2
𝑠2
. °C, and 𝑇𝑎 = 50 °C. Assume that the initial temperature of the rod is zero.
8) Generate eight equally-spaced points from the function f (t) = sin2t from t =0 to 2π. Fit this
data with (a) a seventh degree interpolating polynomial. Compare the interpolating
polynomial with the actual function graphically using MATLAB.
9) To calculate a planet’s space coordinates, we have to solve the function f(x) = x − 1 − 0.5
sin x. Let the base point be a = xi = π/2 on the interval [0,π]. Determine the 5th degree Taylor
series expansion resulting in a maximum error of 0.015 on the specified interval. The error
is equal to the absolute value of the difference between the given function and the specific
Taylor series expansion.
10) Consider the function f(x) = x3 − 2x + 4 on the interval [−2, 2] with h = 0.25. Use the
forward and backward, finite difference approximations for the first and second derivatives
so as to graphically illustrate which approximation is most accurate. Graph all three first
derivative finite difference approximations along with the theoretical, and do the same for
the second derivative as well.
11) a) Determine the LU decomposition without pivoting by hand for the following matrix
and check your results by validating that [L][U] = [A].
8 2 1
[3 7 2]
2 3 9
(b) Employ the result of (a) to compute the determinant. (c) Repeat (a) and (b) using
MATLAB
12) The following second-order ODE is considered to be stiff 𝑑2 𝑦⁄𝑑𝑥 2 =
−1001 𝑑𝑦⁄𝑑𝑥 − 1000𝑦. Solve this differential equation (a) analytically and (b)
numerically for x = 0 to 5. For (b) use an implicit approach with h = 0.5. Note that the
initial conditions are 𝑦(0) = 1 and 𝑦 , (0) = 0. Display both results graphically.
13) The following nonlinear, parasitic ODE was suggested by Hornbeck (1975):
𝑑𝑦1 ⁄𝑑𝑡 = 5(𝑦1 − 𝑡 2 ). If the initial condition is 𝑦1 (0) = 0.08, obtain a solution from 𝑡 =
0 𝑡𝑜 5
(a) Analytically (b) Using the fourth-order RK method with a constant step size of 0.03125.
(c) Using the MATLAB function ODE45. (d) Using the MATLAB function ODE23s. (e)
Using the MATLAB function ODE23tb. Present your results in graphical form.
14) The infinite series
𝑛
1
𝑓(𝑛) = ∑
𝑖4
𝑖=1