2D Four Colour cellular Automaton

21
1 2D Four Colour 2D Four Colour cellular Automaton cellular Automaton (Surface (Surface explorations) explorations) NKS-2006 NKS-2006 Dr Robert H Barbour Dr Robert H Barbour Unitec Unitec New Zealand New Zealand

description

2D Four Colour cellular Automaton. (Surface explorations). NKS-2006 Dr Robert H Barbour Unitec New Zealand. Wolfram Context. Open Problems and Projects . Six different mentions of ‘Gray Code’ One mention of exploring more than two colours in a cellular automaton. Problem. - PowerPoint PPT Presentation

Transcript of 2D Four Colour cellular Automaton

Page 1: 2D Four Colour cellular Automaton

1

2D Four Colour cellular 2D Four Colour cellular Automaton Automaton

(Surface (Surface explorations)explorations)

NKS-2006NKS-2006

Dr Robert H BarbourDr Robert H Barbour

UnitecUnitec

New ZealandNew Zealand

Page 2: 2D Four Colour cellular Automaton

2

Wolfram ContextWolfram Context

Open Problems and Open Problems and ProjectsProjects..

•Six different mentions of Six different mentions of ‘Gray Code’‘Gray Code’

•One mention of exploring One mention of exploring more than two colours in a more than two colours in a cellular automaton.cellular automaton.

Page 3: 2D Four Colour cellular Automaton

3

ProblemProblem

• A space is to be searchedA space is to be searched• Progress reports are required from Progress reports are required from

time to timetime to time• The search process must be The search process must be

replicable and reversiblereplicable and reversible• The algorithm describing the The algorithm describing the

search behaviour must be as search behaviour must be as simple as possiblesimple as possible

Page 4: 2D Four Colour cellular Automaton

4

A context: model solution as a A context: model solution as a Cellular automatonCellular automaton

• Cellular automata require two Cellular automata require two entities, andentities, and

–a display system, a display system, –agreed rules for managing agreed rules for managing entity behaviour entity behaviour

–a recording system is a recording system is useful.useful.

Page 5: 2D Four Colour cellular Automaton

5

MotivationMotivation

• To identify a spatial search algorithm that To identify a spatial search algorithm that

could model event time. could model event time.

• To identify a means of externalising the To identify a means of externalising the

algorithm to study its behaviour. algorithm to study its behaviour.

• To implement the algorithm in a suitable To implement the algorithm in a suitable

computing environment linking Gray Code computing environment linking Gray Code

and CA.and CA.

Page 6: 2D Four Colour cellular Automaton

6

The EntitiesThe Entities

• We have two ‘entities’.We have two ‘entities’.

– A two dimensional matrix of cells much like an A two dimensional matrix of cells much like an unshaded chess board.unshaded chess board.

– A space searching virtual ‘Ant’ that moves in A space searching virtual ‘Ant’ that moves in single steps from one cell to the next.single steps from one cell to the next.

Page 7: 2D Four Colour cellular Automaton

7

The AlgorithmThe Algorithm

• Move a Vant (virtual ant) from one cell to the next.Move a Vant (virtual ant) from one cell to the next.

– On leaving a cell change the cell colour in the On leaving a cell change the cell colour in the

following sequence: white-green-black-yellow.following sequence: white-green-black-yellow.

– On leaving a cell turn left 90On leaving a cell turn left 90o o if the cell colour if the cell colour

was black or yellow and right 90was black or yellow and right 90o o if the cell if the cell

colour was white or green.colour was white or green.

– Record the cell colour and the ant coordinates. Record the cell colour and the ant coordinates.

Page 8: 2D Four Colour cellular Automaton

8

Binary LogicBinary Logic

• Represents true and false conditionsRepresents true and false conditions• A basis of digital computing representationA basis of digital computing representation• Does not represent sequences of change Does not represent sequences of change

wellwell• 0,1,0,1,0,1,0,1,0,1… provides no 0,1,0,1,0,1,0,1,0,1… provides no

parsimonious way of distinguishing parsimonious way of distinguishing between sets of interactions.between sets of interactions.

• Langton’s Ant (demo Ant Farm here) Langton’s Ant (demo Ant Farm here) 2D two colour CA.2D two colour CA.

• Integer Sequence Integer Sequence A102358A102358 (Visit iterations) (Barbour, 2005) (Visit iterations) (Barbour, 2005) and and Integer Integer Sequence Sequence A102369A102369 (Iteration Intervals) (Barbour, 2005). (Iteration Intervals) (Barbour, 2005).

Page 9: 2D Four Colour cellular Automaton

9

Quaternary LogicQuaternary Logic

• Quaternary Logic adds representations that Quaternary Logic adds representations that

disambiguate the disambiguate the direction through sequencesdirection through sequences . .

• Two bits are required for the four Two bits are required for the four

representations (a Gray Code.).representations (a Gray Code.).

• 00, 01, 11, 10, 00, … note the single bit change00, 01, 11, 10, 00, … note the single bit change

Page 10: 2D Four Colour cellular Automaton

10

Quaternary Logic appliedQuaternary Logic applied

• Quaternary logic/Gray Code allows the reporting of Quaternary logic/Gray Code allows the reporting of

specific changes in cell visits.specific changes in cell visits.

– Cells in the grid unexplored (or forgotten)Cells in the grid unexplored (or forgotten)

0000

– Some cells explored (data added) Some cells explored (data added)

0101

– All cells explored (data complete)All cells explored (data complete)

1111

– Some cells forgotten (data lost)Some cells forgotten (data lost)

1010

Page 11: 2D Four Colour cellular Automaton

11

Interaction CycleInteraction Cycle

01

10

1100

false true

Becoming true, being explored

Becoming false, being forgotten

stable

unstable

unstable

Page 12: 2D Four Colour cellular Automaton

12

Interaction SequenceInteraction Sequence

00

01

11

10

00

Interaction Sequence

stable

Unstable

Unstable

Page 13: 2D Four Colour cellular Automaton

13

Change or not?Change or not?

00

00

0101

00

01

11Change

No Change

Change occurs, or not,

in sequenceEither

towards or away from

11 (or learning about cells’

space)

Page 14: 2D Four Colour cellular Automaton

14

The Binary tree of changeThe Binary tree of change

00

00

0101

00

01

11

11

01

11

01

01

00 00

00

11

10

Change

No Change

Completed sequence

No change

Page 15: 2D Four Colour cellular Automaton

15

Interaction World linesInteraction World lines• World line traces the actual status World line traces the actual status

sequence through the possible worlds in sequence through the possible worlds in an interaction.an interaction.

00

00

0101

00

01

11

11

01

11

01

01

00 00

11

World Line 00000111

World Line 00010101

Page 16: 2D Four Colour cellular Automaton

16

Demo hereDemo here

• This cellular automaton uses colours to This cellular automaton uses colours to distinguish where in the cycle of visits distinguish where in the cycle of visits the Ant has reached on any iterationthe Ant has reached on any iteration

• White White = 00 unexplored= 00 unexplored• Green Green = 01 exploring= 01 exploring• Black Black = 11 explored= 11 explored• Yellow Yellow = 10 forgetting= 10 forgetting

Page 17: 2D Four Colour cellular Automaton

17

Probability of a particular Probability of a particular outcome during a particular outcome during a particular

iterationiteration• From any particular start an assessment may be From any particular start an assessment may be

made of the probability of a particular outcome by made of the probability of a particular outcome by enumerating the possibilities during each iteration.enumerating the possibilities during each iteration.

• The first five iterations generate an integer sequenceThe first five iterations generate an integer sequence::– 00, 01, 11, 0000, 01, 11, 00– 1, 0, 0, 01, 0, 0, 0– 1, 1, 0, 01, 1, 0, 0– 1, 2, 1, 01, 2, 1, 0– 1, 3, 3, 11, 3, 3, 1– 2, 4, 6, 42, 4, 6, 4

– Leading to the conclusion that the most Leading to the conclusion that the most likely single outcome after the fifth iteration likely single outcome after the fifth iteration is 11 or ‘true’. is 11 or ‘true’.

– (see Integer Sequence A094266)(see Integer Sequence A094266)

Page 18: 2D Four Colour cellular Automaton

18

Probability of a particular Probability of a particular outcome over a number of outcome over a number of

iterations.iterations.• The cumulative totals from the columns of the four The cumulative totals from the columns of the four

alternatives gives the changing probabilities ‘going alternatives gives the changing probabilities ‘going forward’ from a particular status.forward’ from a particular status.

• 00, 01, 11, 01 representations.00, 01, 11, 01 representations.

1, 0, 0, 0.1, 0, 0, 0. falsefalse 2, 1, 0, 0.2, 1, 0, 0. falsefalse 3, 3, 1, 0.3, 3, 1, 0. falsefalse 4, 6, 6, 1.4, 6, 6, 1. moving to truemoving to true 6, 10, 10, 5.6, 10, 10, 5. moving to truemoving to true 12, 16, 20, 15. 12, 16, 20, 15. true or agreementtrue or agreement 28, 28, 36, 35.28, 28, 36, 35. true but moving awaytrue but moving away(see Integer Sequence A099423)(see Integer Sequence A099423)

Page 19: 2D Four Colour cellular Automaton

19

Interaction Model in useInteraction Model in use

• Space is searched by repeated cell visits.Space is searched by repeated cell visits.

• The pattern of visits can be exteriorised using the The pattern of visits can be exteriorised using the

recent path functionrecent path function and the and the cell visits functioncell visits function..

• The cellular automaton regularly ‘returns to base’ The cellular automaton regularly ‘returns to base’

• The status of visited cells in the searched grid is The status of visited cells in the searched grid is

known simultaneously on iterations: 4, 8, 32, 64, known simultaneously on iterations: 4, 8, 32, 64,

416, 832 that is Integer Sequence A094867, the 416, 832 that is Integer Sequence A094867, the

six completed single colour squares.six completed single colour squares.

Page 20: 2D Four Colour cellular Automaton

20

SummarySummary

• Search Status refers to the aggregate of cell visits Search Status refers to the aggregate of cell visits having the same attributes (colour or some other having the same attributes (colour or some other marker) in the searched space.marker) in the searched space.

• Two bits provides the representation, while Two bits provides the representation, while quaternary logic provides the underlying quaternary logic provides the underlying reasoning.reasoning.

• Unpredicted emergent regularities in some Unpredicted emergent regularities in some Integer sequences and unpredicted completed Integer sequences and unpredicted completed squares in the Ant Farm.squares in the Ant Farm.

• Relationship between Gray Code and CA shownRelationship between Gray Code and CA shown

Page 21: 2D Four Colour cellular Automaton

21

ReferencesReferences1.1. Barbieri,M., F. De Martini, G. Di Nepi, P. Mataloni (2003) Experimental Detection of Entanglement with Barbieri,M., F. De Martini, G. Di Nepi, P. Mataloni (2003) Experimental Detection of Entanglement with

Polarized PhotonsPolarized Photons arXivarXiv:quant-ph/0307003 v1 1 Jul 2003:quant-ph/0307003 v1 1 Jul 2003

2.2. Barbour, R.H. (2004) A099423.Online Encyclopaedia Integer of Sequences. Barbour, R.H. (2004) A099423.Online Encyclopaedia Integer of Sequences.

http://www.research.att.com/projects/OEIS?Anum=A099423http://www.research.att.com/projects/OEIS?Anum=A099423, A102358, A102369,, A102358, A102369,

3.3. Barbour, R.H. (2005) LQTL. in Beziau & Costa-Leite, UNILOG-2005 Handbook.Barbour, R.H. (2005) LQTL. in Beziau & Costa-Leite, UNILOG-2005 Handbook.

4.4. Barbour, R.H.& L.D. Painter (2004) A094266 Online Encyclopaedia of Integer Sequences. Barbour, R.H.& L.D. Painter (2004) A094266 Online Encyclopaedia of Integer Sequences.

http://www.research.att.com/projects/OEIS?Anum=A094266http://www.research.att.com/projects/OEIS?Anum=A094266

5.5. Barbour, R.H. & J Chapman (2004) A094867 Online Encyclopaedia of Integer Sequences. Barbour, R.H. & J Chapman (2004) A094867 Online Encyclopaedia of Integer Sequences.

http://www.research.att.com/projects/OEIS?Anum=A094867http://www.research.att.com/projects/OEIS?Anum=A094867

6.6. Beziau, J-V & A. Costa-Leite (eds) (2005) Handbook of the First World Congress and School on Universal Beziau, J-V & A. Costa-Leite (eds) (2005) Handbook of the First World Congress and School on Universal

Logic UNILOG'0 2005, Montreux – Switzerland http;//www.uni-log.org5 March 26th - April 3rdLogic UNILOG'0 2005, Montreux – Switzerland http;//www.uni-log.org5 March 26th - April 3rd

7.7. Chapman, J. (2004) Personal Communication.Chapman, J. (2004) Personal Communication.

8.8. Endriss, U. (2003) Modal Logic of Ordered Trees. Unpublished PhD Thesis, King’s College, London.Endriss, U. (2003) Modal Logic of Ordered Trees. Unpublished PhD Thesis, King’s College, London.

9.9. Ganguly, N. et al., (2003) A survey of Cellular Automata. Technical Report Centre for High Performance Ganguly, N. et al., (2003) A survey of Cellular Automata. Technical Report Centre for High Performance

Computing, Dresden University of Technology, December 2003.Computing, Dresden University of Technology, December 2003.

10.10. Gray, F. (1953) Pulse code communication, Gray, F. (1953) Pulse code communication, March 17March 17, U.S. , U.S. patentpatent no. 2,632,058. no. 2,632,058.

11.11. Hazelhurst, S. (1996) Compositional Model Checking of Partially ordered state spaces. DPhil Thesis Hazelhurst, S. (1996) Compositional Model Checking of Partially ordered state spaces. DPhil Thesis

University of British Coilumbia.University of British Coilumbia.

12.12. Prior, A. (1967). Prior, A. (1967). Past Present and FuturePast Present and Future: Oxford University Press.: Oxford University Press.

13.13. Sarkar P. (2000), A Brief History of Cellular Automata. ACM Computing Surveys. Vol. 32 No. 1 March.Sarkar P. (2000), A Brief History of Cellular Automata. ACM Computing Surveys. Vol. 32 No. 1 March.

14.14. Wolfram, S.(2002) A New Kind of Science, Wolfram Media, Champaign, IllinoisWolfram, S.(2002) A New Kind of Science, Wolfram Media, Champaign, Illinois