10.2 Diffusion and Cellular Automata. Simulating Motion: Cellular Automata If all we have to work with is a grid of cells (spreadsheet), how can we simulate.

Slides:



Advertisements
Similar presentations
The 4 important interactions of photons
Advertisements

These describe matter. Starts with a “p”
Wave-Particle Duality
Solids, Liquids, and Gases
Chapter 7 Quantum Theory of the Atom Copyright © Houghton Mifflin Company. All rights reserved. What are the electrons doing in the atom? Why do atoms.
Atomic structure refresher…..
1 Stefano Redaelli LIntAr - Department of Computer Science - Unversity of Milano-Bicocca Space and Cellular Automata.
CITS4403 Computational Modelling Game of Life. One of the first cellular automata to be studied, and probably the most popular of all time, is a 2-D CA.
Chapter 11: Electromagnetic Waves
No friction. No air resistance. Perfect Spring Two normal modes. Coupled Pendulums Weak spring Time Dependent Two State Problem Copyright – Michael D.
Quantum Mechanics 101 Waves? or Particles? Interference of Waves and the Double Slit Experiment  Waves spreading out from two points, such as waves.
CELLULAR AUTOMATON Presented by Rajini Singh.
CELLULAR AUTOMATA Derek Karssenberg, Utrecht University, the Netherlands LIFE (Conway)
The Photoelectric Effect
Macquarie University The Heat Equation and Diffusion PHYS by Lesa Moore DEPARTMENT OF PHYSICS.
Today’s Plan Introduction to Artificial Life Cellular Automata
IGCSE Unit 2 Light Cambridge IGCSE Physics
Nawaf M Albadia Introduction. Components. Behavior & Characteristics. Classes & Rules. Grid Dimensions. Evolving Cellular Automata using Genetic.
Parallelization: Conway’s Game of Life. Cellular automata: Important for science Biology – Mapping brain tumor growth Ecology – Interactions of species.
1 The Physical Meaning of the Wave Function. 2 Superposition creates regions of constructive and destructive diffraction according to the relative incidence.
Modern Physics.
Wave-Particle Duality of Light
CITS4403 Computational Modelling Fractals. A fractal is a mathematical set that typically displays self-similar patterns. Fractals may be exactly the.
18.1 Electromagnetic Waves Opener #4 - Wednesday, March 10, 2010 Complete the following questions using complete sentences. Section 17.3 assessment pg.
Electromagnetic Waves. Electromagnetic Wave A transverse wave that transfers electrical and magnetic energy. Consists of vibrating electric and magnetic.
The Role of Artificial Life, Cellular Automata and Emergence in the study of Artificial Intelligence Ognen Spiroski CITY Liberal Studies 2005.
Chapter 11: Diffusion. Diffusion Diffusion refers to any process in which a substance or property spreads from one region to another: transfer of heat,
10.2 Random Walks. Random Walk A random walk refers to the apparently random motion of an entity. This is often the best model of a physical process (Brownian.
Multiscale Modelling Mateusz Sitko
Lukasz Grzegorz Maciak Micheal Alexis
OBJECTIVES 06-1 Define temperature. Explain how thermal energy depends on temperature. Explain how thermal energy and heat are related.
Chapter 13 States of Matter
Notes on Modeling with Discrete Particle Systems Audi Byrne July 28 th, 2004 Kenworthy Lab Meeting Deutsch et al.
More Accurate Rate Estimation CS 170: Computing for the Sciences and Mathematics.
1 Introduction to quantum mechanics (Chap.2) Quantum theory for semiconductors (Chap. 3) Allowed and forbidden energy bands (Chap. 3.1) What Is An Energy.
1 Cellular Automata and Applications Ajith Abraham Telephone Number: (918) WWW:
Introduction to Lattice Simulations. Cellular Automata What are Cellular Automata or CA? A cellular automata is a discrete model used to study a range.
Model Iteration Iteration means to repeat a process and is sometimes referred to as looping. In ModelBuilder, you can use iteration to cause the entire.
< BackNext >PreviewMain Section 1 Temperature What Is Temperature? Temperature is a measure of the average kinetic energy of the particles in an object.
Chapter 18 The Electromagnetic Spectrum and Light Colorful neon lights brighten up a walkway in Chicago’s O’Hare Airport.
Final Test Review Tuesday May 4 th 10:00am to 11:50am Relativity Quantum Mechanics.
Chapter 11 Whew! It's Hot!. Temperature and thermal energy.
5.1 Essential Questions What is temperature?
The probability of a particle escaping a given cell so that it can it can move either to the cell’s right or left can be calculated as: Where  is defined.
4th International Conference on High Performance Scientific Computing 4th International Conference on High Performance Scientific Computing A Framework.
Cellular Automata FRES 1010 Eileen Kraemer Fall 2005.
Cellular Automata Introduction  Cellular Automata originally devised in the late 1940s by Stan Ulam (a mathematician) and John von Neumann.  Originally.
Electrons as Particles and Waves
1 1.Diffraction of light –Light diffracts when it passes the edge of a barrier or passes through a slit. The diffraction of light through a single slit.
To Address These Questions, We Will Study:
The Dilemma  Particles have mass and a specific position in space (matter)  Waves have NO mass and NO specific position in space (light and energy)
Monday, March 30, 2015PHYS , Spring 2015 Dr. Jaehoon Yu 1 PHYS 3313 – Section 001 Lecture #15 Monday, March 30, 2015 Dr. Jaehoon Yu Wave Motion.
Activator: Why is the sun important? How does the heat get from this big, bright, ball in the sky to us?
Quantum Theory and the Electronic Structure of Atoms Chapter 7.
FROM THE LAST UNIT, WE TALKED ABOUT THE OLD MODELS OF THE ATOM IN THE PAST. THIS UNIT, WE WILL BE FOCUSING ON THE CURRENT MODEL, WHICH IS THE QUANTUM MECHANICAL.
Introduction to Physics and Astronomy (1) 2-1. Light and Black Body Radiation.
Elementary cellular automata
Spatio-Temporal Information for Society Münster, 2014
L – Modeling and Simulating Social Systems with MATLAB
Pedro Ribeiro de Andrade Münster, 2013
Spatio-temporal information in society: cellular automata
Determination of the thermal conductivity of a metal
Hiroki Sayama NECSI Summer School 2008 Week 2: Complex Systems Modeling and Networks Cellular Automata Hiroki Sayama
Chapter 14 Spatial Threshold Systems
Taking Aim at Moving Targets in Computational Cell Migration
Temperature and Thermal Energy
The Development of a New Atomic Model
Matter in Motion - all thing are made of tiny particles (atoms)
The Formation of a Packard Snowflake
Energy and Matter.
Presentation transcript:

10.2 Diffusion and Cellular Automata

Simulating Motion: Cellular Automata If all we have to work with is a grid of cells (spreadsheet), how can we simulate a random walk? Moving a value from one cell to an adjacent cell is simulated by changing the contents of the cells over time: time t time t +1

The Wave

Aside: The Wave/Particle Duality We tend to think of “true” motion as movement of an object from one location to another, and the wave phenomenon as an illusion of motion. But at the most fundamental level, energy and matter behave like both a particle (object) and a wave….

Aside: The Wave/Particle Duality Double-slit experiment (Young 1801): Light must be a wave, because interference produces more than two bands on screen. Photoelectric effect (Thomson 1899): Light must consist of particles, because light waves knock electrons out of a metal plate.

Cellular Automata A cellular automaton (plural automata) is a dynamical model discrete in space, time, and state (possible values, typically just 0 and 1). CA has a grid of cells, and a set of transition rules describing what happens to a cell based on its own state and the state of its neighbors. Simplest CA are one-dimensional….

1D Cellular Automata Sample rule: Look at a cell and its left and right neighbors. Change the cell according to the following table:

ExCellular Automata Each row is the state of the CA at a particular time step. First row has random values: = IF(RAND()>0.5, 1, 0) Subsequent rows have rule: =IF( OR (AND( A1=1,B1=1,C1=1), AND (A1=1,B1=0,C1=0), AND (A1=0,B1=0,C1=0)), 0, 1)

ExCellular Automata Drag second row, second column rightward to next-to-last Keep first and last columns (boundary conditions) constant Drag second row down 60 or 70 rows Use Conditional Formatting / Color Scales to color cells based on values Zoom out to view whole display Hit F9 key to restart with new initial conditions Experiment with other rules:

Diffusion: Cellular Automata in Nature

2D Cellular Automata

Diffusion Diffusion refers to any process in which a substance or property spreads from one region to another: transfer of heat, spread of dye in a liquid, motion of ants outward from a nest, etc. Diffusion has traditionally been modeled using differential equations / systems dynamics – averages over large regions of individuals. Modern advances in computing power allow us to use cellular automata to model diffusion at the level of individual ants, molecules, etc.

Diffusion & Cellular Automata We will study diffusion via cellular automata. With Excel, this becomes difficult:

Cellular Automata in Matlab So we will use Matlab to study CA: Industry standard Performs operations on entire table at once (no click-and- drag) Programs look much like pseudocode in textbook Free, open-source version called Octave

Application: Spreading of Fire

Initializing the System “Forest” is an n x n grid (lattice) of cells. Each cell is either empty (0) has a tree (1) or has a burning tree (2). n n probTree = probability of tree in cell probBurning = probability that the tree is burning

Cell Initialization Algorithm (Pseudocode) if a random number is less than probTree if another random number is less than probBurning assign 2 to the cell// tree is burning else assign 1 to the cell// tree is not burning else assign 0 to the cell// no tree

Cell Initialization (Matlab) grid = zeros(n); % N x N grid of zeros rand1 = rand(n); % N x N random in [0,1) rand2 = rand(n); grid(rand1 < probTree) = 1; grid(rand1 < probTree & rand2 < probBurning) = 2;

Cell Initialization (Matlab) pcolor(grid) axis square

Updating Rules We determine a cell’s new state at time t + 1 based on its current state (at time t ) and the state of the neighbors in its von Neumann neighborhood (N, S, E, W): N S W E site

Updating Rules If cell is empty, it stays empty at t + 1 If a cell has a burning tree, the tree is gone at t + 1 If a tree is adjacent to a burning tree, it catches fire with a probability (1 – probImmune ) A tree may also catch fire by being struck by lightning: probLightning

Applying a Function to Each Grid Point i indexes row; j indexes column Problem: what to do at boundaries? (i, j) (i-1, j) (i+1, j) (i, j+1) (i, j-1)

Absorbing Boundary Conditions Cells beyond perimeter are inactive (nothing west of column 1, nothing east of column n, nothing north of row 1, nothing south of row n).

Periodic Boundary Conditions Column 1 and column n are neighbors.

Periodic Boundary Conditions Row 1 and row n are neighbors.

Periodic Boundary Conditions This makes the space a torus.

Periodic Boundary Conditions In Matlab Matlab’s circshift function does this for us: >> a = [1 2 3; 4 5 6; 7 8 9] a = >> circshift(a, [0 1]) % W neighbors ans =

Translate Updating Rules to Matlab If cell is empty, it stays empty at t + 1 % no action necessary

Translate Updating Rules to Matlab If a cell has a burning tree, the tree is gone at t + 1 newgrid(oldgrid == 2) = 0;

Translate Updating Rules to Matlab If a tree is adjacent to a burning tree, it catches fire with a probability (1 – probImmune ) n = length(oldgrid); % length of one side havetree = oldgrid == 1; susceptible = rand(n) < (1 - probImmune); nfire = circshift(oldgrid, [1 0]) == 2; sfire = circshift(oldgrid, [-1 0]) == 2; efire = circshift(oldgrid, [0 -1]) == 2; wfire = circshift(oldgrid, [0 1]) == 2; adjacent = nfire | sfire | efire | wfire; newgrid(havetree & adjacent & susceptible) = 2;

Translate Updating Rules to Matlab A tree may also catch fire by being struck by lightning: probLightning newgrid(havetree & (rand(n) < probLightning)) = 2;