According to Wolfram Alpha, there are 2.9 x 10^6 dietary calories in a cubic meter of cheese, 142829% of your recommended daily caloric intake.

Furthermore, there are 8.468×10^47 cubic meters in a cubic light year. From this, we can conclude that there are 2.455 x 10^54 dietary calories in a cubic light year of cheese.

According to NASA the sun produces 3.8 x 10^33 ergs/sec or roughly 3.8 x 10^26 joules/sec. Over the course of a year that adds up to approximately 6.065 x 10^37 joules of energy.

One dietary calorie or “kilocalorie” equals about 4180 joules. Doing the math we conclude it will take 1.7 x 10^20 years for our sun to generate the same amount of energy as a cubic light year of cheese.

Be warned, however, that at 977 kilograms per cubic meter, or 8.27 × 10^50 kilograms per cubic light year, the Schwarzchild Radius of a cubic light year of cheese would be 1.23 × 10^24 meters, significantly greater than the 9.46 x 10^15 meters in a light year. From this we can conclude that a cubic light year of cheese, should that somehow manifest itself, will immediately collapse into a black hole.

So while you would think a cubic light year of cheese would be the obvious choice over the sun, if you are presented with a choice between them, the numbers suggest you would be far better off choosing the sun.

These numbers assume cheese of approximately constant density. Swiss cheeses require much more sophisticated modelling.

*(This article has been updated to reflect a comment from Jin, seen below, who notes that Wolfram returns dietary calorie units, which is to say kilocalories, rather than simply calories. The original claim, that it would take the sun 1.7 x 10^17 years to generate the same amount of energy as is contained in a cubic light-year of cheese was inaccurate, and has been corrected above. The author sincerely regrets any inconvenience this may have caused.)*

When asked for calories in cheese, Wolfram Alpha returns the answer in dietary calorie units, or kilocalories. There are 4180 joules in a dietary calorie, so it will take 1.7*10^20 years.

Thanks, I’ve made the correction.

It would be gouda to know your thoughts on the string cheese theory of the universe…

So. Awesome.

This has occupied more of my evening than I probably ought to admit, and there has been some rather undignified giggling while my wife and I pondered what, exactly, could possibly cause the sudden manifestation of a cubic light-year of uniformly dense cheese.

Regardless, it certainly wouldn’t stay uniformly dense for long; that much is certainly clear from your calculations above!

I must comment, though — with as little pedantry as possible — that one simply does not swap spherical and cubic volumes. While a profound thought exercise, your cubic light-year of cheese would assume the form of a sphere without the outside influence of (we assume) the same divine power that curdled it into existence. The radius of this would be just over half a light-year, 5.869 x 10^15 meters.

This clearly does not affect the final outcome, as this glorious mass — though galacticly insignificant volume — of cheese would shortly collapse in upon itself, perhaps showering its nearby neighbors with a rain of fondue in the process.

…

Should it manifest as a Swiss cheese of the same mass, however, it should be noted that this Schwarzschild Radius is an astonishing 129,390,756 LIGHT YEARS, occupying a volume of 7.757 x 10^72 cubic meters — 9.16 x 10^24 cubic light-years.

Wow.

That’s a lot of cheese. (And here’s hoping XKCD notices this and runs with it.)

— Calculations performed with pencil, paper, Microsoft Mathematics & Wolfram Alpha; value of Pi used to 8 decimal places. Attention to detail courtesy Dad, Basic Training & my college physics professor.

I’d like to point out that food energy is based on combustion. So, natural next calculation is to find out how much oxygen would be needed to burn those calories.

As to the Black Hole postulate, estimating the likelihood of collapse, and rate thereof, would depend upon what we can provisionally identify as the mode of manifestation of the cubic lightyear of cheese.

(Note: As will become clear, I am not an astrophysicist and don’t even play one on the internet.)

For example: Has it been constructed? Have smaller chunks of stable cheese been somehow brought together? Has a stable configuration or assemblage of pre-existing matter been instantaneously transformed into cheese?

Perhaps we need to posulate the existence of an arrangement, perhaps a kind of surrounding latticework, of dense material, superhard candy, perhaps, sufficient in mass to generate counter-gravity? How large would it have to be to prevent the Black Hole collapse?

Alternatively, if we supposed a god-like entity capable of wishing the cheese supermass into existence, then why should we assume that it lacks the ability to sustain it, at will – or, if subject to other physical laws of this universe, capable of exerting the same force provided by the above-referenced superhard candy counter-gravity latticework.