Contribute Media
A thank you to everyone who makes this possible: Read More

Python in Astronomy


Sławomir Piasecki - Python in Astronomy [EuroPython 2016] [21 July 2016] [Bilbao, Euskadi, Spain] (

I would like to talk about modern Astronomy where I would give a brief history of Astronomy. I will answer some question: What do we use computers for today in astronomy? Where is Python’s place in today’s science? Is Python is the best language for scientific computation? I would like to give a short introduction into AstroPy module. Finally I would like presents some result of my research where Python was used to create data.

For ages people have been watching the sky, and tried to learn something about all those mysterious lights. In ancient times, scientist used mostly their naked eyes to watch what happened in the night sky. Astronomy is one of the oldest fields in science. Everything changed when Galileo invented his lunette. Thanks to thi, we were able to proof Copernicus’ new model of the solar system with the sun in the center.

The next big step in Astronomy was using computers. Where there are computers and Astronomy, there is a place for programming. For many years astronomers were mostly using Fortran and C/C++. Both are suited to numeric computation and scientific computing. Since they are structured programming language, that makes them very valuable for science.

Over the past decade, Python has started to be used by more and more people in astronomy. But is there a place in Astronomy for Python, as it is not as fast as Fortran or C/C++? In Python there is a module called AstroPy which helps astronomers in their work.

MatPlotLib is one of the most popular library use in astronomy. This tool helps created very sophisticated plots and graphs.

Finally I would like talk about some research I did using Python. For research, we decided to use AUTO. It is a hybrid of Fortran and Python, to compute bifurcation points in mathematical models. In Python we introduce mathematical model, ODE and initial parameters. Fortran does all the computation.


Improve this page