Monday Connect: Elevator Algorithms

Somewhere in the world it is Monday now, correct? Just sending out just another small bit of interesting, perhaps obscure things I come across on the web to have at least something to read here once a week under monday-connect (help me with ideas, suggestions taken).

We talk and sometimes bemoan the influence of algorithms - hey do you ever wonder where that word algoritm came from? It’s hardly new, according to Merriam Webster:

It was formed from algorism “the system of Arabic numerals,” a word that goes back to Middle English and ultimately stems from the name of a 9th-century Persian mathematician, abu-Jaʽfar Mohammed ibn-Mūsa al-Khuwārizmi, who did important work in the fields of algebra and numeric systems.

But do you ever consider the algorithm of elevators? Spend some time enjoying this interactive explanation of elevators from a site called john.fun


This diagram is animated on the https://john.fun/elevators site for the SCAN algorithm that was created in 1961.

Everyone has shared the frustration of waiting for an elevator that never seems to arrive. “I pressed the button, why isn’t it coming?” you ask. For something as commonplace as elevators, they are far more complex than meets the eye.

Over the course of this article, we’ll unravel the mysteries of elevators. The way you push their buttons, and how they push yours.

If you are like me I had no idea about thus much complexity behind the button for an elevator! This is but one if many interesting interactives on the main john.fun site, and I cannot help but wonder if he is a friend of the person who makes more of these at neil.fun.

There us much fun still to be had on the open web and much of it, created by individuals like John, might be seen as educational or of use.

Now where is that darned elevator?

1 Like

Confirming it’s Monday here, Alan! :smile:

Love this explanation. And it confirmed my suspicion about Destination Dispatch – it seems like wait times in those buildings should be shorter (because of extra advance knowledge which floor everyone is going to) but it feels like you’re stuck waiting forever.

After I clicked the link, I had the very same thoughts as you – the site is basically a clone of neal.fun; the domain pattern is the same, even the visual language is the same. I suspect the author was “somewhat inspired” by it…? (HackerNews submissions: neal.fun had posts back in 2019, john.fun goes back to 2023). – If someone goes so far in cloning (especially before powerful AI!), that seems like the ultimate flattery.

Both Neal and John are great and remind me of the work of the OG in this space, Bartosz Ciechanowski. When Bartosz posts, it’s Christmas time.

PS: Good recent discussion about Elevators on HackerNews:

PS2: Math-related cousin: BetterExplained – kind of like 3Blue1Brown (which is very visual and has given us Manim Python library for those who would like to make their own visual explanations).

1 Like