Question: ###### Please make a separate plot for each steps not on one plot on top of each other Question 2: Confined 2D random walk Brownian
###### Please make a separate plot for each steps not on one plot on top of each other
Question 2: Confined 2D random walk Brownian motion is the motion of a particle, such as a smoke or dust particle, in a gas, as it is buffeted by random collisions with gas molecules. Make a simple computer simulation of such a particle in two dimensions as follows. The particle is confined to a square grid or lattice LL squares on a side, so that its position can be represented by two integers i,j=0L1. It starts in the middle of the grid. In each step of the simulation, choose a random direction---up, down, left, or right---and move the particle one step in that direction. This process is called a random walk. The particle is not allowed to move outside the limits of the lattice---if it tries to do so, choose a new random direction to move in. (We choose an odd length for the side of the square so that there is one lattice site exactly in the center.) Write a program to perform a million steps of this process on a lattice with L=101. Plot the position of the particle for different numbers of steps (100,1000,10000,100000). [25 points]
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
