Jump to content

File:2D Random Walk 400x400.ogv

Page contents not supported in other languages.
This is a file from the Wikimedia Commons
From Wikipedia, the free encyclopedia

2D_Random_Walk_400x400.ogv (Ogg Theora video file, length 11 min 7 s, 400 × 400 pixels, 218 kbps, file size: 17.34 MB)

Summary

Description
English: One million steps in a two-dimensional random walk, at 1500 steps per second. At each step, the particle randomly moves to any one of the eight positions in its Moore neighbourhood. The grid is 400x400 square with toroidal boundary conditions (i.e. going off one edge reappears on the opposite edge). Generated with MATLAB using my own script - video has 20000 frames. The steps slowly fade out exponentially at 0.9999^t (a version showing all the steps taken is here). Encoded with Ogg Theora at 600 kbps: video has noticeable compression artifacts, but these do not appear to significantly detract from quality. MATLAB source code shown below:

tmax=20000;%the maximum time
x=1;       %the number of particles
n=400;     %the size of the square grid
pos=randi(n/2,2,x)+n/4; %initial position of particles.
vel=randi(3,2,x)-2;     %initial velocity of particles.
img=zeros(n);
r=1;
for t=1:tmax
    for q=1:50 %how many steps per frame
        img=0.9999*img;%reset the image but with a shadow or trail.
        for i=1:x
            img(pos(1,i),pos(2,i))=img(pos(1,i),pos(2,i))+10;
        end
        vel=randi(3,2,x)-2; %velocity of particles.
        pos=pos+vel;
        pos=mod(pos-1,n)+1;
    end
    imwrite(img./11,[num2str(t) '.png'],'png');
end

Date
Source Own work
Author Purpy Pupple
Other versions
All the places where this random walk has covered.
A static trace of a different random walk generated with a similar but different algorithm.

Licensing

I, the copyright holder of this work, hereby publish it under the following licenses:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.
GNU head Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled GNU Free Documentation License.
You may select the license of your choice.

Captions

Add a one-line explanation of what this file represents

Items portrayed in this file

depicts

14 January 2011

application/ogg

da621e40b03e5c47f29121a4cae40f1dcbbbdbdc

18,181,201 byte

666.533333333333 second

400 pixel

400 pixel

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current22:47, 15 January 201111 min 7 s, 400 × 400 (17.34 MB)Dllu{{Information |Description={{en|1=One million steps in a two-dimensional random walk, at 1500 steps per second. At each step, the particle randomly decides whether to go up, down, left, or right. The grid is 400x400 square with toroidal

Global file usage

The following other wikis use this file:

Metadata