Practice Solution
Given a set of data provided in Table 2 below:
(a) Write the general form of the Newtons interpolating polynomial that passes through
ve data points.
(b) Make a table with columns of i, xi , f (xi ), f [xi+1 , xi ], f [xi+2 , xi+1 , xi ]
EMAE 250: Lab Assignment 2
1. Define the following function in MATLAB and save the m-file as Lastnamefun.m.
Please find Jeongfun.m
2. Write an algorithm to approximate the root of the above function by using the bisection method. Let xl,
xu, ed, and n be
Lab Assignment 1
Consider the following continuous function:
f ( x) = cos x
1. For x = 0 : 0.1:10 , plot a graph of the above function in MATLAB. Print the figure and submit it with
the completed assignment.
See the Lab1q1.m
2. Derive the second-order Tay
EMAE 250.100: Exercise Problem
February 23, 2011
Given a set of data provided in Table 2 below:
(a) Write the general form of the Newtons interpolating polynomial that passes
through ve data points.
(b) Make a table with columns of i, xi , f (xi ), f [xi+
Homework 11 Solution
1. For the following matrix:
2 4 1
A= 3 0 2
11 0
(a) [1pt] Using Matlab, nd Q and R by using the following commend: [Q, R] = qr(A).
(b) [2pt] For Q and R, perform three iterations of the QR algorithm for nding eigenvalues
of A. You m
EMAE 250: Homework 11
April 15, 2011
1. For the following matrix:
2 4 1
A= 3 0 2
11 0
(a) [1pt] Using Matlab, nd Q and R by using the following commend: [Q, R] =
qr(A).
(b) [2pt] For Q and R, perform three iterations of the QR algorithm for nding
eigenva
Homework 10 Solution
1. Given
dy
= 15(sin x + y ) cos x
dx
(a) [1pt] If y(0) = 1, use the explicit Eulers method to obtain a solution from x = 0 to
x = 1 with the step size, h = 0.5.
(b) [1pt] For the same initial values, use the implicit Eulers method to
EMAE 250: Homework 10
April 7, 2011
1. Given
dy
= 15(sin x + y ) cos x
dx
(a) [1pt] If y (0) = 1, use the explicit Eulers method to obtain a solution from x = 0
to x = 1 with the step size, h = 0.5.
(b) [1pt] For the same initial values, use the implicit
Homework 9 Solution
1. Given the following function:
f (x) = 3x4 4x3 + 2x 5
(a) [1.5pt] nd the estimate of the rst and second derivatives using the forward nite
divided dierence (FFDD) formulas by truncating after the rst term at x = 0.5 and
h = 0.25.
(b)
EMAE 250: Homework 9
April 1, 2011
1. Given the following function:
f (x) = 3x4 4x3 + 2x 5
(a) [1.5pt] nd the estimate of the rst and second derivatives using the forward nite
divided dierence (FFDD) formulas by truncating after the rst term at x = 0.5
an
EMAE 250: Homework 8
March 22, 2011
1. Evaluate the following integral
6
(2 + x 3x2 + 4x4 x5 )dx
0
(a) [1pt] Analytically.
(b) [1pt] Simpsons 1/3 rule where n = 2;
(c) [1pt] Simpsons 1/3 rule where n = 6;
(d) [1pt] Simpsons 3/8 rule where n = 3;
(e) [1pt]
Homework 7 Solution
1. [3pt] We derived a0 and ak from the following equation in the class. Find bk by using
T
T
the cosine and sine laws and the facts that 0 cos(t)dt = 0 sin(t)dt = 0. Note that
w0 = 2/T .
f (t) = a0 +
[ak cos(kw0 t) + bk sin(kw0 t)]
k=1
EMAE 250: Homework 7
March 17, 2011
1. [3pt] We derived a0 and ak from the following equation in the class. Find bk by
using the cosine and sine lows and the facts that 0T cos(t)dt = 0T sin(t)dt = 0.
Note that w0 = 2/T .
f (t) = a0 +
[ak cos(kw0 t) + bk s
Homework 6 Solution
February 28, 2011
1. Consider the following function:
f (x, y ) = (x 1)2 (y 2)2 + xy
(a) [2pt] Find the gradient vector and the Hessian matrix.
(b) [2pt] Perform one iteration of the Newtons method with the initial point x0 =
(x0 , y0
EMAE 250.100: Homework 6
February 17, 2011
1. Consider the following function:
f (x, y ) = (x 1)2 (y 2)2 + xy
(a) [2pt] Find the gradient vector and the Hessian matrix.
(b) [2pt] Perform one iteration of the Newtons method with the initial point x0 =
(x0
Homework 5 Solution
1. Consider the following function:
f (x) = 1 + 4x 2x2 + cos x
(a) [2pt] Find an maximum using three iterations of the Golden Section search with initial
guesses xl = 5 and xu = 5.
(b) [2pt] Find an maximum using three iterations of qu
EMAE 250.100: Homework 5
February 10, 2011
1. Consider the following function: f (x) = 1 + 4x 2x2 + cos x
(a) [2pt] Find an maximum using three iterations of the Golden Section search with
initial guesses xl = 5 and xu = 5.
(b) [2pt] Find an maximum using
Homework 4 Solution
1. In some problems, it is possible to obtain a complex systems of equations (Text pp. 267),
such that
Cx = y,
(1)
where C M nn is a matrix containing complex numbers. In this case, each term can
be divided into the real number and the
EMAE 250.100: Homework 4
February 3, 2011
1. In some problems, it is possible to obtain a complex systems of equations (Text pp.
267), such that
Cx = y,
(1)
where C M nn is a matrix containing complex numbers. In this case, each term
can be divided into t
Homework 3 Solution
1. Determine the approximated root of the following equation:
f (x) = 5x3 3x2 + 6x 2
(a) [1pt] Using three iterations of the Newton-Raphson method with the initial guess,
x0 = 1.
(b) [1pt] Using three iterations of the secant method wi
EMAE 250.100: Homework 3
January 27, 2011
1. Determine the approximated root of the following equation:
f (x) = 5x3 3x2 + 6x 2
(a) [1pt] Using three iterations of the Newton-Raphson method with the initial
guess, x0 = 1.
(b) [1pt] Using three iterations o
Homework 2 Solution
1. For the following function:
f (x) = 6x2 + sin x
(a) [1pt] Using the rst forward nite divided dierence method, compute the approximation
of the rst derivative of the above function at xi = 1 where the step size h = xi+1 xi =
0.1. Rep
EMAE 250.100: Homework 2
January 20, 2011
1. For the following function:
f (x) = 6x2 + sin x
(a) [1pts] Using the rst forward nite divided dierence method, compute the
approximation of the rst derivative of the above function at xi = 1 where the step
size
Homework 1
1. [2pts] Derive Taylor series expansion for the following function from xi = 0:
f ( x) = e x .
Solution: Since f (n) (xi ) = exi = 1 for n = 1, 2, . . . and f (xi ) = 1, we have
f (x) = f (xi ) +
n=1
f (n) (xi )
(x xi )n =
n!
n=0
xn
n!
2. For
EMAE 250.100: Homework 1
January 13, 2011
1. [2pts] Derive Taylor series expansion for the following function from xi = 0:
f (x) = ex .
2. For the following function:
f (x) = sin x
(a) [2pts] Derive zero to third order Taylor series approximation of xi+1