Professor Gilbert Strang
Office: E17420
email: gs@math.mit.edu
Office Hours by Appointment
Lecture:
 Tuesday and Thursday, 1011AM in 1190
 Tuesday, 34PM in 54100
Teaching Assistants:
 Jason Choi (choij@mit.edu). Office Hours by Appt.
 JanChristian Huetter (huetter@mit.edu)
 Florent Bekerman (bekerman@math.mit.edu)
Fall 2014 Exam Dates:
 Tuesday, Sep. 30th (26100), Solutions. Average: 78, Standard Deviation: 15.
 Thursday, Oct. 30th (Walker 50340), Solutions. Average: 86, Standard Deviation: 11.
 Thursday, Dec. 4th (Walker 50340), Solutions. Average: 82, Standard Deviation: 9.
Help Sessions:
 Monday 34PM in E17401Q (Office Hour with Florent Bekerman)
 Wednesday 45PM in 66168 (Help Session with JC Huetter)
Announcements:
 Congratulations on finishing 18.085! The final lecture is Tuesday, Dec. 9, at 10 am. Exam 3 and other graded assignments will be returned then.
 The 3pm lecture on Tuesday, Dec. 9 is CANCELED. Enjoy the break!
 Solutions and grades to exam 3 have been posted. If you have any discrepancies, please contact Jason to make an appointment on Wednesday or see Prof. Strang AFTER looking at the solutions.
 Any graded assignment not picked up in class can be picked up during Florent's office hour or from Prof. Strang's office 17420.
 The course Piazza is up! Please register by following this link: http://piazza.com/mit/fall2014/18085. You will get more rapid responses from the TAs and your peers through Piazza.
Additional Exam Practice:

Exam 3
Homework: [Fall 2014]
#9 (Due: Tuesday, Nov. 25 @ 10am), Solutions, courtesy of Shuai Li
A scan of the problems is here: Textbook Scan Compute the following convolutions:
 $(1, 2, 3) \ast (3, 2, 1)$
 $(1, 2, 3) \circledast (3, 2, 1)$
 $f(x) \ast \delta(xa)$
 $\delta(xa)\ast \delta(xb)$
 4.3: 21
 4.4: 1, 6, 8
 4.5: 1, 2, 8, 10, 12, 22
#8 (Due: Thursday, Nov. 13), Solutions
A scan of the problems is here: Textbook Scan 4.1: 1, 3, 7, 11, 13
 4.2: 1, 3
 4.3: 2, 8, 10
#7 (Due: Thursday, Nov. 6), Solutions
 Divide the square $1 \leq x \leq 1$, $1 \leq y \leq 1$ into 4 unit squares (not triangles!)
The values of $u$ are given at the 8 boundary points (call those values $u_E$
and $u_{NE}$ and $u_N$, ....) The only unknown is $U_0$ at the center.
The one TEST function is BILINEAR in each square: $V(x,y) = a + bx + cy + dxy$
It is zero around the boundary and 1 at the center point. What are $a, b, c, d$ for its 4 pieces in the 4 squares?
The one TRIAL function is also BILINEAR. It matches all 8 boundary values.
We only have to find its value $U_0$ at the center, in terms of those 8 boundary values.
 Write the weak form of Laplace's equation
 Substitute the 1 test function $v$ and the trial function with unknown value at the center point.
 Integrate the weak form to find that unknown value in terms of the 8 known boundary values.
#6 (Due: Thursday, Oct. 23), Solutions, courtesy of Boris Lipchin
 $u(x,y) = x + y  x^2 + y^2 $ solves Laplace's eqn.
 What is $v(x,y) = \nabla u$ ?
 What is the stream function $s(x,y)$ that satisfies the CauchyRiemann eqns $du/dx = ds/dy$ and $du/dy =  ds/dx$?
 The gradient $v(x,y)$ is perpendicular to every equipotential curve $u =$ constant. Find $g = \nabla s$ that is perpendicular to the streamlines $s =$ constant. Check that $g$ is perpendicular to $v$.
 These equipotential curves and streamlines are (ellipses) (parabolas) (hyperbolas). [Choose the correct answer]
 3.3: 1, 7, 8, 11
 3.4: 2, 4, 5
#5 (Due: Thursday, Oct. 16), Solutions, courtesy of Rachel Mok
A scan of the textbook problems is here: 3.1/3.2 Problems The Matlab problem is to approximate the eqn $+u'' + u = x$ by linear finite elements with boundary conditions $u(0)=0$ and $u(1)=0$.
 First find the solution $u= x + A sin x + B cos x$ (particular + null) with $A,B$ from boundary conditions.
 Then find the stiffness matrix $K $(for $u''$) and mass matrix $M$ for the $u$ term and the load vector $F$ for the right side $f(x)=x$.
 The $N$ equations to solve will be $(K + M)U = F$. This is for $N$ hat functions $\phi(x)$ centered at $x=h, 2h, ...,Nh$ with $(N+1)h = 1$. Solve for $N=4, 8, 16, 32$ and plot $ N=32$ against the true $u(x)$.
 The maximum error at meshpoints should decrease like $(1/N)^2$Does it?
 3.1: 5, 9, 11, 12, 13, 18
 3.2: 3, 17 (on cubic splines)
#4 (Due: Thursday, Oct. 9), Solutions, courtesy of Hyunwoo Yuk
 Problem 2.4.17 in the book has a square grid with 9 nodes and 12 edges. Count the zeros in $A'A$, find its main diagonal (degree matrix), and find its middle row with 4 and four 1's.
 Start with 4 nodes and all 6 edges. A is 6 by 4. (note: you have to use MATLAB/Julia/some other programming language for this problem. Attach printouts.)
 Find $A'A$.
 Then ground node 4 by $u_4 = 0$. Remove column 4 so $A$ is 6 by 3 with independent columns: invertible $A'A$. PUT IN RANDOM BATTERIES $b = rand(6,1)$.
 Solve $A'Au = A'b$, and find the voltage at node 1  do this 1000 times to find the average voltage $u_1$ at node 1.
 For the same 4node graph with all 6 edges, fix $u_1 = 1$ as well as $u_4 = 0$. The vectors $b$ and $f$ are zero and $C = I$.
 Solve for $u$ and $w$ and find the total current to node 4.
 2.7: 1, 2, 3, 4, 9 (Truss problems)
#3 (Due: Thursday, Sep. 25), Solutions, courtesy of Hyunwoo Yuk
 1.6: 27
 2.1: 3, 7, 8
 2.3: 7, 8, 24
 2.4: 1, 2, 7
#2 (Due: Thursday, Sep. 18), Solutions
 The following questions come from the course textbook. For this week ONLY, the problems in the book are provided, here.
 1.4: 7, 9, 11
 1.5: 9 (and find the eigenvalues by MATLAB/Julia)
 1.6: 3, 9, 20
 Master Equations. Please see the last page of the above posted link.
#1 (Due: Thursday, Sep. 11), Solutions
 $A$ = [1 3 2] is a 1 by 3 matrix and $A'$ = 3 by 1 transpose
 Find $K = A' * A$ and explain why this $K $is singular (many answers, all OK)
 Find all solutions to $Ku=0$.
 Compute $K^4 = A'AA'AA'AA'A$ by hand in a smart order
 Page 16 of the text multiplies our 2nd difference matrix $K$ (make it infinite to avoid boundary effects) by vectors ones = 1,1,1,.. linear 0,1,2,3,.. squares 0,1,4,9,...
 Do the same for cubes 0,1,8,27,.. and quartic 0,1,16,81,..
 Which ones give the wrong derivative and what is the error
 Multiply these vectors by the FORWARD 1st difference matrix $D_+$ and the CENTERED first difference matrix $D_0$ (infinite) and compare to the derivatives of $x^2, x^3, x^4$.
 Solve $u'' = \delta(xa)$ with $u(0)=0$ and $u'(1)=0$ (free). Graph $u(x)$ and explain what is happening at $x=a$ between 0,1
 Problem 1.2.9 on page 24 is about the 4th difference with coefficients 1,4,6,4,1. Where did those numbers come from and should you divide by a power of $h=\Delta x$ ?
 Problem 1.2.19 on page 25 is about $u'' + u' = 1$. Choose a finite difference approximation. Solve for $u$.
 Invert our $T$ matrix with $T_{11}=1$ and diagonals $1,2,1$ for $n=3$ and $n=4$. From the pattern guess a formula for any $n$. Can you show that your guess is the correct inverse (any $n$)?
Homework Notes:
 PLEASE PRINT YOUR NAME CLEARLY
 Good to underline your last name.
 The Class List with class numbers will be created from these homeworks.
 Homeworks are for learning. Discussion is OK. Write clear answers for the graders: please.
 Problems will often come from the 18.085 textbook on CSE. (Printouts / Graphs for MATLAB questions.)
 Section 1.1 is available on math.mit.edu/cse
 A printing of 1.1.27 has a typo (my name for a mistake)

These are the simplest corrections: Verify that
 K comes from A0 A0 ' (prime = transpose)
 T comes from A1 A1 '
 B comes from A2 A2 '
 (Those have 2 then 1 then 0 boundary conditions. They change from positive definite to semidefinite.)
 problem set 1.2 from CSE textbook
Notes from Class:
 Solution to Ku=F is u = K\F backslash in Matlab, K first !
 Join Piazza for this course: http://piazza.com/mit/fall2014/18085
 Notes from Tuesday afternoon
 Notes from Tuesday afternoon 17 Sep
Course Topics:
 Applied Linear Algebra
 Applied Differential Equations
 Fourier Methods
 Algorithms
 Course outline
Additional Information:
 Quotes collected by my 18.085 class
 Goals for the Course: See applications of calculus, ODE, linear algebra, and discrete methods without going into too much proof.
 Textbook: Computational Science and Engineering (WellesleyCambridge, 2007).
 Grades: Homework 25%, 3 quizzes 75%, no final exam. Please email Prof. Strang about conflicts with quiz dates.
 Use of MATLAB for tedious calculations is encouraged, however you need to know how to do the basic algorithms taught in the course by hand (at least for small matrices) for the quizzes.
Class Resources:
 Movie of elimination: moe.m , realmmd.m
 Code to create K,T,B,C as sparse matrices
 MATLAB's backslash command to solve Ax = b: ps, pdf
 Getting started with Matlab: http://ocw.mit.edu/OcwWeb/Mathematics/1806Spring2005/RelatedResources/