Lego Math Maniac

Though I have lived in Southern California for several years, I have never been to Legoland, a theme park based around the classic (and awesome) children’s toys.  The park perennially sits in the shadow of more popular parks in the region (e.g. Disneyland, Universal Studios, and the Banana Club Museum), and its prices make it hard to justify a visit for an adult male with no children, no matter how many fond Lego memories he may have from his childhood.  However, given the recent attention Lego has received in the context of mathematics, it may be time to finally plan a trip.

A recent article on Wired’s website discusses the mathematics of Lego – more specifically, it highlights an article on the complexity of Lego systems.  As any child will tell you, Lego sets can vary from very simple, small sets, to much larger and more complicated ones.  As a simple corollary, smaller sets will have fewer pieces, and larger sets will have more pieces.  But how does the number of types of pieces grow as the size of the set grows?  For example, if a 100 piece set consists of 10 different types of pieces, is it reasonable to guess that a 1000 piece set will consist of 100 different types of pieces?

In a word, no.  Though the number of different types of pieces will grow as the size of a set grows, it will grow slower than the size of the set (in other words, it will grow sub-linearly).  To put it another way, as the size of the Lego set grows, rather than building more and more new types of pieces, the same types of pieces that are present in smaller sets tend to be used in new ways.  The effect is that the proportion of distinct piece types decreases as the size of the set grows.  From a mathematical standpoint, if we let y denote the number of different types of pieces, and x be the number of pieces, then this power law is giving us the following equation:

y = Ax^{b},

for some constants A and b, with b between 0 and 1.  While y grows as x grows, it does not grow as quickly as x itself.

Taken in a broader context, though, this should not be surprising.  Examples of similar phenomena are prevalent throughout nature, as well as in made-made phenomena such as urban planning.  One example cited in the Wired article is Kleiber’s Law, which states that the ratio of an animal’s metabolic rate to its mass tends to decrease as mass increases (in other words, larger animals are capable of metabolizing more efficiently).  Here’s an article that discusses an analogue of this power law in the context of brain development, and relates this to the development of cities.

So the next time you give a Lego set to a child, feel free to explain this connection – I’m sure any child will welcome the math lesson (at least, any child worth giving a Lego set to in the first place).  It’s also worth noting that this phenomenon is most likely not unique to Lego sets – I am eagerly awaiting a similar report on the mathematics of Tinkertoys – though unfortunately, in this case the number of piece types seems not to have increased in nearly a century.

Pin It

5 comments to Lego Math Maniac

  • Matt Foulger

    Nice post Matt. Nice shout out to Kleiber’s law. I’ve watched a presentation on the metabolism of cities before and as an urban planning dilettante I found it quite interesting. As for Lego, I definitely thought about the complexity and size of Lego sets as a kid but I couldn’t figure out the relationship, being 11. It seemed like you had to get the bigger sets in order to score the cool new pieces, but there never seemed to be enough of them in the set. Actually, when it came to free form creative rebuilding, the true magic of Lego, I found the funky pieces to be less useful because there wasn’t a critical mass of pieces in their style to be of much use. I usually found myself wanting more of the ‘core’ style pieces so I could build bigger castle walls, for example. By the way, I’m sure someone could get some pretty interesting results from analyzing the aggregate inventory of the big Lego piece resellers online. Every piece has a standard code and they are categorized by color, size, etc. Cheers dude.

  • I totally agree with regards to creative rebuilding. My own personal preference was to take the heads of all of my lego men and form a giant lego head totem pole, but perhaps this is not something I should so freely admit. Nice idea regarding Lego inventory as well. I wonder which colors are the most popular!

  • Smith

    1993… I was a completely inspired lego maniac. I had two “giant” card tables in the basement completely devoted to Lego worlds I was building. One was of the “Town” variety, while the other was of the “Pirate” scene. For a time, my mother would always gift me with same small lego pack (car with a motorcycle and a little trailer) whenever I was sick. After receiving it three times, I debated saying something to her. Though I realized that while I never really cared to build the intended sets, I did now have a small stock pile of the “unique” parts that allowed me to really start doing some fun stuff with those parts. There is something to be said for the smaller cheaper packs, but you have to get a lot of them to build up the value of those random parts.

  • Patrick

    Holy smokes, that Banana Club Museum is a little frightening.

  • @Smith we should organize a lego playdate asap.
    @Patrick, if by frightening you mean fantastic, then yes, I agree.

    To everyone else, a reader sent a great little Lego infographic my way. Did you know that Lego designs sets for university aged students? If only I had known! Here’s the link: (thanks Muhammad!)

Leave a Reply




You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>