Profile

Cover photo
Emil Sit
Works at Hadapt
Lives in Cambridge, MA, USA
10,834 views
AboutPosts

Stream

Emil Sit

Shared publicly  - 
 
What are the must read systems research papers of the past few years?
1
Add a comment...

Emil Sit

Shared publicly  - 
 
Anyone played with LaTeX editors for iOS? They seem decently advanced feature wise but curious for any first hand reports. See https://itunes.apple.com/us/app/texpad-latex-editor/id550419159?mt=8 or https://itunes.apple.com/us/app/tex-writer-latex-editor-compiler/id552717222?mt=8 for example.
1
Add a comment...

Emil Sit

Shared publicly  - 
 
 
How the price of paint is set in the hearts of dying stars

Today I’m going to try to explain the real reason that barns are painted red: nuclear fusion. And yes, this is an excuse to take a mad ride around some of the stranger corners of physics and chemistry in order to give you the real, this-is-not-BS, answer to a simple question.

This question got stuck in my head as a result of an episode of a long-forgotten sitcom called Head of the Class, about a high school class full of smart kids. (Sort of like Welcome Back, Kotter in reverse) This being an American show, it’s obligatory to occasionally emphasize the superiority of the ordinary virtue of “plain folk,” so in one episode the protagonists face off in some kind of academic contest with kids from a rural school, and end up losing because their city-slicker knowledge can’t answer the question “why are barns red?” (And this episode appears to have annoyed me enough that, several decades later when I have only the haziest memory of the show’s existence, I still remember it) The answer the show gives is “because red paint is cheaper,” which is absolutely true, but it doesn’t really tell you why red paint is cheaper. It clearly isn’t because the Central Committee for the Pricing of Paints has decreed that red shall be in vogue this century, or because of the secret Communist sympathies of early American farmers. In fact, to answer this we have to go all the way to the formation of matter itself.

Paints & Pigments & The Sun

First of all, let’s think about what paint is. At a minimum, paint is a combination of a binder (some material that dries to form a film, like acrylic or oil) and a pigment, some material which gives it a color. A pigment is a material which absorbs some colors of light and reflects others; most pigments are minerals. (There are also organic pigments, such as the Imperial Tyrian purple made from the snot of the Murex snail, but not as many, and they tend to be much more expensive for the simple reason that there are a lot more rocks than there are animals and plants.) So for something to be a cheap pigment, it has to be a good pigment, and it has to be cheap. So let’s figure out what makes each of these happen.

To be a good pigment, first and foremost, something has to have a nice, bright color. The way pigments produce color is that light shines on them, and they absorb some, but not all, of the colors of light. (Remember that white light is a mixture of many colors of light) For example, red ochre, a.k.a. hematite, a.k.a. anhydrous iron oxide (Fe2O3), absorbs yellow, green and blue light, so the light that reflects off of it is reddish-orange. (This happens to be the pigment that’s used in barn paint, so we’re going to come back to it.) Light is absorbed when a photon (a particle of light) strikes an electron in the pigment and is absorbed, transferring its energy to the electron. But quantum mechanics tells us that an electron can’t absorb just any amount of energy: the particular energies (and therefore colors) that it can absorb depend on the layout of the electrons in the material, which in turn depends on its chemistry.

The detailed calculations, or even the not-so-detailed calculations, are way beyond the scope of this post. (There are even whole books about it, like Nassau’s The Physics and Chemistry of Color) But there’s one important pattern which I can at least tell you about, which is that if you look at the various atoms which form a pigment, and you look at their outermost electrons (not the inner electrons, which are so tightly bound to their atom that they don’t participate in chemistry; all of chemistry is determined by the behavior of the outermost electrons around an atom) then it turns out that certain kinds of outermost electrons form pigments, and certain ones don’t.

The magic property is what’s called “angular momentum,” which basically measures how fast these outermost electrons are rotating around the nucleus. Electrons in atoms get angular momentum only in fixed increments (there’s that quantum mechanics again, only fixed increments allowed) and for historical reasons, the first few increments are named “s,” “p,” “d,” and “f.” On the periodic table, (http://www.webelements.com/) the elements whose outer electrons are “s” form the two tall leftmost columns; the “p” elements are the big square on the right; the “d” elements are the big block in the middle; and the “f” elements are the two rows off at the bottom. (If we ever make element 121, it would be the first “g” element) 

Electrons with less angular momentum spin in more spherical (rather than deformed) orbits, and when multiple electrons are trying to fly in the same spherical orbit, they repel each other pretty strongly. The result of this is that two “s” electrons meeting will have very different energies -- and it turns out that, in quantum mechanics, the amount of energy an electron can absorb is exactly the difference between these energy levels. So “s” means a big gap, “p” a slightly smaller one, and so on. And it turns out that “d” electrons are right at the sweet spot where that gap corresponds to visible light. 

Well, why are those particular colors of light visible? It’s because of the temperature of the Sun: our eyes didn’t evolve to see X-rays because there aren’t many X-rays to see around here. Instead, they’re very sensitive in the range of colors that the Sun produces, from red (around 780nm wavelength) to a peak brightness of yellow (around 600nm) all the way up to violet (around 400nm). Those colors correspond to energy gaps of about 0.3 electron volts (eV, a good unit of energy for studying atoms) which are right around the energies of chemical bonds involving d electrons. S- and p- bonds involve energies of 1-3 eV, corresponding to wavelengths around 100nm, in the far ultraviolet range.

Did we just get lucky that the Sun is yellow, and if we lived orbiting another star might the useful pigments come from p bonds? Surprisingly, the answer is no. The Sun’s color comes pretty directly from its temperature: it’s literally glowing yellow-hot, with a surface temperature of about 5,800K. The coolest stars, red dwarfs, are about 2,800K and glow red. The hottest stars, the type O stars, go up to about 40,000K, only 72nm; but it turns out that when a star gets any hotter than class F (about 7,000K, about 400nm -- blue) its lifespan starts to decrease precipitously. This is because the temperature of stars is actually fixed by the kinds of fusion reaction going on in their core, which I’ll get back to in a moment, and those hotter reactions burn through their fuel a lot faster. The net result is that any star that’s going to last long enough to have planets with life on them might be a bit redder or a bit bluer than our sun, but not radically so: and it’s those d-orbitals that are going to make the best pigments for anyone whose eyeballs evolved there.

How the price of iron is determined in the centers of stars

So now we know what makes a good pigment. What makes a cheap pigment? Obviously, that it’s plentiful. The red pigment that makes cheap paint is red ochre, which is just iron and oxygen. These are incredibly plentiful: the Earth’s crust is 6% iron and 30% oxygen. Oxygen is plentiful and affects the color of compounds it’s in by shaping them, but the real color is determined by the d-electrons of whatever attaches to it: red from iron, blues and greens from copper, a beautiful deep blue from cobalt, and so on.

So if we know that good pigments will all come from elements in that big d-block in the middle, the real question is, why is one of these elements, iron, so much more common than all of the others? Why isn’t our world made mostly of, say, copper, or vanadium?

The answer, again, is nuclear fusion. 

To explain this, we need to think about how fusion actually works. The basic principle is that two small atomic nuclei combine to form a bigger nucleus. Now, there are two forces at work here: there’s an electromagnetic force, which makes the positively-charged nuclei repel each other, and repel each other more and more as they get closer. And there’s the strong nuclear force, which is what holds nuclei together: it’s powerfully attractive, much stronger than the electromagnetic force, but it has the interesting property that it simply shuts off at distances of much more than about 1fm. (10^-15m, the size of a medium nucleus) So to make fusion happen, you need to somehow push two nuclei together with enough force (generally in the form of heat and pressure) to overcome their repulsion until they get within range of the strong force, at which point it will yoink them together with spectacular force and release a good deal of energy in the process.

This gives us two rules of thumb. As the nuclei involved get bigger, the amount of energy (heat and pressure, in particular) required to set fusion off gets higher, because you have more repulsion that you have to overcome before fusion can start. And second, as the nuclei get bigger, the amount of energy you get back from the fusion gets smaller: in the bigger nucleus that you would form, you still have all of this repulsion, but the strong force can only bind together the nucleons that are close to each other, so as the nucleus gets bigger you keep adding repulsion but you don’t keep adding attraction. 

This means that fusion of really small elements is very efficient; combining two hydrogen atoms is just great. (For various technical reasons, the slightly heavier isotopes of Hydrogen -- deuterium (a proton with a neutron) and tritium (a proton with two neutrons) do better than bare protons. That’s where the “D-T” of D-T fusion comes from, and it’s the kind that powers both the Sun and H-bombs.)

In fact, once the atoms get too big, you no longer get back any net energy from fusion: the last reactions which turn out to be net-positive are the ones that form atoms with 56 total neutrons and protons in them. Beyond that, fusion starts consuming more energy than it produces, and won’t light up anything. (If you go far enough beyond that, to 232 nucleons or more, you start to see nuclei that are so unstable that a swift kick will make them separate enough that repulsion takes over, and they explode with a bang: that’s nuclear fission, a subject for another time)

Now imagine a star. It starts out its life as a giant ball of primordial hydrogen from the formation of the universe, and under the tremendous pressure of gravity, it starts to fuse. As it fuses, it starts to form heavier elements like helium: but (rule 1) it takes higher temperatures than these mere hydrogen fusion temperatures to make helium do any fusing, so the Helium basically acts as a pollutant and just gums up the works. Ultimately, it reduces the efficiency of fusion so much that power levels start to go down.

But the only thing holding the star up was the energy of the fusion reactions, so as power levels go down, the star starts to shrink. And as it shrinks, the pressure goes up, and the temperature goes up, until suddenly it hits a temperature where a new reaction can get started. These new reactions give it a big burst of energy, but start to form heavier elements still, and so the cycle gradually repeats, with the star reacting further and further up the periodic table, producing more and more heavy elements as it goes.

Until it hits 56. At that point, the reactions simply stop producing energy at all; the star shuts down and collapses without stopping. This collapse raises the pressure even more, and sets off various nuclear reactions which will produce even heavier elements, but they don’t produce any energy: just stuff. These reactions only happen briefly, for a few centuries (or for some reactions, just a few hours!) while the star is collapsing, so they don’t produce very much stuff that’s heavier than 56. 

If the star is small, it will end up as a slowly-cooling cinder, or as a white dwarf. But if it’s big enough, then this collapse will send shock waves through the body of the star which bounce off the star’s core, pushing the collapsing wall of matter outward with more than enough energy to escape its gravity: the star explodes in a supernova, carrying off a good ⅓ of its total mass, and seeding the rest of the universe with elements heavier than the simple hydrogen we started with. Those elements, in turn, will join the mix for the next generation of stars, as well as the accretion clouds of stuff around them which turns into clumps rather than falling into those stars: that is, the planets. And this is how all of the chemical elements in the universe were formed.

How do we know that this is really where the elements came from? There’s a whole field of science around this, but the classic paper is commonly known as “B2FH” for its authors -- Burbidge, Burbidge, Fowler, and Hoyle. Using only the physics and the computational resources available to them in 1957, they calculated all of the various processes by which elements would be formed in stars, in enough detail to predict the ratios of elements which would be formed, and to predict the abundance ratios of chemical elements in our solar system. Amazingly enough, they made a pretty damned good and thorough prediction, enough that even then it was clear that this was a smoking gun -- and it’s been refined considerably since. 

So how does this tie in to red paint? Well, I told you before that the magic cutoff for ordinary fusion is at 56 nucleons. Because it’s the last point in the normal reaction chain, a lot of the fusion products tend to “build up” there before the star explodes, and so you get a lot more of isotope 56 than you do of anything except for the really light elements that didn’t fuse at all, or didn’t fuse much. (Check out the first figure in the B2FH paper, linked below) And what has 56 nucleons in it and is stable? A mixture of 26 protons and 30 neutrons -- that is, iron.

So it’s because of the details of nuclear fusion -- the particular size at which nuclei stop producing energy -- that iron is the most common element heavier than neon. And as we saw before, you have to be a d-block element to make a decent pigment, which means that iron is going to be, by far, the most plentiful pigment for any species which lives on a star that isn’t about to blow up. And it’s going to bond to oxygen, the most plentiful thing around in planetary crusts for it to bond to (only hydrogen and helium are more common, and they tend to evaporate), to form iron oxides: those rich, red ochres that we mix with oils to form a cheap, stable, red paint.

And that’s why barns are painted red.


To learn more:
Something a lot more interesting than you would guess: http://en.wikipedia.org/wiki/Paint
http://en.wikipedia.org/wiki/Pigment
The color of the Sun: http://en.wikipedia.org/wiki/Sunlight
Colors of stars, and a place to start about how they get them: http://en.wikipedia.org/wiki/Main_sequence
The abundance of elements in the universe, the Earth, the human body, and other places:
http://en.wikipedia.org/wiki/Abundance_of_the_chemical_elements
A nice diagram of how much energy you get from fusion and fission for various elements, thanks to +Jas Stronghttp://hyperphysics.phy-astr.gsu.edu/hbase/nucene/imgnuk/bcurv.gif
The 1980’s sitcom that inspired this: http://www.imdb.com/title/tt0090444/

To learn a lot more about color:
http://www.amazon.com/Physics-Chemistry-Color-2nd/dp/0471391069
To learn a lot more about how the elements are formed, the original B2FH paper: http://rmp.aps.org/pdf/RMP/v29/i4/p547_1

Photo by John Christopher: http://www.flickr.com/photos/67382043@N06/6153955066/
326 comments on original post
1
Add a comment...

Emil Sit

Shared publicly  - 
 
Is there some way on a Google Nexus (not the Nexus 4, if it matters) to wake the screen during a long call, where the screen is likely to blank, without hanging up? If I tap the power button, which is how I normally do it, the call disconnects.
1
Add a comment...

Emil Sit

Shared publicly  - 
 
A few months ago, dropped my Galaxy Nexus (it's a little big in the hand) and cracked the screen. It's starting to crack more. A replacement screen, naturally, costs nearly as much as the Nexus 4. So, thinking to buy some sort of screen cover thing-y to hold it together. Any recommendations?
1
Dan Sandler's profile photo
 
My vote would be for a good adhesive screen protector, or even a piece of clear plastic tape…
Add a comment...

Emil Sit

Shared publicly  - 
 
We've been using Gradle to manage our Java build at Hadapt. Here's a quick intro to using Gradle to build an application on top of (Cloudera) Hadoop.
This post is a translation/knock-off of Cloudera’s post on developing CDH applications with Maven and Eclipse for Gradle. It should help you …
1
Add a comment...

Emil Sit

Shared publicly  - 
 
Do I know anyone who works on Google's Chromium team or on the Chrome Extension webstore?
1
Add a comment...

Emil Sit

Shared publicly  - 
 
I'm imagining a tool that intercepts a processes system calls and provides some sort of DSL for specifying "interesting" call sequences upon which the tool would allow doing things like: changing the return value, spawning some external action, etc. I'd like to use it for testing things.

It'd sort of be the opposite of a system call fuzz tester like Trinity.

Does anyone know of such a tool?

Some things I can think of:
* Write it from scratch on top of ptrace. (+Harvey Tuch didn't you do something like this at some point?)
* Scripting on top of dtrace or systemtap.
* Use some sort of LD_PRELOAD hackery. I vaguely recall reading a paper, maybe a Usenix ATC submission that did this to test for programs responding poorly to "unusual" system call returns (e.g., short reads). +Frank Dabek do you remember?
1
Frank Dabek's profile photoChris Frost's profile photoEmil Sit's profile photoHarvey Tuch's profile photo
4 comments
 
We were using ptrace for trap-and-emulate style virtualization at user-level, so not quite what you are after. Of course, you could roll your own with ptrace, the real limitation is going to be performance, depending on the architecture you're looking at 3x the number of system calls...
Add a comment...

Emil Sit

Shared publicly  - 
 
I know my Galaxy Nexus with latest official Android is supposed to be buttery fast. But, it's not. Why?
1
David Andersen's profile photoFrank Dabek's profile photoEmil Sit's profile photoBen Chambers's profile photo
12 comments
 
+Emil Sit Thanks for the update. Mine seems to have stopped the worst of the slowdowns (and/or maybe I've already gotten used to the slower speed). I think I'll hold off on a reset until it's annoying me more.

Defragging does have a certain appeal though. Maybe I can get a copy of RAM Doubler running on there too... :)
Add a comment...

Emil Sit

Shared publicly  - 
 
Really? Thrift RPC doesn't support multiple outstanding calls to the same remote procedure over a single connection?
1
David Andersen's profile photoMaxwell Krohn's profile photoEmil Sit's profile photoChris Lesniewski's profile photo
10 comments
 
+Marc Horowitz does.
Add a comment...

Emil Sit

Shared publicly  - 
 
Spent a weekend using my Nexus One.

The keyboard feels so small in comparison to the giant Galaxy Nexus one. Also, it is constantly running low on space with apps like Google Maps or Facebook taking up 10% of system storage.

I missed the updated multi account gtalk app the most. And it really makes clear the usability refinements (notably, cut and paste) that have made their way into 4.x.

Still, like the form factor a lot. There ought to be a Nexus 3.
3
Emil Sit's profile photoFrank Dabek's profile photo
3 comments
 
Yeah... though I hear the motoblur is getting lighter and lighter these days.
Add a comment...

Emil Sit

Shared publicly  - 
 
For all you Malcolm Gladwell fans out there.
The “neuroscience” shelves in bookshops are groaning. But are the works of authors such as Malcolm Gladwell and Jonah Lehrer just self-help books dressed up in a lab coat?
2
1
David Andersen's profile photoChris Lesniewski's profile photo
 
I'll recommend exactly one book along these lines:  Stumbling Upon Happiness ( http://goo.gl/6GVuZ ) by Daniel Gilbert.  tl;dr:  Humans are pretty bad about predicting what will make us happy;  our brains are pretty resilient to big shocks.
Add a comment...
Story
Tagline
Do it right.
Places
Map of the places this user has livedMap of the places this user has livedMap of the places this user has lived
Currently
Cambridge, MA, USA
Work
Employment
  • Hadapt
    2011 - present
  • VMware
    2008 - 2011