Tag Archives: visualisation

Conway’s Game of Life: 3D

Another MRes Processing assignment, and on this occasion – something cellular automata related.

In an effort to again try out some Processing ideas that I hadn’t used before, the application created for this is 3D.

The application itself is based on Conway’s Game of Life, the basic idea of which is “to start with a simple configuration of counters (organisms), one to a cell, then observe how it changes as you apply Conway’s ‘genetic laws’ for births, deaths, and survivals”.

The initially defined rules are:

  • Survivals. Every counter with two or three neighbouring counters survives for the next generation.
  • Deaths. Each counter with four or more neighbours dies (is removed) from overpopulation. Every counter with one neighbour or none dies from isolation.
  • Births. Each empty cell adjacent to exactly three neighbours–no more, no fewer–is a birth cell. A counter is placed on it at the next move.

For this version of it a cell’s neighbours are the 2 cells either side of it in each of the 3 planes. The rules used are:

  • Survivals – cells with 2 live neighbours will continue as they are
  • Deaths – cells with 0 or more than 4 live neighbours
  • Births – cells with 1, 3 or 4 live neighbours

In the application the dead cells are coloured green, live cells start off pink and get brighter turning yellow and then white depending on how long they’ve been alive.

As the neighbour cells being used to determine the future of each call do not wrap this can lead to the edges of the cube becoming permanently white. The two examples below show how this can, but doesn’t always, happen.

In these versions the dead cells are not drawn.

Advertisements

London Bike Hire Journeys – 29th April 2011

The most recent MRes Processing assignment was to show the flow of journeys from a day of London bike hire usage. My previous Processing visualisations have all been quite dynamic, the kind that run through data on their own. For this one I decided to take a different approach. It’s an interactive visualisation where the user can click on any of the bike hire stand locations to see where the journeys went to from that stand.

The when the app starts it looks like this

London Bike Hire Flows 1

The size of the stand locations shows the number of journeys from that location. Clicking on a stand then shows which other stands those journeys went to

London Bike Hire Flows 2

The brightness of the line indicates the number of flows from the clicked stand to the stand the line goes to.

Some of the stands didn’t have any journeys made from them – I assume that the stand existed but wasn’t fully open on the day the data is taken from.

London Bike Hire Flows 3

If the user prefers to have more of an idea where the stand locations are, pressing space will display a map background instead of the more basic one

London Bike Hire Flows 4

Overall I’m really pleased with how it has turned out. I think it’s quite useful for seeing the journeys made from each of the hire stands, and I like the way it looks.

Here’s a video showing the app in use

A Week of Tweets in London

A visualisation of a week’s worth of geocoded tweets that were all in or around Greater London.

It’s a fairly simple Processing app, displaying each tweet in order. The ellipses displayed at each point though stay for 5 seconds, getting gradually smaller and darker with each second. The best way I could think to do that was with a fading point class for each tweet. This is then poked every second to both update, and then return whether it should be removed from the stack of points or not.

Playing around with this also reminded me how to sort an ArrayList. My Java knowledge is slowly returning..