In complex emergent systems (not to be confused with complicated) the macro behavior of the system is irreducible to the individual components. Some systems that exhibit this type of behavior are flocks, ecosystems and economies. One approach to studying such systems is to create computer simulations. Within these simulations one can attempt to model individual agents of the system with some degree of verisimilitude. Then, when the simulation is run, one can verify if there hypothesis about the behaviors and interactions of individual agents leads to the expected macro, system level behavior.
SwarmJS is a simple framework for creating such simulations and running them in the browser. An example of Craig Reynolds classic 'Boids' model built using this framework can be seen here.
Project Euler is a fantastic resource for algorithmic and mathematical problems. It has hundreds of problem descriptions and offers answer verification. Aaron Ward and I wanted to make the process of working through Project Euler problems in JavaScript (or CoffeeScript) an easier process. Enter EulerJS, a command line tool for working through project Euler problems. Available on NPM as euler.
In order to determine whether or not two objects are colliding or within a certain distance of each other, to avoid an O(n^2) algorithm, an intelligent data structure decision must be made.
A quadtree is a data structure that partitions two dimensional space. It is a tree in which every internal node contains exactly four children, which correspond to the four quadrants of the area demarcated by that node. The root node encapsulates the entirety of the desired space.
With this data structure you can do useful things such as quickly determine what Uber cars are within a specific range of a customer in O(logN) time. My quadtree implementation is available on npm as generic-quadtree.
ng-Eocities is a library of Angular directives that pays homage to the internet of yesteryear. It contains recreations of the deprecated html tags marquee and blink, a figlet generator, image pixelator and more. It is available on bower as ng-eocities. An example of the contained directives can be seen here (turn down volume).
John Conway's Game of Life is everyone's favorite cellular automata. The rules of the game are simple. The world consists of a grid of cells. Each cell may be either alive or dead. On each tick, or discrete unit of time in the simulation, the following rules hold:
1) If a cell is alive, then if 2 or 3 of it's neighbors are alive, it stays alive.
2) If fewer than 2 of it's neighbors are alive, then it dies of loneliness.
3) If more than 3 of it's neighbors are alive, it dies of overcrowding. If a cell is dead, then if exactly three of its neighbors are alive, it comes alive through reproduction.
The application of these rules to large worlds of cells leads to fascinating and often beautiful emergent patterns within the system.
Tab of Life is a new tab chrome extension. Every time a user opens a new tab a randomized Game of Life is initiated and run within the new tab. It's a fun and entrancing way to begin your web browsing.
Available on the Chrome Store
Hacker Muse is chrome extension so that you can keep a compulsive eye on how your most recent Hacker News post is doing. It was built as a collaborative project with Aaron Ward who was the design wiz. I wired up the logic to integrate with Hacker News' Firebase API and the Chrome Storage API.