Mathematics coursework
Order Description
Marks The total mark is 20. Some marks will be allocated for properly documented and con- structed M-les and a properly constructed report
What to Hand In Your report should consist of ? 10 A4 pages of text, with printouts of your commented M-les. Books, lecture notes and other sources of information (e.g. WWW) should be properly referenced – that means that you give enough detail for someone else to nd the information you have used. You should attach a cover sheet to the report and ll in the details – get it from the coursework submission box. The whole collection should be stapled at the top left corner. There is no mark awarded for word-processing but you should consider constructing the report in LATEX. The reports cannot be returned, so we advise you to make a copy to keep for yourself.
Project This project examines the relationship between a random walk on the real line and the heat equation and should address the following : 1. Modify or write a script to simulate 100 steps of a random walk on the real line starting from zero with probability of moving left or right = 1/2 with x = 0.1 and t = 0.1. Use this code to plot some sample walks. 2. For 1000 samples plot a histogram of the position of the particles after 100 steps (ie at t = 10). Scale the histogram to approximate the probability density function. 3. Consider the heat equation ut = Duxx with x ? [5, 5] and assume zero Dirichlet boundary conditions (so that u(5, t) = u(5, t) = 0). Let x = 0.1 and x = 5 + x : x : 5 x so x1 = 5 + x = 4.9, x2 = 5 + 2x, . . . , x99 = 5 x = 4.9 and let uj ? u(xj, t). The derivative uxx can be approximated by uxx ? uj+1 2uj + uj1 x2 . Write out the ODE satised by u1, u99 and uj for j = 2, . . . , 98. Use ode23s to solve numerically the heat equation with initial data u50 = 1 and uj = 0 for j = 50. Plot the solution at time t = 10. Scale the solution at t = 10 so that 5 5 u(x, 10)dx = 1 and plot u(xj , 10) against xj . 4. Discuss briey the connection betweeen the random walk and the heat equation ut = Duxx
This question first appeared on Write My Essay

