[Golly] Random Fill probability < 1%

For scripts to aid with computation or simulation in cellular automata.
Post Reply
User avatar
DivusIulius
Posts: 94
Joined: April 1st, 2009, 11:23 am
Contact:

[Golly] Random Fill probability < 1%

Post by DivusIulius »

Just a quick question: Is there a way in Golly to get Random Fill probabilities inferior to 1% with/without scripting?.

Thanks in advance. :wink:
User avatar
Andrew
Moderator
Posts: 1053
Joined: June 2nd, 2009, 2:08 am
Location: Melbourne, Australia
Contact:

Re: [Golly] Random Fill probability < 1%

Post by Andrew »

Here's a (clumsy) way without scripting:

- Create an empty selection and randomly fill it at 50%.
- Use Prefs > Edit to change the percentage to 1%.
- Randomly fill the selection again (now at 1%).
- Copy this 1% selection to the clipboard.
- Undo back to the 50% selection.
- Edit > Paste Mode > And.
- Edit > Paste to Selection.
- Now the selection density should be about 0.5%.

Clearly if you want to do this a lot it would be better to write a custom script. A good place to start would be random-fill.py in the scripts database (Help > Online Archives > Golly Scripts Database, then ctrl-click on that script).
Use Glu or Glui to explore CA rules on non-periodic tilings: DominoLife and HatLife and SpectreLife
User avatar
DivusIulius
Posts: 94
Joined: April 1st, 2009, 11:23 am
Contact:

Re: [Golly] Random Fill probability < 1%

Post by DivusIulius »

Andrew wrote:Here's a (clumsy) way without scripting.
Hey, such a sweet idea! Thank you!
Post Reply