Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Markov Random Walks A Markov Random Walk in a process where at every step you pick whether you go to the left or right

image text in transcribedimage text in transcribed\image text in transcribedimage text in transcribed

Markov Random Walks A Markov Random Walk in a process where at every step you pick whether you go to the left or right with a specific probability. A simple example of this would be flipping a coin everytime you arrived at a junction to determine which way you went. Random walks are powerful processes which can be used in a variety of applications such as foraging animal movement, the movement of molecules in a gas or liquid and to track a gamler's spending at the casino. In this module we will be looking at one-dimensional Random Walks on the integers Z. An example of the process of a random walk is: 1. Start at the origin, o 2. Flip a coin 3. Take one step right (i.e. +1) if the coin is heads, take one step left if the coin is tails (i.e. -1). 4. Flip a coin 5. Take one step right (i.e. +1) if the coin is heads, take one step left if the coin is tails (i.e. -1). 6. ... As can be seen from the process above, the random walk only depends on the state it currently is in and has no memory. The probabilty of moving right or left does not have to be symmetric and so the coin can be replaced with a random number generator rand(). If a random number is generate it is tested to see if it is bigger or smaller than the probability of moving right and then the required movement is undertaken Exercise 1 Write a matlab function that generates a one-dimensional random walk. The random walker starts from the origin x= 0 and at each discrete step jumps 1 unit distance to the right or left with probabilities PR and pL = 1- PR, respectively. The input variables to the matlab function are the probability PR and the number of steps (N), and the output is a single vector containing all the positions of the walker after each step. Start your function with the line function walk = randomWalk (pR, N) Show/hide hint Check your code visually by running it and plotting the output random walk trajectory i.e. position vs time. Use different values of PR and N: the symmetric case PR = pl = 0.5, PR = 0.7 and PR = 0.4, for 10, 100 and 1000 iterations. walk generator Submit your M-file for your random below: Browse... No file selected. Upload your M-file 0% Exercise 2 Write a matlab script that repeatedly runs your function written in part 1 (at least 5 times). and plots the trajectories on the same graph. Browse... No file selected. Upload your M-file 0% Use your script to visually investigate the random walks for different values of the parameters Nand pR. Then briefly describe and submit your observations and submit three representative graphs as examples. Use title to list the values of pR and N used. Use the figure number below to can refer to them in the text. Enter answer Figure 1 Browse... No file selected. Upload your PNG 0% Figure 2 Browse... No file selected. Upload your PNG 0% Figure 3 Browse... No file selected. Upload your PNG 0%

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

Machine Learning And Knowledge Discovery In Databases European Conference Ecml Pkdd 2017 Skopje Macedonia September 18 22 2017 Proceedings Part 3 Lnai 10536

Authors: Yasemin Altun ,Kamalika Das ,Taneli Mielikainen ,Donato Malerba ,Jerzy Stefanowski ,Jesse Read ,Marinka Zitnik ,Michelangelo Ceci ,Saso Dzeroski

1st Edition

3319712721, 978-3319712727

More Books

Students also viewed these Databases questions

Question

Have I incorporated my research into my outline effectively?

Answered: 1 week ago