Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Simulation of Browman Motion in One Dimension Observe what happens when sunbeams are admitted into a building and sited light on its shadowy places. You

image text in transcribed

Simulation of Browman Motion in One Dimension Observe what happens when sunbeams are admitted into a building and sited light on its shadowy places. You will see a multitude of tiny particles mingling in a multitude of ways... their dancing is an actual indication of underlying movements of matter chat are hidden from our sight.. It originates with the atoms which move of themselves [i.e., spontaneously]. Then those small compound bodies that tire least removed from the impetus of the atoms are set in motion by the impact of their invisible blows and in turn cannon against slightly larger bodies. So, the movement mounts up from the atoms and gradually emerges to the level of our senses, so that those bodies are in motion that we see in sunbeams, moved by blows that remain invisible. De Reram Natura, Lucretius, c, 50 BCE Brownian motion is the random motion of particles suspended in a fluid (a liquid or gas) resulting from their collision with the fast-moving atoms or molecules in the fluid^3. Imagine you are a tiny particle suspended in a fluid. Or maybe you are average-sized and standing on a sidewalk. A very long sidewalk. One that stretches to infinity in both directions Not having much impetus of your own in move in any one direction (e.g. forward, left, up) and sometimes you take step in the other (e.g. backward, right, down). Which way you go is random. You flip a coin (a.k.a. roll Id2) and go forward if it lands on heads, and so backwards if it lands on tails. This process is known as a random walk. If you take n steps in this way. Where do you end up? And how did you end up there^4? Now it's your turn. Write a function which takes as input an integer number of steps and performs a random walk of that many steps and returns the sequence of distances from the initial starling position. For example: >> A = random walk(10) A = -1 -2 -3 -4 -3 -4 -5 -6 -7 -6 You can make a quick and dirty visualization of this by using the plot function, plot function > > plot(A) If you were to count how many times each distance occurred in the array, you would know how many times you occupied each spot. You can find the unique elements of an array using the unique function. >> unique (A) SDS = -7 -6 -6 -4 -3 -2 -1 You can find how many tunes a value occurs in an array using the length and find functions >> length (find (A==-3)) ans = 2 If you were lo take a random walk of a given length many limes, you would get many different trajectories, that all start from the same place, bill all end up in different places, and all visit the locations (distances from start) different numbers of times. You can then find out how far, on average, you end up from the start, and how many times, on average, you visit each location. You can even act an average trajectory^3

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Hands On Database

Authors: Steve Conger

1st Edition

013610827X, 978-0136108276

More Books

Students also viewed these Databases questions

Question

2. What type of team would you recommend?

Answered: 1 week ago