Skip to content

Instantly share code, notes, and snippets.

Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@augeas
augeas / cyclic_id.ipynb
Created October 18, 2021 17:55
cyclic 1-dimensional cellular automata
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@augeas
augeas / glf.ipynb
Last active May 15, 2019 11:47
Generalised logistic function
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@augeas
augeas / ca_fft.ipynb
Created August 23, 2017 00:42
In which the current and previous states of elementary 1D cellular automate rules 30 and 86 are treated as spectra, and inverse-Fourier transformed into sound.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@augeas
augeas / merry_christmas_mr_lorenz.py
Created August 2, 2016 18:34
Lorenz attractor noises, made by reasonably analogue synths.
from collections import namedtuple
import pygame
from pygame import midi
from pygame import time
class attractor(object):
def __init__(self,dt,scales,variables=['x','y','z']):
self.dt = dt
@augeas
augeas / index.html
Created August 21, 2015 12:27
Shonky javascript which I wrote for the image-processing module of an A-level physics course a *very* long time ago.
<html>
<head>
<script language="JavaScript">
var grid_dim = 16;
var pens = new Array("#000000","#202020","#404040","#606060","#808080","#A0A0A0","#C0C0C0","#FFFFFF");
var dx = new Array(0,1,0,-1,-1,1,1,-1,0);
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@augeas
augeas / collatzeral_damage.py
Last active August 29, 2015 14:21
Collatzeral Damage
# Licensed under the Apache License Version 2.0: http://www.apache.org/licenses/LICENSE-2.0.txt
# Collatzeral Damage. Giles R. Greenway, May 2015.
# Collatz conjecture MIDI sounds.
import pygame
from pygame import midi
from pygame import time
# Mersenne numbers give the Collatz conjecture a good run for its money.
def mersenne():
@augeas
augeas / 30th_rule_is_eat_veggie_kielbasa.py
Last active August 29, 2015 14:21
30th rule *is*: eat veggie kielbasa
# Licensed under the Apache License Version 2.0: http://www.apache.org/licenses/LICENSE-2.0.txt
# Here's Looking at Euclid. Giles R. Greenway, March 2015.
# Elementary 1-D cellular automata beats.
# Just putting it out there: http://tinyurl.com/wolframsacrank
import pygame
from pygame import midi
from pygame import time
@augeas
augeas / heres_looking_at_euclid.py
Created March 2, 2015 12:33
Here's Looking at Euclid...
# Licensed under the Apache License Version 2.0: http://www.apache.org/licenses/LICENSE-2.0.txt
# Here's Looking at Euclid. Giles R. Greenway, March 2015.
# Euclidian poly-rhythms...
import itertools
# http://www.pygame.org/docs/ref/midi.html
import pygame
from pygame import midi
from pygame import time