My question is related, but much simpler: we know "dark matter" exists because the mass of the "visible" universe is much lower than you'd expect it to be from gravity observations. Ergo, there must be more matter out there than we can directly detect (secret science hint: aforementioned astronomer friend says it's probably just lots of neutrinos, and not "invisible space monsters" as I'd originally guessed). Implicit in that explanation is something pretty staggering: astronomers have apparently figured out how to estimate the mass of the entire goddamn observable universe to a reasonable level of precision (at least a couple of orders of magnitude). How the hell did they manage that?
|This seemed kind of impractical (image of universe from Wikipedia, image of scale from random google image search)|
The answer is kind of an anticlimax, unfortunately; there were no ridiculous calculations or impossibly precise measurements of gravity involved, just some basic observations and lots of extrapolation.
The key is that space, as far as we can tell, is pretty much the same all across the universe: stars of the same type have roughly the same densities, galaxies have roughly the same stellar densities, chunks of space have roughly the same galactic densities, etc etc etc. There are centuries of astronomical data to back this one up, and the fact that even I know it should say something about its complete lack of controversy.
So armed with that convenient fact, you can vastly simplify the question: if you can calculate the area of one more or less representative chunk of space, you should be able to extrapolate that number out ad infinitum. That's still a lot of universe to deal with, but you can keep drilling down until you hit numbers that can actually be measured.
One of the most current (according to Wikipedia, which may not be the leading authority on this matter) estimates of the mass of the universe uses the Hubble volume (a sphere as big as the whole observable universe; what's important here is that it has a volume of about 4 x 10^30 cubic light years) as its representative chunk of space. It combines this with observations (by the Hubble telescope, natch) of stellar and galactic volume and density to estimate the number of galaxies, and by extension the number of stars, in the gigantic bubble, mostly by assuming that the parts we've been able to observe are the same as all the other parts density-wise. For what it's worth, there are about 5 x 10^21 stars in there.
So we're almost there, we just need to decide what to use as the mass of a star. This is where it gets a little heliocentric and sketchy; the mass of the sun (2 x 10^30 kg) gets used as the mean stellar mass, ostensibly because it's about average-sized (there are lots of bigger stars, but also lots of much smaller ones) but also because we know its mass to a conveniently high degree of precision, what with it being right next door and all. Still, people who know a lot more than me about this stuff seem to think it's a reasonable assumption.
So the mass calculation becomes a simple equation: mass = number of stars * mean stellar mass. Even I can do that one. Apparently the mass of the observable universe is approximately 3 x 10^52 kg, which is a lot of kg. There's another estimation that's even simpler, based on the fact that the universe appears to be at near-critical density, but it gives you essentially the same number.
Interestingly, if you go back and use that number to calculate the density of observable space, you get 1.766 x 10^-26 kg/m^3 as the mean density of the universe. To put that in nano-perspective, that's slightly under one atom per cubic meter. The universe is pretty empty when you think about it.