Astronomy bottlenecks…

[tweetmeme only_single=false service=wp.me source=allinthegutter]

Guess what’s the largest hurdle impeding scientific progress in astronomy? Lack of money? Governmental disinterest? Nope, according to a paper published yesterday it’s our bad programming skills.

Modern astronomers are much more likely to be found in front of a computer these days than behind a telescope. We spend our time analysing our data and to do so we need to write computer programs. Some of these are pretty simple (`read table, make graph, join dots’), but often they’re much more sophisticated (`read table, decipher Universe’ etc). However, whilst we generally received some basic programming training during our degrees, we tend not to be proper software developers. As the authors of the paper point out this can mean that our programs:

…often contain the goto statement every 10–20 lines; names of variables do not
follow any conventions, i.e. a1, a2, aa1; the code is unreadable: no or bad indentations,
very long function bodies and/or source files. There is a lot of hard-coding of file and
device names, file system paths.

and

When the author is
returning to the same program after several months or years, he/she often finds that the
existing procedure/function calls do not satisfy his/her needs, however is not willing to
modify them to keep the backward compatibility. Then, a wrapper routine is created
which is calling some underlying procedures/functions in a slightly different way.

These aren’t the only flaws they highlight but they’re the ones, I’m embarrassed to admit, I might, perhaps, maybe inflict on my own code (though not the GOTO statement – I don’t do that)!


(GOTO as seen by Futurama from this page of programmer’s jokes)

So, is hiring software developers to code `properly’ for us the answer? Nope: our programs might be inefficient and unwieldy but

…at the end the program does what it is supposed to, because the author
knows exactly what it should do. Even though it may sometimes crash during run-time
or have very poor performance,

whereas a programming professional could write pretty code but might not spot an obvious flaw in the output. It’s not all bleak though, as they also give some examples of well-written pieces of astronomy software such as the excellent TOPCAT which Niall has guest-blogged about before over at AstroBetter.

The authors’ solution to the problem is to introduce mandatory undergraduate courses in these skills and to wean us all off the obsolete programming languages (in their opinion) that we insist on using. This sounds like a good idea, especially as this problem will only increase in future as the amount of data we have to handle rises. This only leaves the question of what to teach everyone which, as xkcd points out, is another kettle of fish entirely.

ResearchBlogging.orgIgor Chilingarian, & Ivan Zolotukhin (2010). The True Bottleneck of Modern Scientific Computing in Astronomy Astronomical Societ of the Pacific arXiv: 1012.4119v1

Advertisements

Discovering Cosmic Discoveries

I’m currently back in Europe for a few weeks over Christmas. Last week I travelled back from Hawai`i via New York and had a 10 hour stop-over in Newark. To pass the time I decided to pop into Manhattan and meet up with a few folk who work in my field at the American Museum of Natural History. There they have research astronomers who also spend part of their time doing outreach activities at the museum. One of them, Emily Rice has been involved in producing a nice little app for the iPhone called Cosmic Discoveries. I had a play about with it on my Dad’s iPod touch (I like my music players to have buttons).

Rose Center Planetarium

The Rose Center Planetarium at AMNH.

It’s main part is a big mosaic which shows Saturn with it’s aurorae (the Northern Lights are an example of this phenomenon on Earth). Zooming in you can see thousands of images of stars, planets, galaxies, fuzzy things, telescopes, famous astronomers and the planetarium at AMNH. Speaking of the planetarium (see right) it’s a huge sphere inside a glass cube. It reminded me of the Technodrome from Teenage Mutant Ninja Turtles. Inside it I took in a great planetarium show about stars and their evolution. Each photo also comes with a short bit of information and the ability to comment on it. Additionally there are also a series of more in-depth stories about topics in astronomy. This isn’t an app that will change your life, but if you want something to browse around occasionally (or if you want to distract astronomically curious relatives over Christmas) it’s very nice indeed. The app is available for free from the iTunes store.

If you have a favourite astronomy app (for iPhone, Android or another system) feel free to discuss it in the comments.

PS for people at AMNH, this is mince pie, they rock.


Strictly PhD dancing

[tweetmeme only_single=false service=wp.me source=allinthegutter]

It’s the grand final of Strictly Come Dancing in the UK tonight. If you’re not aware of this series it pairs professional dancers with celebrities and then they compete over many weeks to see who’s the best dancer (if you’re in the USA it’s the same as Dancing With the Stars). Since our travel plans were foiled by the snow this morning, my mum and I will be settling down (probably with a Christmas glass of sherry) to watch it at home instead (I think we’ll be voting for Matt if you care about that sort of thing).

It’s not just celebrities that get to take part in stuff like this though. Since 2008 scientists have had the chance to explain their research through the medium of dance in the annual `Dance your PhD’ contest. One of my fellow postdocs in Nottingham, Ruth, took part in the very first competition, presenting her thesis work on “The eventful life of galaxies in low-density environments”. Here she is as a small galaxy tangoing around, and eventually merging with, a much bigger companion:

I doubt any of the Strictly competitors tonight will be thinking much about expressing science in their routines (though if they did maybe they’d need a peer review panel of judges of as well) but it’s nice that someone out there is!


ALMA nearly ready

[tweetmeme only_single=false service=wp.me source=allinthegutter]

I’m in Manchester for a few days this week at a workshop preparing for `Early Science’ with the new Atacama Large Milimetre Array (ALMA for short) that’s been under construction for several years now. The final telescope will consist of 66 linked antennas, but the current plan is to have about 16 in place by next year, and to let astronomers have a go on them to see how everything works!

As you can tell from its full name, ALMA is in the Atacama desert – a very high, very dry site in Chile. Observers won’t get to go out and see it in person, but I was lucky enough to see some of the prototype 12 metre antennas for it when we were both at the Very Large Array in 2006:

ALMA is going to be a fantastic instrument. The wavelengths at which it operates are ideal for revealing previously hidden details about how stars and galaxies form. It will even be able to see this sort of thing happening in some of the earliest galaxies in the Universe. It operates in a similar wavelength range to the Herschel Space Telescope, and complements it nicely – it will be able to have a very detailed look at interesting things Herschel finds in its large surveys.

I’m sure that by this time next year ALMA will have produced some impressive first light pictures and hopefully will be living up to everyone’s expectations. I’m looking forward to it.


Mysterious web site

Hey all

Stuart here with my first post in an embarrassingly long time. Promise to get back to blogging more regularly but until then I just wanted to share this mysterious website:

http://www.milkywayproject.org/

its counting down to midday today … wonder what it could be ?


The astronomer prince of Samarkand

Sweeping conquests in the style of Genghis Khan, a shining city at the crossroads of east and west and amongst it all, one of the great astronomers of his age……

I should start by saying that I came across the subject for this post from listening to the BBC radio series A History of the World in 100 Objects as a podcast. The particular episode was on the jade cup of Ulugh Beg. The owner of the object in question was the descendant of one of the most successful military campaigners of the late middle ages and was himself one of the great Islamic astronomers.

In the late 14th century Central Asia was a patchwork of successor states to the great Mongol Empire. In this period the Turco-Mongol military leader Tamerlane waged campaigns of conquest from India to Mesopotamia. In doing so he founded the Timurid Empire which in stretched from Baghdad and the Black Sea in the west to Kashmir in the east and from the Indian Ocean to the Aral Sea.

After Tamerlane’s death, his son Shah Rukh took over most of empire covering Iran and Central Asia. Rather than rule his territories from Tamerlane’s capital of Samarkand in what is now Uzbekistan, he moved his capital to Herat in modern-day Afghanistan. He then sent his sixteen year old son Ulugh Beg to rule over Samarkand.

When I think of the great Islamic astronomers and centres of learning I automatically envisage Cairo, Baghdad and Damascus. Samarkand by contrast conjures up images of bussling commerce and great wealth due to its position on the Silk Road. But, like his father and grandfather before him, Ulugh Beg was a patron of the arts and sciences. He founded an Islamic school (madrasa) in Samarkand but was also interested in pursuing science himself.

An enthusiastic scholar of astronomy and mathematics Ulugh Beg’s madrasa was a place with a vibrant academic culture attracting great minds such as the Persian mathematician al-Kashi. To satisfy his growing interest is astronomy he build a magnificent observatory. Before telescopes astronomical measurements could be difficult. The positions of stars were measured by timing them crossing their highest point and using sextants to measure their height while they did this. Ulugh Beg’s observatory had a massive sextant over 35 metres in diameter. This was used to measure the length of the astronomical year and the tilt of the Earth’s axis more accurately than later, more famous astronomers such as Copernicus and ol’ Mr. Brassnose Tycho Brahe. Ulugh Beg also catalogued nearly a thousand stars and determined trigonometric relations to astonishing accuracy.

Ulugh Beg's Observatory in Samarkand

The observatory also produced great thinkers of its own. One such was Ali Qushji, the son of Ulugh Beg’s royal falcon trainer. He challenged the orthodox astronomical thinking of the time, trying to break astronomy free from the shackles of Aristotle’s model of the world and making it an independent science. He also postulated that the Earth was not stationary based on his observations of comets.

Ulugh Beg was one of the great scientists of the Middle Ages, however he was not a successful ruler. After his father’s death he lost several important battles and was eventually killed after his own son moved against him. The Timurid Dynasty would survive thanks to his great-nephew Babur, who founded the Mughal dynasty in India. This did not officially fall until the Sepoy Rebellion in 1857. Just to put that into context, Tamerlane and Ulugh Beg’s dynasty lasted from before the European Renaissance to the time of Queen Victoria.

If you want to read more on Ulugh Beg, I found this article from the University of St. Andrews very informative.


Supernovae – setting the standard, part II

[tweetmeme only_single=false service=wp.me source=allinthegutter]

In part I of this blog post I told you how supernovae type Ia have proven to be so important in defining today’s standard model of Cosmology. I did, however, leave out some important details so let’s get stuck right in.

Type Ias don’t always explode with the same brightness. There seems to be some intrinsic variation – some are a little dimmer, and some are a little brighter. It’s important to note that this variation is relatively small when it comes to astrophysical events, but it still gets in the way of precision cosmology. We’re trying to measure the acceleration of the Universe, and that’s not an easy task. Nature, however, can sometimes be kind to us and it turns out that type Ia supernovae provide themselves the means to compensate for this small variation.

The commonly used trick relies in measuring how the brightness of a given supernova changes with time. Right after the explosion, the brightness increases very rapidly until it peaks, and then it decays more slowly. The following animation shows a real example of a supernovae light curve. In the image on the left, you can see a bright spot getting brighter before it gets dimmer again – that’s the supernova. The curve on the top right shows how that brightness changes with time – we call this a light-curve – and the curve on the bottom right show the supernova spectrum. The timescale  is only of a few days, or perhaps a couple of weeks – but well within something what can be tracked with our current technology:

What is neat (and lucky!) about light-curves, is that they are systematically different for supernovae that are dimmer or brighter. Brighter supernovae have broader light curves, and fainter ones have narrower, or shorter light-curves. In practice, what this means is that if we can measure the light curve of a supernova and how broad, or stretched it is, then we can correct for the small variations I mentioned at the start of this post and infer its real brightness – handy! It works pretty well, as you can see in these two images: the first one shows the light-curves for a bunch of supernovae and you can clearly see how some and brighter and some are dimmer. The second image shows how you can use the width of the light-curves alone to calibrate all supernovae to a single, intrinsic brightness.

Supernova light curves before correction.

Supernova light curves after correction.

We now have the so called standard candles, although many Astronomers would rightly point out that supernovae should rather be called standardisable candles.

So is the problem solved? Once again – it depends on how well you want to play the game. Corrections like the ones I’ve shown you are pretty much standard right now, and they work to the precision required of present-day Cosmology experiments. They are definitely sufficient to establish the need for Dark Energy with a high level of confidence! Nonetheless, as we gear up to the next era of Cosmology experiments, Astronomers need to match technological advancements with new ways to analyse and interpret data.

There are two main potential drawbacks in the light-curve approach. One is that this correction may be too simplistic in detail, and another is that light-curves are still not trivial to measure (they require a follow up of the explosion for days after the event). And this brings me to the paper I read last week, and which prompted this post (you thought I’d forgotten, uh? In truth I’ve been wanting to introduce Type Ia cosmology for a while!).

Jordin et al., focus not on the light-curve of the supernova, but rather on its spectrum. I have a soft spot for this sort of approach for a variety of reasons, but primarily am I attracted by the possibility that a single shot of a supernova spectrum (instead of multiple images taking during the course of days to make up the light-curve) has the same information, the same potential to calibrate supernovae brightness. In practical terms this would be some serious advantage for future cosmology experiments. This is not the first time I hear about it, although peer reviewed papers are just starting to come out on this. As others have found, Jordin et al. find that a particular chemical signature in the spectrum of a type Ia – the Silicon II absorption feature – seems to be related with how stretched a light-curve is. Further study will be needed to find out if this Silicon II feature could in the future replace – or better, improve – light-curve corrections, but the results on this paper are at least enticing.

Another thing I find attractive in this approach, is the fact they find in the supernova spectrum information about the galaxy in which it comes from. The work done to date (and I’ve done a fair bit on this, too) involves using the spectrum of the host galaxy to infer the likely properties of the environment that gave origin to the supernova, but this is not without trouble too. One of the reasons is because we can often only extract average information about a galaxy as a whole, and not about the specific bit of the galaxy the supernova comes from. The spectrum of the supernova has the potential to tell a far more direct tale, and I find that pretty exciting.

The truth is, type Ia supernova are a truly empirical probe of the Cosmos. By this I mean that the way in which we use them is based purely in empirical laws – not on any analytical or computational modelling – and that means that we must be that little bit more careful, and smart, about how we deal with the data. But there is where a lot of the fun lies…

J. Nordin, L. Ostman, A. Goobar, R. Amanullah, R. C. Nichol, M. Smith, J. Sollerman, B. A. Bassett, J. Frieman, P. M. Garnavich, G. Leloudas, M. Sako, & D. P. Schneider (2010). Spectral properties of Type Ia supernovae up to z~0.3 Astronomy and Astrophysics arXiv: 1011.6227v1