Posts filed under Just For Fun

There are more recipes than atoms in the universe. What does this mean for your life, career and dinner?

Fresh ramen noodles, pork belly marinated in sake, mirin and soy, sous-vided and then deep-fried, chives, extra-spicy Szechuan sauce (itself consisting of: fermented salted soybean, water, salt, wheat flour, chili, sugar, pickled vegetables, soy bea…

Fresh ramen noodles, pork belly marinated in sake, mirin and soy, sous-vided and then deep-fried, chives, extra-spicy Szechuan sauce (itself consisting of: fermented salted soybean, water, salt, wheat flour, chili, sugar, pickled vegetables, soy bean oil, garlic, salt, peanut, onion, sesame oil, yeast extract, maize starch), sous-vided egg marinated in juices from the pork belly, jalapenos, mayu (blackened garlic in sesame oil), bean sprouts, blanched bok choy and blanched Shanghai choy.

All of above, now with 12 hour Tonkotsu broth made from pig bones, pigs feet, a whole chicken, garlic, charred garlic, ginger, charred ginger, onions and chives poured on top of it.

All of above, now with 12 hour Tonkotsu broth made from pig bones, pigs feet, a whole chicken, garlic, charred garlic, ginger, charred ginger, onions and chives poured on top of it.

The Joy of Cooking

I enjoy cooking.  Part of it is because it allows you to eat tasty things at home, but part of it is because it is a puzzle of sorts.   What ingredients, in what order, in what relative quantity, with what pre-treatment, with what cooking technique are likely to produce something that is tasty, nutritious, both or neither, is a non-trivial problem.

The other day I was thinking about exactly how non-trivial the problem, in particular "how many recipes theoretically exist?" and came to the astonishing conclusion that there are far more potential recipes to try than there are atoms in the universe and that, short of some post-Singularity food modeling, we humans, in aggregate, will never cook more than an infinitesimally small fraction of all recipes that can be cooked.

I will run through some quick math of how to calculate the Total Recipe Space, noting that I believe every number here is wildly underestimated.

How many potential ingredients are there?  

I am assuming for my calculation that there are 200,000 ingredients in the world.   This is a huge understatement.

The average suburban supermarket sells ~40,000 items and anyone who has traveled abroad knows that there are still very large distinctions in what type of food is carried in supermarkets in Nashville, Nice, Nicosia, Nagpur or Nanjing.

Beyond that, what you realize is if you start digging deep into any specific food area, is that there are variations upon variations upon variations.  An elite sushi chef will differentiate between many different parts of a tuna, differentiate between warm-water and cold-water tuna, between younger and older tuna and so on, at which point one comes to the conclusion that there are probably 50,000 different cuts of fish, each with different tastes, consistencies, textures and cooking properties.  The same thing holds for any other food group once you start studying intently.  I have read, for example, that there are 75,000 wines in production in the world right now.  

But for the purposes of this exercise, we will stay with 200,000 potential ingredients, even though I suspect that the total number of unique ingredients is well into the millions.

How many ingredients go in a recipe?  

I am going to base my estimates on assuming 10-ingredient recipes.   I have read that 8 ingredients is average in a recipe, but it is trivial to go above 8.  Fajitas with salsa and guacamole, a generic Tex-Mex dish easily surpasses that, to say nothing of complex or engineered foods.   The ramen above had nearly 40 ingredients in it.   

Each additional ingredient assumed above 10, adds about 7 orders of magnitude to the final number as you will see below so these figures are also an underestimate because we know that there are recipes with more than 10 ingredients.

What are the relative quantities of ingredients used?

A recipe with 1lb of pasta and 1lb of garlic is different than one with 1lb of pasta and 1oz of garlic.

For the purposes of this exercise, let's assume that there are 10 possible quantities of each ingredient so our 200,000 ingredients become 2,000,000 ingredients.  Again, this is also a simplification.

What are the preparing, cutting and cooking treatments of each ingredient?

Recipes are more than simply put each of the ingredients in a bowl and serving them.

They might be chopped into different sizes (Chinese cuisine has dozens of variations of chopping size alone), they might be grilled, sauteed, boiled, blended, mashed, mashed+grilled, grilled rare, medium rare or very well done, glazed, sous-vided, broiled, steamed, cooked in the wok (itself many different variations), put in a clay oven and so on.

And again the results differ:  raw garlic is different than sauteed garlic which is different than minced garlic which is different than grilled garlic which is different than blackened garlic which is different than ground garlic which is different than oven-roasted garlic and so on.

Let's assume that there are 10 methods of preparation for each ingredient which is definitely a dramatic understatement (the real number is probably closer to 100-200, if not 1,000).

In any case, with 200,000 ingredients in 10 different portion sizes and 10 methods of preparations, we have 20,000,000 building blocks to work with.   If we wanted to be more aggressive, we could imagine 2,000,000 ingredients with 10 portion sizes and 100 methods of preparation and start with 2 billion building blocks.   In any case, we will start with the 'conservative' case.

Factorials!

Using the factorials we learned in high school math, it means that the possible number of 10-ingredient recipes is:

20,000,000 x 19,999,999 x 19,999,998 x 19,999,997 x 19,999,996 x 19,999,995 x 19,999,994 x 19,999,993 x 19,999,992 x 19,999,991 = 

10,239,976,960,022,300,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000 

potential 10-ingredient recipes.

Or, 1.02 x 10^73 if I counted my zeros correctly

And if I took less conservative estimates above, we might be multiplying 2,000,000,000 x 1,999,999,999 and so on in which case we are talking about about 1.02 x 10^93 or this for those who are counting at home:

1,023,997,696,002,230,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000 

Note 1: Since the order of ingredients matters in recipes, we do not need to divide by 2

Note 2: Some might argue that there are logical parts of the Total Recipe Space that are unpalatable and should be excluded: e.g raw beef tartare + onions + strawberries + tuna + cheetos + doritos + bacon + kale + yogurt + oatmeal is probably not tasty.

I will note that:

(a) that is true but this is a calculation of all possible recipes (not necessarily recipes that you would like)

(b) Fusion chefs have created some very tasty food out of very unlikely combinations and there are certainly many unexplored delicious flavor combinations that we do not know about yet.

(c) Even if that is the case, the more aggressive estimates that add 20 or more orders of magnitude would more than account for this problem.

How big is 10^73?

So, let's put that 1.02 x 10^73 figure in context.   

(a) I have seem estimates that the total number of people who have ever lived is 100 billion.

Let's be super generous and imagine that every man, woman and child who ever lived knew 50 unique recipes and that each of those recipes were unique to that person - aka no two people ever cooked the same dish.

That places the total number of world recipes ever cooked at 5 trillion or 61 orders of magnitude (61 zeros) less than the  Total Recipe Space.

(b) There are supposedly 9.48x 10^61 atoms in the known universe or 12 orders of magnitude fewer than the Total Recipe Space (conservative estimate).

So that means, even with lots of 'fusion' restaurants, humanity will never explore even a small fraction of the Total Recipe Space (unless we get to post-Singularity intelligences that model food tastes and cook recipes 'virtually').   If every man, woman and child alive today made a new recipe for breakfast, lunch and dinner for each day of his/her 80 year life, we only get to 6.13 x 10^14 number of recipes.

What this means for life, liberty and the pursuit of happiness?

(1) If you are fusion chef, keep experimenting!  Please.  For the good of humanity itself - you might discover the next tuna tartare-avocado combination that will spread around the world

If you are a restaurant-goer, be kind to those chefs who try new things.   They are the startups of the food world and they are doing us all a service by expanding into new parts of the Total Recipe Space.

(2) I have read statistics that claim that the average family repeats the same 6 to 12 recipes.  

If you cook at home,. you might consider, in this context, there there might be room to expand your mix of recipes!

(2) If there are 1 x 10^73 choices for dinner, imagine how many choices you have about how to live your life in which every moment you are deciding what to think, what to say, what to do and where to go?  

Be bold.  Don't just do what you think you 'ought to'.   All of the humans who have ever lived have barely scratched the surface of "what's for lunch?" let alone how you should live your life and what you should do for your career, for your personal life, for your family and for love.

So step out into that broader world and help us all expand the scope of human knowledge and experience, one step, one idea and one recipe at a time!

Posted on March 18, 2014 and filed under Just For Fun.