The
1
freaq
bookmarklet

One of my students, Zach Pomerantz, created a bookmarklet called freaq that is an audio visualizer for YouTube. Very cool. He also gave a great presentation about his process for making this bookmarklet and for using npm.

Read More

The N-Queens Problem

Eight Queens is a well-known algorithmic problem. How many ways can you place eight queens on an 8x8 chessboard so that none of the queens threaten each other. Following the rules of chess, one queen threatens another when it is in the same row, column, or diagonal. N-Queens in the more general problem of solving this for any n queens on an n x n chessboard.

Read More

Flooring a Number with Bitwise OR

Somewhere along the way, I stopped using JavaScript’s Math.floor() function and I started using bitwise OR 0 such as in the following example:

Read More

Testing for Prime Numbers

It seems like a common toy problem is writing a function that tests whether or not a number is prime (only divisable by itself and 1). This toy problem, however, soon started a discussion on how much could be gained by using a prime sieve (such as the Sieve of Eratosthenes or the Sieve of Sundaram) for finding all primes in a range instead of simply looping through and testing each number. Three of us quickly wrote up a few different versions and tested them in JS Perf. You can find the results here.

Read More

The Galaxy Zoo Kaggle Competition

Back in February, a few colleagues and I decided to go for our first Kaggle competition! We entered the Galaxy Zoo challenge to classify galaxy morphologies. For some of us, this was the first time doing machine learning. And many of us hadn’t done any image processing or feature extraction before.

Read More