Gal Science: How to Build a Galaxy and Fight an Army

ageofempiresAs The Toast searches for its one true Gal Scientist, we will be running a ton of wonderful one-off pieces by female scientists of all shapes and sizes and fields and education levels, which we are sure you will enjoy. They’ll live here, so you can always find them. Most recently: Parasite Tales for Every Occasion. This column is sponsored by the author herself, who nicely waived her fee.

It was an epic battle.

Cavalry pounded through the gates, aiming for the deadly catapults that were hurling stone missiles into crumbling city walls. Ropes snapped and wheels collapsed, but the horsemen were overwhelmed by enemy swordsmen. Archers charged out from behind smoking towers to assist, but were cut down before their bow strings had even released the second volley of arrows. The town was swarmed by fighters who mercilessly trampled farms and buildings, not resting until they had annihilated every last man, woman and child.

“You have been defeated!”

The message flashed across the computer screen as the game froze on the image of the smouldering ruin of my civilisation. I had lost my virtual mediaeval battle to a pile of wires and silicon chips. It was deeply unfortunate. Fortunately, unlike a real war, with a few clicks of my mouse and I could try again…and again…and…well, it was a difficult game but I was confident I would eventually be victorious.

It is also exactly like my job.

me_conivalBy day (and occasionally by caffeine-filled nights) I build galaxies in my computer. To be more specific, I use simulations to try and understand what causes stars to form.

The similarities between astrophysics and virtual mass slaughter for recreational purposes begin at the start of both activities. When ready for a fresh attempt at Mediaeval apocalypse, the game presents the player with only a small town centre and a few peasants. Likewise, my simulations begin with a very simple model of how I think a galaxy might look in the early stages of its life. Since stars are born out of gas, my current work begins with a smooth rotating gas disk, like a spinning frisbee.

The archers, cavalry and swordsmen are akin to the physics that I include to control how the galaxy changes over time. For example, the galaxy’s gas will cool and heat, gravity will pull things together and stars will begin to form.

Once we begin the simulation, battle is commenced. Large simulations run on supercomputers capable of calculating what happens to the galaxy over millions of years. Sometimes this can be computed in less than a day but very big simulations can take months to complete. Once finished, the model galaxy can be compared to actual galaxies observed in the Universe. As with my latest game attack strategy, this is the point where not everything goes to plan…

In a recent case, instead of producing a beautiful galaxy disk glittering with stars, my simulation returned a misshaped blob. Embedded in this mess were two or three huge boils of stars, giving an end product that more strongly resembled a half-eaten pepperoni pizza than a galactic beauty. To emphasise the complete failure of this model, streams of stars were shooting alway from the galaxy as if demanding a better life.

“You have been defeated!”

The words did not flash up on the terminal, but the message was very clear. As with the computer game, I could restart my simulation and try again. The problem was, I was not sure what had gone awry. I was expecting my smooth disk to fragment into many dense knots of gas, so that its surface would resemble a mass of small bumps and ridges like the face of an ornamental cabbage. Within these chilly knots, gas would be pressed together so tightly atoms would fuse and the first stars would begin to shine. The end product would have stars spread evenly over its surface, not only in a few giant patches.

As with the carnage of archers, peasants and horses in the computer game, there were many possibilities as to why the model galaxy did not resemble its genuine counterparts. For instance, similar to the way a cooking sauce can become lumpy as it get cold, a galaxy needs to cool to form the gas knots that birth stars. If the galaxy is too hot, then these stellar nurseries can never form, leaving a starless region of space. Alternatively, the recipe I was using to decide when a star is born might not be correct, producing stars in the wrong places or at the wrong times. Another possibility was that there was a key ingredient, like a different military troop, missing from my simulation that was essential for a realistic galaxy.

The crux of the matter was there were too many possible problems and I could not untangle one from the other to discover the real issue. This was true for both the galaxy and the computer game: what did I need to change for success?

It was time to do some exploring.

I returned first to the computer game and this time created an army only of cavalry. Using a single combat unit was not enough to defeat the enemy, but it allowed me to understand exactly what that soldier could do in battle.

Since cavalry require both a mount and a person, these troops were expensive and slow to create. This restricted me to a smaller army. However, the horses could move far faster than other armed forces and were able to reach the enemy at speed. This was particularly useful in dissembling siege equipment before it came within the firing distance of my city walls.

In previous games, I had created a small number of horsemen to take out heavy enemy equipment. This exploration in a calvary-only game confirmed this was an effective strategy and therefore not the reason for the regularity of the soul-crushing defeats.

I therefore loaded up the game for a second time and on this occasion, focussed on archers. Archers turned out to be great against swordsmen and other foot soldiers. Their bows had an excellent range, resulting in the enemy force being peppered with arrows before they could get close enough to retaliate. Their weakness was against fast moving troops such as cavalry. Horsemen could reach the archers between volleys of arrows and at close quarters, archers had very little defence. The best position for an archer was therefore behind a wall, where they could take aim at the enemy but be protected from close-up combat.

This had been the problem with my previous strategy. I had placed archers outside the city, where they were easily cut down. It was time to try this battle again.

***

The next scene has been cut to allow this article to appeal to a wider audience. Needless to say, it contains many acts of violent in which innocent pixellated warriors were crushed to death.

***

“You have been victorious!”

deskSuccess was mine, but could these new battle tactics also apply to galaxies? I moved back to the simulations, this time allowing the galaxy’s gas to change temperature but not permitting stars to form. It did not matter how dense a patch of gas became, I forbade it to start shining. This was the equivalent to my single-troop games: was the galaxy cooling as I expected, or did it stay too warm to make the cold knots for star birth chambers?

After a few hundred million years of simulation time and roughly two days of my time, my star-free galaxy was complete. The result was a spinning disk of gas scattered with cold knots all over its surface. Like my cavalry troops, the galaxy’s temperature was doing exactly what I expected. The problem was elsewhere.

I turned back on star formation and ran the simulation for a second time. Very quickly, I saw problems occurring with the galaxy eroding from a thin disk to a shrunken mass of silly putty. The star formation recipe was the archers; it was clearly needed but I was implementing it badly.

Carefully, I scrutinised the galaxy as the simulation ran. While knots of gas formed all over the disk, the stars almost only appeared in the very largest knots. As a result, these stars became incredibly concentrated, bunching together in a small number of super-clusters. It was like buying 20 pepperoni slices for your pizza but piling them into just three huge piles rather than spreading them evenly over the base.

These huge star consortiums started to orbit the galaxy’s centre, but they were so massive that their gravitational pull affected everything around them. Imagine you had a taut rubber sheet on which you dropped a few very heavy canon balls. The weight of those objects would distort your sheet from its original flat surface and any smaller objects would roll towards the balls. In the same way, the galaxy disk was being pulled out of shape by these massive clusters of stars. Any smaller stars born outside the giant clumps felt a huge tug as if they were being dragged down the steep dip in the rubber sheet. The tug was so strong that the stars could be accelerated up to 1000 km/s (about 2,240,000 miles per hour) and stream out of the galaxy.

xc30What was needed was for the stars to form in all the gas knots, not just the very biggest. This would mean that huge numbers of stars would not form solely at the same location, but spread evenly through the galaxy. To do this, I adjusted my star recipe so that stars could form at a lower density than before. The gas for the star birthplace still had to be a cold knot, but it did not need to be quite so compacted as before.

Another two days later and I had my new results. The galaxy was a disk of glittering stars and completely lacking in half-eaten pepperoni pizza look-a-likes.

Was this the ultimate victory? I had crushed my enemies, both the sword wielding mediaeval fighters and the pepperoni star clusters. Yet, in all the best fight scenes, the arch nemesis returns for the sequel.

The stars had formed in my galaxy, but still their birth rate and numeracy did not match that of observed real galaxies. That would be the fight for another game.

Tags: , ,

16 Comments

  1. cuminafterall +4

    Ahhh this blows my mind! I’d like to go back in time to nine years old, when astrophysics was my dream career, and whisper in my own ear and make it happen. As I can’t do that, I’m planning to take calculus for the first time at age 26.

    1. ejtasker +2

      I also became interested in astrophysics when I was 9! My Dad took me to the London planetarium and I was hooked.

      Although, I was quite insistent I wanted to be a vet until I was 13… whereupon I took one of those career aptitude and interest tests which pointed out that my dream of driving around the Yorkshire countryside sticking arm up cows’ rear behinds (I was reading a lot of James Herriot at the time) was completely at odds with my desire to play with computers and destroy universes.

      You’ll love calculus (I hope)! When I started studying it, I realised what an incredible language mathematics was.

  2. TiaBaheri +9

    Have you tried entering a “coolest job in the world” contest? Is there such a contest? If so, I think the odds are in your favor. This is like a superhero story. I, for one, am also extremely curious about your non-superhero Japanese canteen experiences. Canteen+ foreign language situations make for hilarity.

    1. ejtasker +4

      Thank you! Though I have to admit to editing the parts where frustration made me threaten my computer with being dropped out a window. (I always threaten. Verbally and with hand gestures. I’m pretty sure it helps.)

      The canteen is a daily mini adventure! Fortunately, I don’t have any dietary requirements so as long as I emerge from the experience with a bowl of food, I consider it a huge success. I think the biggest surprise I’ve had (given that I have no real faith in getting what I expect) is when the dish is the wrong temperature. You can’t tell that from the pictures (or plastic models) so I’ve sometimes ordered a bowl of noodles and found it was served cold. That’s surprisingly disconcerting….

  3. Elizabeth

    I also became interested in astrophysics when I was 9! My Dad took me to the London planetarium and I was hooked.

    Although, I was quite insistent I wanted to be a vet until I was 13… whereupon I took one of those career aptitude and interest tests which pointed out that my dream of driving around the Yorkshire countryside sticking arm up cows' rear behinds (I was reading a lot of James Herriot at the time) was completely at odds with my desire to play with computers and destroy universes.

    You'll love calculus (I hope)! When I started studying it, I realised what an incredible language mathematics was.

  4. Elizabeth

    Thank you! Though I have to admit to editing the parts where frustration made me threaten my computer with being dropped out a window. (I always threaten. Verbally and with hand gestures. I'm pretty sure it helps.)

    The canteen is a daily mini adventure! Fortunately, I don't have any dietary requirements so as long as I emerge from the experience with a bowl of food, I consider it a huge success. I think the biggest surprise I've had (given that I have no real faith in getting what I expect) is when the dish is the wrong temperature. You can't tell that from the pictures (or plastic models) so I've sometimes ordered a bowl of noodles and found it was served cold. That's surprisingly disconcerting….

  5. normal_catlady +5

    I love how you explained your research! It made it accessible to me but I could also appreciate your expertise. My grad research is also simulations but on the opposite end of the scale! I do all-atom simulations of proteins. Do you maintain your own cluster? But your last picture looks like a supercomputer. Please write more! I would love to read more about your research and your adventures in the cafeteria! I cannot stop typing exclamations!!! Computational physicists on the toast!!!

    1. ejtasker +4

      High five, fellow computational physicist! My first taste of computational physics was actually down at your scale, but I was only an undergraduate, so I did not get very into depth. I did my final year project using CASTEP, which models the electron density.

      We do maintain a “small” (64 x 8 processors) cluster at the university but we also have time on the supercomputer in Tokyo (a huge Cray). And when I say “we maintain” I really mean our graduate students do the work!

  6. Elizabeth

    High five, fellow computational physicist! My first taste of computational physics was actually down at your scale, but I was only an undergraduate, so I did not get very into depth. I did my final year project using CASTEP, which models the electron density.

    We do maintain a "small" (64 x 8 processors) cluster at the university but we also have time on the supercomputer in Tokyo (a huge Cray). And when I say "we maintain" I really mean our graduate students do the work!