What I'd like to see in Golly
Re: What I'd like to see in Golly
I've "invented" a new type of neighborhood (inspired by http://www.sq3.org.uk/Evolution/Squirm/): given our cell and it's neighborhood. Using some moving rules given in rule table cell can either move into empty square or stay in place. Cells can also "communicate", if to cells are going to occupy same cell in next generation, both will stay in one place to prevent collision. Number of cells will be preserved, like in Squirm
First question ever. Often referred to as The Question. When this question is asked in right place in right time, no one can lie. No one can abstain. But when The Question is asked, silence will fall. Silence must fall. The Question is: Doctor Who?
- Tim Hutton
- Posts: 64
- Joined: May 20th, 2010, 7:30 am
- Contact:
Re: What I'd like to see in Golly
There's a lot of fun to be found in this direction. Take a look at artificial chemistries, which are much like cellular automata except that the cells can move around instead of being fixed in place. When I was playing with Squirm I hadn't come across artificial chemistries.Wojowu wrote:I've "invented" a new type of neighborhood (inspired by http://www.sq3.org.uk/Evolution/Squirm/): given our cell and it's neighborhood. Using some moving rules given in rule table cell can either move into empty square or stay in place. Cells can also "communicate", if to cells are going to occupy same cell in next generation, both will stay in one place to prevent collision. Number of cells will be preserved, like in Squirm
If we make the movement random and restrict interactions to be between just two cells (atoms) then we could define a rule table format something like this:
n_states:2
neighborhood:square_lattice_chemistry_2atoms
symmetries:none
0,1 : 1,1
If we started off with most atoms in state 0 but one in state 1, then soon all the atoms would become state 1 as they bumped into each other.
Is that the sort of thing you mean?
Implementing all this in a normal CA is possible but a little tricky, it's not really a natural fit. The square9_reading_order neighborhood might be a starting point, but it's not currently supported in Golly. (Talk to me if you're keen to have it.) Or the Margolus neighborhood, which also supports movement naturally.
Some artificial chemistries to have a look at:
Organic Builder
Living Physics
Re: What I'd like to see in Golly
It isn't exactly what I thought, but your idea is intresting. Here is what I mean: consider 3x3 block with our cell in middle. Middle cell is marked 0 and its neighbors are marked 1-8 clockwise starting from upper cell. If middle cell has state n other than zero and its neighbors have states n1, n2 etc. with some of them zero we make transition rule: n,n1,n2,0,0,n5,n6,n7,0,a and a is one of neighbors which are empty (here 3,4 or or 0. Then our cell will move to this empty space, or stay in place if transition is zero. As I saidbefore, if two cells are going to occupy same neighbor, they will both stay in place.
Another thing I would like in Golly is a bit of uncertainity. If next state in transition rule is variable which wasn't earlier used, program will randomly choose state in next generation. Every state should have same probabillity (also die of cell should have same probability)
Another thing I would like in Golly is a bit of uncertainity. If next state in transition rule is variable which wasn't earlier used, program will randomly choose state in next generation. Every state should have same probabillity (also die of cell should have same probability)
First question ever. Often referred to as The Question. When this question is asked in right place in right time, no one can lie. No one can abstain. But when The Question is asked, silence will fall. Silence must fall. The Question is: Doctor Who?
-
- Posts: 80
- Joined: September 16th, 2011, 10:29 pm
Re: What I'd like to see in Golly
Make ruletables support randomness!
Here's how it might work:
If the ruletable has conflicting rules,and if the ruletable has some sort of "random" property, it will randomly choose one of the conflicting rules and run it.
This will be extremely useful for lattice-gas simulations.
Here's how it might work:
If the ruletable has conflicting rules,and if the ruletable has some sort of "random" property, it will randomly choose one of the conflicting rules and run it.
This will be extremely useful for lattice-gas simulations.
- Tim Hutton
- Posts: 64
- Joined: May 20th, 2010, 7:30 am
- Contact:
Re: What I'd like to see in Golly
This is not a bad idea. It would mean that the hashlife approach wouldn't work but that's OK for lattice gas and similar since hashlife only helps if the pattern has repetition. We'd have to make a new algorithm for it in Golly but that's OK too. Maybe call it RuleTableNoHashlife or something.edwardfanboy wrote:Make ruletables support randomness!
Here's how it might work:
If the ruletable has conflicting rules,and if the ruletable has some sort of "random" property, it will randomly choose one of the conflicting rules and run it.
This will be extremely useful for lattice-gas simulations.
In terms of the rule table format, we could just add an optional new line like conflicts:random. These files will be rejected by the RuleTable algorithm and picked up by RuleTableNoHashlife. (Could also then support conflicts:take_first (the default), conflicts:take_last and conflicts:give_error.)
Code: Select all
# just an idea, not yet supported!
neighborhood:vonNeumann
n_states:14
symmetries:permute
conflicts:random
0,1,0,0,0,1
0,1,0,0,0,0
Re: What I'd like to see in Golly
I meant exactly that! You have just found another way of implementing that. But that would need a change in rule tables. I've many rule tables, and none of them have conficts:something. I think that a good way to miss error messages is to made some things default in rule tables:
1. Neighborhood by default can be Moore
2. Symmetries by default can be none
3. Conflicts by default should be take_first
4. N_states can be calculated by largest number in used rule table
BTW why 4. isn't implemented now? Is that really as hard to do?
1. Neighborhood by default can be Moore
2. Symmetries by default can be none
3. Conflicts by default should be take_first
4. N_states can be calculated by largest number in used rule table
BTW why 4. isn't implemented now? Is that really as hard to do?
First question ever. Often referred to as The Question. When this question is asked in right place in right time, no one can lie. No one can abstain. But when The Question is asked, silence will fall. Silence must fall. The Question is: Doctor Who?
Re: What I'd like to see in Golly
My first idea can have one advantage that your one would be harder to make. If one variable will have {0,0,0,1,1,1,1,1,2,3} then state 0 will have probability 30%, state 1 50%, state 2 and state 3 10%. It can be also done with your method like in this
Code: Select all
NOT YET IMPLEMENTED
conflicts:random
0,1,0,0,0,0
0,1,0,0,0,0
0,1,0,0,0,0
0,1,0,0,0,1
0,1,0,0,0,1
0,1,0,0,0,1
0,1,0,0,0,1
0,1,0,0,0,1
0,1,0,0,0,2
0,1,0,0,0,3
First question ever. Often referred to as The Question. When this question is asked in right place in right time, no one can lie. No one can abstain. But when The Question is asked, silence will fall. Silence must fall. The Question is: Doctor Who?
- Tim Hutton
- Posts: 64
- Joined: May 20th, 2010, 7:30 am
- Contact:
Re: What I'd like to see in Golly
Yes, we should definitely allow variables to appear as the output. Our example would be:Wojowu wrote:My first idea can have one advantage that your one would be harder to make. If one variable will have {0,0,0,1,1,1,1,1,2,3} then state 0 will have probability 30%, state 1 50%, state 2 and state 3 10%.
Code: Select all
# just an idea, not yet supported!
neighborhood:vonNeumann
n_states:14
symmetries:permute
conflicts:random
var a = {0,0,0,1,1,1,1,1,2,3}
0,1,0,0,0,a
Yes, this is fine, we wouldn't be breaking anything. Those files will continue to work correctly using either the existing RuleTable algorithm or the proposed RuleTableNoHashlife algorithm. New files that include conflicts:random will only work in RuleTableNoHashlife.Wojowu wrote:But that would need a change in rule tables. I've many rule tables, and none of them have conficts:something.
-
- Posts: 80
- Joined: September 16th, 2011, 10:29 pm
Re: What I'd like to see in Golly
This could be another way of simulating randomness.
Here is an example rule table:
The random( ) block in the above ruletable should be replaced (before variable substitution) with
0,a,0,0,0,1 or
0,0,a,0,0,1 or
0,0,0,a,0,1 or
0,0,0,0,a,1 .
It should choose between these rules randomly with equal probability (in this case they will have 1/4 probability),
but it will ignore any rules that cannot be run.
I hope any moderators reading this can understand, because adding this would allow you to make a ruletable
for 3-state von-Neumann lattice gases (above)!
Here is an example rule table:
Code: Select all
# 0 Background
# 1 Gas
# 2 Vent (creates gas)
n_states:3
neighborhood:vonNeumann
symmetries:none
var a={1,2}
var b={0,1,2}
var c={b}
var d={b}
var e={b}
random(
0,a,0,0,0,1
0,0,a,0,0,1
0,0,0,a,0,1
0,0,0,0,a,1
)
1,b,c,d,e,0
0,a,0,0,0,1 or
0,0,a,0,0,1 or
0,0,0,a,0,1 or
0,0,0,0,a,1 .
It should choose between these rules randomly with equal probability (in this case they will have 1/4 probability),
but it will ignore any rules that cannot be run.
I hope any moderators reading this can understand, because adding this would allow you to make a ruletable
for 3-state von-Neumann lattice gases (above)!
Re: What I'd like to see in Golly
Another thing that can be made in Golly (I don't think this one is hard to make) is a new type of simulating 1D neighborhoods. I am thinking about something similar to evolution of Wolfram rules in Golly; given starting pattern next state of 1D universe is computed and is placed below first one. I know we can made another rule in Moore neighborhood, but then rule tables will be much longer. Else, can someone made script which creates such Moore-neighborhood rule given ruletable with 1D neighborhood?
First question ever. Often referred to as The Question. When this question is asked in right place in right time, no one can lie. No one can abstain. But when The Question is asked, silence will fall. Silence must fall. The Question is: Doctor Who?
- Tim Hutton
- Posts: 64
- Joined: May 20th, 2010, 7:30 am
- Contact:
Re: What I'd like to see in Golly
Either I've misunderstood or that won't work. If you do the replacement for every cell the same then they all the particles will move in the same direction on each timestep. If you do the replacement differently for each cell then there is no guarantee that the number of particles will remain the same.edwardfanboy wrote:This could be another way of simulating randomness.
Here is an example rule table:The random( ) block in the above ruletable should be replaced (before variable substitution) withCode: Select all
# 0 Background # 1 Gas # 2 Vent (creates gas) n_states:3 neighborhood:vonNeumann symmetries:none var a={1,2} var b={0,1,2} var c={b} var d={b} var e={b} random( 0,a,0,0,0,1 0,0,a,0,0,1 0,0,0,a,0,1 0,0,0,0,a,1 ) 1,b,c,d,e,0
0,a,0,0,0,1 or
0,0,a,0,0,1 or
0,0,0,a,0,1 or
0,0,0,0,a,1 .
It should choose between these rules randomly with equal probability (in this case they will have 1/4 probability),
but it will ignore any rules that cannot be run.
I hope any moderators reading this can understand, because adding this would allow you to make a ruletable
for 3-state von-Neumann lattice gases (above)!
We can implement proper lattice-gases with the previous suggestions for randomness but we will need to keep hold of the two ideas that a) particles are little arrows moving in a particular direction, and b) more than one particle can be in a cell at a time. I can't see any other way of doing it.
I've just opened a discussion on RuleTableNoHashlife on the golly-test list, by the way. I think it would be very nice to have.
Re: What I'd like to see in Golly
Music like that! will be very cool!
Is beautiful that please without concept
Re: What I'd like to see in Golly
A simple enhancement suggestion… when viewing patterns downscaled, the entire live pattern will be colored per state 1. I understand not including color interpolation, but if a given pixel represents an area that only has cells of a state N≠1, it should be possible to color those correctly tho, shouldn't it? Large LifeHistory etc. patterns would become a lot more legible with just this one tweak.
Re: What I'd like to see in Golly
If you want to play with 3D CAs then try Ready (http://code.google.com/p/reaction-diffusion/). See the bays_3D.vti example file.Pilou wrote:Golly 3D !
Re: What I'd like to see in Golly
Certainly possible, but expensive to compute -- a pixel might have billions of cells -- so we'd have to make this feature optional and only do it below a certain scale limit, say 2^5:1. This is definitely a feature I'd love to see, but the code changes are non-trivial. Hopefully one day!Tropylium wrote:... I understand not including color interpolation, but if a given pixel represents an area that only has cells of a state N≠1, it should be possible to color those correctly tho, shouldn't it? ...
Re: What I'd like to see in Golly
We can already do colour interpolation very efficiently, as the pattern is stored as a quadtree (except in QuickLife, which only supports one state anyway!). For a proof-of-concept, see the attached image, which is the direct output of my quadtree-editing program, CAVE.I understand not including color interpolation
In Golly, I wouldn't recommend adding this functionality, since it involves increasing the size of a node in memory (by three bytes, if you want TrueColour). An increase from 20 bytes to 23 bytes per quadtree node would require significantly more memory (15% more, to be precise) to run a pattern.
Unless, of course, we add that as an optional feature (let's say as another algorithm, RuleTableColoured). However, altering the existing code to accommodate those three extra bytes seems like a daunting task, and Tom Rokicki has far more important things to do.
- Attachments
-
- Zoomed-out image of my G-to-C-to-G loop.
- corder-loop.PNG (45.93 KiB) Viewed 16630 times
What do you do with ill crystallographers? Take them to the mono-clinic!
Re: What I'd like to see in Golly
Agreed. The primary concern I think should be a RuleTableNoHash algorithm, possibly followed by either larger neighborhoods or probabilistic CA (larger neighborhoods can already be emulated by rule tables with additional states, though. Probablistic CA would be nice, but would be hard to do efficiently.)
- Extrementhusiast
- Posts: 1966
- Joined: June 16th, 2009, 11:24 pm
- Location: USA
Re: What I'd like to see in Golly
What would be useful would be a new type of geometry: mirror, in which the simulation is mirrored "over the edge". (In this way, one half of a symmetric pattern will be placed next to the "mirror", within the grid, while the other side would be extrapolated from the first side.) This would be very useful for hand-searches of symmetric oscillators, as one does not have to do a complex and tedious process of mirroring random soups.
I Like My Heisenburps! (and others)
Re: What I'd like to see in Golly
Assuming I understand you correctly, I think a Perl/Python script could do what you want. A useful starting point might be the make-torus.py script included with Golly.Extrementhusiast wrote:What would be useful would be a new type of geometry: mirror, ...
Re: What I'd like to see in Golly
Yes, the script Andrew describes is similar to an old one I made, called 'octuple.py'. I use this to construct a pattern in all eight orientations, to ensure it is constructible with 'synthesise-pattern.py' independent of orientation.
Code: Select all
# Produce eight copies of the universe, one for each orientation:
import os
import golly as g
from glife import *
# Ensure that a non-empty pattern has been provided:
r = g.getrect()
if len(r)==0: g.exit("There is no pattern.")
clist = g.getcells(r)
# Double:
x = r[0]
y = r[1]
w = r[2]
h = r[3]
g.putcells(clist, x-y + w + 10, y-x - w - 10, 0, 1, 1, 0)
# Quadruple:
r = g.getrect()
clist = g.getcells(r)
x = r[0]
y = r[1]
g.putcells(clist, 2*x-20, 0, -1, 0, 0, 1)
g.putcells(clist, 0, 2*y-20, 1, 0, 0, -1)
g.putcells(clist, 2*x-20, 2*y-20, -1, 0, 0, -1)
What do you do with ill crystallographers? Take them to the mono-clinic!
Re: What I'd like to see in Golly
I'd like to request 3 little features...
1) display population count when the user selects an area
useful in many situations, like checking if the pattern has minimum population, without having to make multiple layers.
2) cache the original window size when maximized
when I maximize and close golly, it remembers the maximum window size. Not too nice.
3) script autosave, much like rule autosave
It would be nice if we could save a golly script inside the clipboard directly to the scripts directory, just like saving rules.
EDIT: Thought of one more. How about the adding the functionality of creating and deleting files from the patterns/scripts pane?
1) display population count when the user selects an area
useful in many situations, like checking if the pattern has minimum population, without having to make multiple layers.
2) cache the original window size when maximized
when I maximize and close golly, it remembers the maximum window size. Not too nice.
3) script autosave, much like rule autosave
It would be nice if we could save a golly script inside the clipboard directly to the scripts directory, just like saving rules.
EDIT: Thought of one more. How about the adding the functionality of creating and deleting files from the patterns/scripts pane?