Skip to content

jtompkins/elementary-automata

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

elementary-automata

A simple program to generate images for Wolfram's elementary automata. The output looks like this (for rule 126):

rule 126 output

Usage

elementary-automata [<flags>] <rule> <file>

Flags

Flag What does it do? Default
-s How large is each generation? 1000
-g How many generations should be simulated? 1000
-c Create the initial generation with a centered "on" cell false
scale How large should each cell appear in the output image (in pixels)? 1
rule Which elementary automata rule should be used? (30, 50, 126, etc) N/

Running locally

  1. go get ./...
  2. go run main.go -c 126 ~/one-twenty-six.png (produces the image above)

Testing

You need Ginkgo, Gomega, and Counterfeiter installed to run the tests.

  1. go get ./...
  2. go generate ./...
  3. go test ./... or ginkgo -r

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages