Problem 2.1.8
Part (a)
Define a Mathematica function representing the candidate solution.
u x ,t
Exp
^2 t
c
Sin x
t 2
c
sin x
Define a Mathematica function that applies the problems differential operator to any function f . The
residual f
: c D f, t
D
Hwk #6 solution notebook
Plots for 5.3.2 (a)
In[1]:=
Out[1]=
n ,x
Sin n Pi x
sin n x
In[2]:=
n
n ^ 2 Pi ^ 2
Out[2]=
n2 2
In[3]:=
fn n
21
Out[3]=
In[4]:=
In[41]:=
2 Integrate Sin n Pi x Exp x ,
1
2
n
n2
Element n, Integers , n
n
1
fSum M , x
Plot
x, 0, 1
Math 5310 Fall 2010
Homework #4 solutions
1. The binary operation
1
( f , g) =
f ( x ) g ( x ) dx
1
is clearly symmetric, ( f , g) = ( g, f ). It also bilinear,
1
( f + g, h ) =
1
1
f + g h dx =
f h dx +
1
1
g h d x = ( f , h ) + ( g, h )
1
and simila
Math 5310, Homework #4 Solutions
Problem 3: Comparing several fifth-degree polynomial approximations to a function
fx
Sin 3 x
1;
Compute the Taylor series approximation
(Note: Mathematica appends a symbol representing the order of accuracy of the series.
Math 5310 Fall 2010
Homework set #3 SOLUTIONS
1. See Mathematica notebook
2. If the members of S are LD, then a nontrivial constant vector R N such that
N
i i (x) = 0
x [ a, b ] .
i =1
By hypothesis, i C ( N 1) [ a, b]. Differentiation is linear and the
Homework #3 solutions
Problem 1
Set up the Gram matrix and the RHS vector from the projection theorem.
AM
: Table Integrate x ^ i
j , x, 0, 1
bM
: Table Integrate x ^ i Exp
, i, 0, M , j, 0, M
x , x, 0, 1
, i, 0, M
Write a function that solves the system.
Math 5310 Fall 2010
Homework set #3, solutions
Problem 1
Part (a)
The Laguerre polynomials are differentiable so we can use the Wronskian. In this case, the Wronskian matrix
is upper triangular with diagonal elements (1, 1, 1, 1). (You might ask yourself
Math 5310 Fall 2010
Homework set #2 SOLUTIONS
1. See Mathematica notebook
2. Algebra with oating point numbers
(a) Suppose our FP scheme keeps four digits and an exponent. For example, it can store a = 1.234
and b = 5.678 105 . It can add a + a to nd 2.46
Math 5310 Fall 2010
Problem set #2
Problem 1
fx
2 Tanh x
Plot f x , x,
x;
3, 3
1.0
0.5
3
2
1
1
2
3
0.5
1.0
Looks like theres a root at about 1.9. Ill use that as the initial guess.
A single step of Newtons method is
xn
1
xn
f xn
f xn
.
Well write a Mathem
Math 5310 Fall 2010
Homework set #1 SOLUTIONS
1. Problem 1.1:
(a)
(b)
(c)
dx
dt
+ xt = 0 is a linear ODE.
u
2 u
t x2 = (1 + t ) sin x is a linear
w
w
t + w x = 0 is a nonlinear PDE
PDE
2. Problem 1.5
(a) Try x (t) = et/2 as a candidate for solution to 1.1
Homework #6 solutions
Math 5311 Spr 2010
Problem 5.1.8
2
Part (a) The null space of K D , aka ker (K D ) , is the subspace of CD such that K D u = 0. To nd the kernel, then,
we need to solve the differential equation
Ku = au + bu = 0.
This is a second-ord