This is the book being followed in this course. The course is taught by Professor Jeffrey R. Chasnov.
A. Matlab Notes:
- A good place to get an understanding of Matlab is this. Matlab is generally case-sensitive. More on case sensitive here
- Several expressions, separated by comma or semicolons, can be placed on a single line.
- Semi-colon at the end of the line suppresses the value of the expression in that line. Else, the value is displayed.
- Ax = b; x is solved using the backslash operator as: x = A\b;
- A = LU; LU decomposition of a matrix is obtained as: [L, U] = lu(A)
- Ax = L(Ux) = b; x is solved as : x = U(L\b)
- Eigenvalues: lambda = eig(A)
- Eigenvalues & Eigenvectors: [V, D] = eig(A). V is matrix of Eigenvectors and D is the matrix of Eigenvalues. The eigenvalues are on the leading diagonal of D. The first eigenvalue corresponds to the first column eigenvector in V and so on and so forth.
- fzero is the matlab function that is used to find root of a non-linear function.
- interp1 is the matlab function that is used for 1-D interpolation including cubic spline interpolation.
- ode45 is the matlab function that is used for integrating ODEs.
B. Week 1:
- Learnt how to use MATLAB.
- Understood the concept of logistic map. This video by Veritasium provides a good explanation.
- Mathematically, Logistic Map is written as xn+1 = rxn(1-xn).
- xn is a number between zero and one, that represents the ratio of existing population to the maximum possible population.
- r is the growth rate of the population.
- Computed & presented the bifurcation diagram for the logistic map in MATLAB.
C. Week 2:
- Learnt three methods for finding roots viz. Bisection method, Newton method & Secant method.
- Newton’s method is the fastest (speed of convergence), followed by Secant method and then Bisection method.
- The order of convergence for the three methods are: Bisection: 1, Secant: 1.6, Newton: 2. The order of convergence signifies with what power the error decreases.
- Bisection method would always provided a solution, while the Newton method will only provide solution when an analytical derivative for the function exists.
- Secant method is a way for resolving the above shortcoming of Newton method. It approximates the derivative when the derivative for the function doesn’t exist.
- A fractal is a geometrical object that looks similar on all scales. The Newton Fractal is explained in this video.
- Period doubling route to chaos.
- Computed the Feigenbaum Delta by solving the logistic map until the period 11 cycle of r.
D. Week 3:
- Gaussian elimination without pivoting may lead to wrong answers while solving a system of linear equations due to round-off error.
- Partial Pivoting means row interchange. Complete Pivoting means both row and column interchange.
- Gaussian elimination with partial pivoting generally obviates the problem of wrong answers due to round-off errors. This was one of the greatest discoveries in Numerical Analysis.
- LU decomposition of a matrix using partial pivoting. Post LU Decomposition, we can use backward and forward substitution to solve a system of linear equations. This link explains the LU decomposition.
- LU decomposition is superior to Gaussian elimination, when the right hand side of the equation keeps on changing (for instance in PDEs). Thus, we can do the LU decomposition once, and then used backward & forward substitution repeatedly as the right hand side keeps on changing. Gaussian elimination scales as O(N3). Forward and Backward substitutions scale as O(N2).
- Computed & Plotted the fractal by solving the Lorenz Equations.
E. Week 4:
- Quadrature is numerical integration.
- Learnt the Midpoint Rule, Trapezoidal Rule & Simpson Rule. Learnt Quadrature rules viz. Composite, Gaussian and Adaptive. Matlab uses Adaptive Quadrature.
- Learnt interpolation methods viz. linear, polynomial. Cubic Spline is a cubic polynomial spline interpolations between different points on the curve.
- In the project computed the first five positive roots of the first six Bessel Functions.
F. Week 5:
- Euler Method is a first order method of solving ODE. Let the differential equation be dx/dt = f(t,x), with the initial condition X(t0) = X0
- Euler’s Method can be summarized as marching forward from an initial condition in this fashion: xn+1 = xn + tdelta f(tn, xn)
- Learnt the Runge-Kutta (RK) the method. Learnt the Modified Euler Method and its expression as a Second order Runge-Kutta Method. Also, the General Second order, Third Order Runge-Kutta Method. Further, an example of Fourth order Runge-Kutta Method.
- Matlab uses Adaptive Runge-Kutta (RK) methods where itself figures appropriate tdelta. We need to specify only the error tolerance. Smaller the error tolerance, smaller will be tdelta and more expensive the computation.
- ode45 (Matlab Function) uses Dormand Prince Method which is a six stage (fifth order) Runge-Kutta method.
- Solved the two body problem (predict the motion of two massive objects which are abstractly viewed as point particles. The problem assumes that the two objects interact only with one another; the only force affecting each object arises from the other one, and all other objects are ignored) using ode45.
G. Week 6:
- Initial Value problems are solved by marching forward while boundary value problems can be solved by solving by solving for all interior points in one go.
- Learnt how to solve Laplace and 1-D and 2-D Diffusion Equations PDEs using Finite Difference Method.
- Explicit Solution of the Diffusion Equation may become unstable (the values at next time steps exploding) at large time steps. Implicit Solution guarantees that the solution wouldn’t become unstable. Crank-Nicolson is an implicit method to solve Diffusion Equation.
- Three implicit methods to solve the Laplace Equation are Jacobi Method, Gauss-Siedel Method and SOR Method.