Three algorithms

Here are three algorithms that I found pretty funny, and that make you think, while I was trying to find elegant solutions to some problem I faced.

The first algorithm is the Bruton algorithm, that allows you to convert a wavelength into the RGB space.
This is where I found that the equivalent color for a He-Ne laser is 255/66/0 !
Apparently, this algorithm is more or less heuristic, but there’s the fun with playing with color spaces !

The second algorithm is the Goertzel algorithm, which is a way to extract a single frequency component from s signal using a discrete time digital filters (this is an online method to detect a tone ! wow !)

The third algorithm is the Bresenham’s circle algorithm, that allows you to discretize in the most efficient way a circle on a set of pixels.

There is an algorithm that I like, because it cannot be implemented but is yet the most efficient way to sort a list (in time O(N) instead of O(Nlog(N)) for the famous Quicksort) : the spaghetti sort algorithm, that I discovered through Dr Goulu’s blog. Would it work with parallel computers ?

There’s another algorithm that I don’t like, it’s the Shor’s algorithm for factorization, since it tries to define the properties of something that doesn’t yet exist, quantum computers. Interestingly, Google and NASA have published the results the benchmark they’ve made obntheir D-Wave so called quantum computer. I don’t know what to think about the results…

2 thoughts on “Three algorithms

  1. […] Here are three algorithms that I found pretty funny, and that make you think, was I was randomly trying to find solutions to some problem I faced.  […]

  2. […] Here are three algorithms that I found pretty funny, and that make you think, was I was randomly trying to find solutions to some problem I faced.  […]

Comments are closed.