Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/phrb/3d-spanning-tree
Python script for generating 3d spanning trees.
https://github.com/phrb/3d-spanning-tree
Last synced: 18 days ago
JSON representation
Python script for generating 3d spanning trees.
- Host: GitHub
- URL: https://github.com/phrb/3d-spanning-tree
- Owner: phrb
- Created: 2014-07-17T02:35:48.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2016-10-01T01:38:29.000Z (about 8 years ago)
- Last Synced: 2023-08-03T06:10:12.717Z (over 1 year ago)
- Language: Python
- Size: 701 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Spanning Trees in a Cube
------This python script generates a tree that tries to reach
every node of a cube exactly once, i.e., makes a 3d maze.The tree obey certain rules, or "walking modes", defined
by functions in the script:Random Walk: Chooses a new direction for each point,
with no other heuristic than the random number generator.Weighted Walk: Has a propension to favor a point's previous
direction in new extensions.Depth Walk: Extends in a single direction until it finds
an occupied cell or the end of the cube.Shell Walk: Extends until it can, then change direction and
continue extending, making same-colored paths that span the
"shell" of the cube.Usage:
$ python span_tree.py [ ]
![walks](https://github.com/phrb/3d-spanning-tree/raw/master/Walks.png)