My 9 year old asked this question and we created this notebook as part of our fun exploration. The Pluto notebooks along with PlutoUI are really well suited for this kind of exploration. One could use Jupyter notebooks and ipywidgets to do the same.
Note: This is the HTML rendered output of the notebook so it looses all the interactivity. You may want to directly load the pluto notebook in Julia.GitHub Repository
🧬 Length of the Unrolled Human DNA
There are approx. 30 trillion cells in the human body. Every cell contains the DNA in its nucleus (except some). The unrolled DNA is around 2 meters long 🤯. Now, that is one hell of compaction.
Nature is the ultimate computer scientist.
The average number of cells in the human body is 70,000,000,000,000
md"The average number of cells in the human body is $(format(num_cells, commas=true))"
Total Human DNA ~ DNA Length x Cells in human body: 140,000,000,000 KM
"Amazing isn't it", I said and expected it to end.
But, share this fact with the kids and see if it ends there.
Almost immediately, the questions will start to roll in....
Q: If we unrolled the DNA from every cell of the living human and joined together, would it reach the Andromeda galaxy?
md"#### Q: If we unrolled the DNA from every cell of the living human and joined together, would it reach the Andromeda galaxy?
md"[Andromeda](https://en.wikipedia.org/wiki/Andromeda_Galaxy) is about 2.537 million light years from our home planet (and is on the [collision path](https://en.wikipedia.org/wiki/Andromeda%E2%80%93Milky_Way_collision) with our galaxy, in some 4.5 billion years)."
Let's find out.
md"Let's find out."
Is the distance between Earth and Andromeda greater than the length of DNA from a single human?
md"Is the distance between Earth and Andromeda greater than the length of DNA from a single human?"
mankind_dna_km = world_population * human_total_dna_km;
Is the total Human DNA from all living Humans long enough to reach the Andromeda galaxy ?
In fact, it is 45,495 times the distance of Andromeda.
Alright, so we know that the sum total length of every living human DNA is quite large. Some might say its Bigly.
md"Alright, so we know that the sum total length of every living human DNA is quite large. Some might say its Bigly."
Q: Is it longer than the length of our Galaxy?
md"## Milky Way
The width of Milky Way is 1,000,027,700,000,000,000 KM.
We could go from one end of the Milky way to another 1,091,969.752438 times, for that amount of DNA.
Q: It surely is going to be a lot less than the Universe?
md"## Observable Universe
The observable Universe is 8.79873e23 KM. And it is approximately the same length as the total length of entire world population DNA.
md"The observable Universe is $(observable_universe_km) KM. And it is approximately the same length as the total length of entire world population DNA."
Approximately ~ 1.241088 times
md"Approximately ~ $(format( mankind_dna_km/observable_universe_km, commas=true )) times"
At this point, the tiny inbestigators started asking all sorts of question such as what if you only take the population of Maldives or India. How far will it take us?
So, I gave them this. Go Play.
md"So, I gave them this. Go Play."
Total length of DNA from the population of
is 99,438,535.542491 times the distance from Earth to
md" is $(format(distance_times, commas=true)) times the distance from Earth to "
Population of ARUBA is 106314
md"Population of $(uppercase(country)) is $(current_pop)"
Note: The interactive version will only work in the Pluto notebook
pop_to_dna (generic function with 1 method)