Homework 7 solution sketches
Math 371, Fall 2011
Assigned: Saturday, October 28, 2011
Due: Thursday, November 3, 2011
Clearly label all plots using title, xlabel, ylabel, legend
Use the subplot command to compare multiple plots
Include printouts of all Ma
1
chapter 6 : numerical integration
Z 1
0
f (x)dx
ex :
Z 1
0
e
x2
n
X
ci fi , ci : coefficients , fi = f (xi ) , xi : points
i=0
dx = 0.7468 . . . , consider xi = ih , h =
right-hand Riemann sum
1
n
, i = 0, . . . , n : uniform
trapezoid rule
R(h) = f1 h
Math 371
Winter 2013
Homework 9
due: Tuesday April 23
There are several Matlab exercises on this assignment; it is not necessary to turn in the code.
1. Consider f (x) = sin x for 4 x 4. Find the Taylor series for f (x) about x = 0
up to the x7 -term. Usi
Math 371
Winter 2013
Homework 4
due: Tuesday February 19
Solve the problems by hand, but you may use Matlab or a calculator to do arithmetic or
check your answers. All vector norms and matrix norms are the 1-norm.
1. Consider the equations,
2x1 + 3x2
x3 =
1
chapter 7 : time-dependent dierential equations
ordinary dierential equations
Let x(t) be the position of a particle moving on the x-axis at time t.
1st order ODE
dx
= f (x) : velocity is a function of position
dt
x(0) : initial position
The problem is
Math 371
Winter 2017
Homework 2
due: Tuesday January 24
Some problems have a yes/no answer, but to obtain full credit you need to explain your answer.
It is not necessary to submit the Matlab code (unless the assignment specifically requests it).
1. Let f
Math 371
Winter 2013
Homework 3
due: Thursday February 7
1. In class we discussed the equation of state of chlorine gas as an example of root-finding.
The example uses Newtons method to compute the gas volume, given the pressure and
temperature, determine
Math 371 Winter 2017 Homework 3
Garrett McPeek
f ( x)
f ' ( x)
2
n a
( P+ 2 )(V nb)nRT
V
In this case, V 3=V 2
2
n a
2n 2 a
(P+ 2 )+(
)(V nb)
V
V3
1. Newton's method:
g ( x)= x
Now, using V2 = 12.651099337119016 and the other parameters as given, we can
1
chapter 3 : numerical linear algebra
3.1 review of linear algebra
a11 x1 + a12 x2 + + a1n xn = b1
a21 x1 + a22 x2 + + a2n xn = b2
.
.
an1 x1 + an2 x2 + + ann xn = bn
: system of linear equations for x1 , . . . , xn
We can write the system in 3 other for
1
chapter 2 : root-finding
def : Given a function f (x), a root is a number r satisfying f (r) = 0.
p
ex : f (x) = x2 3 ) r = 3
question : How can we find the roots of a general function f (x)?
2.1 bisection method
idea : Find an interval [a, b] such that
Math 371
Winter 2017
Homework 3
due: Thursday February 02
1. In class we discussed the equation of state of chlorine gas as an example of root-finding.
The example uses Newtons method to compute the gas volume, given the pressure and
temperature, determin
Math 371
Winter 2013
Homework 1 due: Tuesday January 22
Please write neatly, explain your answers, and staple the sheets together.
0. (optional) Give a brief description of your academic background and interests. If you work
in a lab or research group, pl
1
chapter 4 : computing eigenvalues
4.1 introduction
problem : Given A, find and x 6= 0 such that Ax = x.
: e-value (e.g. frequency, growth rate, energy level)
x : e-vector (e.g. normal mode, principal component, bound state)
thm : Assume A is real and sy
Math 371
Winter 2013
Homework 6
due: Thursday March 21
1. Consider the linear system, 2x1 + x2 = 1, x1 + 2x2 =
1, with solution x1 = 1, x2 =
1.
a) Write Jacobis method in component form and take three steps starting from initial guess
x0 = (0, 0)T . Prese
Math 371
Winter 2013
Homework 8
due: Tuesday April 9
1. Recall the matrix Ah in the finite-dierence solution of the boundary value problem discussed
in class (steady state heat conduction). It was stated in class that (BJ ) = cos h, (BGS ) =
sin h
cos2 h,
Math 371 Review Sheet Solutions for Midterm Exam Winter 2013
1. True or False? Give a reason to justify your answer.
a) TRUE (10101.01)2 = 24 + 22 + 1 + 14 = 16 + 4 + 1 + 0.25 = (21.25)10
b) TRUE
D+ D f (x) = D+ (D f (x) = D+
=
1
h
f (x+h) f (x)
h
f (x) f
Math 371 Review Sheet for Midterm Exam Winter 2013
The midterm exam is on Thursday February 28 in class. It will cover all the class material up to
and including Thursday February 21. You may use a calculator to do arithmetic and one sheet
of handwritten
Math 371
Winter 2013
Homework 2
due: Tuesday January 29
Some problems have a yes/no answer, but to obtain full credit you need to explain your answer.
1. Let f (x) = 1 + x2 1.
a) Evaluate f (x) for x = 0.1 using 4-digit arithmetic. Show all intermediate s
Math 371
Winter 2013
Homework 7
due: Tuesday April 2
This exercise concerns the two-dimensional BVP discussed in class. Consider a metal plate
on the unit square D = cfw_(x, y) : 0 x, y 1. The plate temperature (x, y) satisfies
the Laplace equation xx + y
1
chapter 2 : root-finding
def : Given a function f (x), a root is a number r satisfying f (r) = 0.
ex : f (x) = x2 3 r = 3
question : How can we find the roots of a general function f (x)?
2.1 bisection method
idea : Find an interval [a, b] such that f (
1
20
Thurs
3/28
chapter 5 : polynomial approximation and interpolation
5.1 introduction
problem : Given a function f (x), find a polynomial approximation pn (x).
application :
Z b
a
f (x)dx !
Z b
a
pn (x)dx , . . .
one solution : The Taylor polynomial of
Math 371 Winter 2013 Homework 5 due: Thursday March 14
announcement : on Feb 19/21 and March 12/14, both sections will meet in 133 Chrysler
This assignment consists of Matlab programming exercises. In class we considered the twopoint boundary value proble
Math 371
Winter 2017
Homework 1 due: Tuesday January 17
Please write neatly, explain your answers, and staple the sheets together.
0. (optional) Give a brief description of your academic background and scientific interests. If you
work in a lab or researc
Homework 11 Solutions
Math 371, Fall 2011
(1) (Richardson Extrapolation) P. 454 #11
(a) Adding the Taylor series for f (x0 + h) and f (x0 h) gives
f (x0 + h) + f (x0 h) =
h4
h8 (8)
h8
2f (x0 ) + h2 f (x0 ) + f (4) (x0 ) +
f (x0 ) +
[f (8) ( ) f (8) (x0 )]
Homework 6
Math 371, Fall 2011
Assigned: Thursday, October 20, 2011
Due: Thursday, October 26, 2011
Clearly label all plots using title, xlabel, ylabel, legend
Use the subplot command to compare multiple plots
Include printouts of all Matlab code, labe
Homework 5
Math 371, Fall 2011
Assigned: Sunday, October 9, 2011
Due: Thursday, October 20, 2011
Clearly label all plots using title, xlabel, ylabel, legend
Use the subplot command to compare multiple plots
Include printouts of all Matlab code and outp