$30 off During Our Annual Pro Sale. View Details »

Python at the speed of light - Simulating Relativity using EinsteinPy

Python at the speed of light - Simulating Relativity using EinsteinPy

An introduction to the very new python package "EinsteinPy", and how it helps to solve the greatest and most complex problem of all times - General Relativity. EinsteinPy is an Astropy Affiliated Package and a member organisation in ESA Summer of Code in Space 2019.

View talk here: https://cloudproject.hosted.panopto.com/Panopto/Pages/Viewer.aspx?id=8f42ed8d-d329-4f10-9ed4-aa9a0107f880

Lightning talk delivered at Python in Astronomy 2019 @ Space Telescope Science Institute, Baltimore, United States of America

Shreyas Bapat

July 29, 2019
Tweet

More Decks by Shreyas Bapat

Other Decks in Programming

Transcript

  1. Python at the speed of light
    Simulating relativity using EinsteinPy
    Lightning Talk
    Shreyas Bapat @astroshreyas
    PyAstro 2019 @ STScI, Baltimore (USA) 29/07/2019

    View Slide

  2. Who is this guy?
    ● Undergraduate (Electrical
    Engineering) from IIT Mandi,
    India
    ● Amateur Astronomer
    ● Software Intern @ Siemens
    ● Passionate about open code
    ● Former Coordinator of Space
    Technology and Astronomy Cell,
    IIT Mandi

    View Slide

  3. What’s Wrong?
    According to derivation from Maxwell’s equation, speed of light is
    given by :
    ● The equation does not depend upon the position or velocity of
    the observer.
    ● This contradicts with Galileo’s and Newton’s perception of
    velocity(classical mechanics)

    View Slide

  4. Incorporate Gravity into SR (GR)
    ● Special Relativity - 1905
    ● General Relativity - 1916
    ● First exact solution to GR(Schwarzschild Solution) - 1916

    View Slide

  5. Straight lines in curved space!
    ● Introduction to geodesics
    ● In differential geometry, a geodesic is a curve representing in some sense the
    shortest path between two points in a surface, or more generally in a Riemannian
    manifold. It is a generalization of the notion of a "straight line" to a more general
    setting.

    View Slide

  6. Einstein’s Field Equation (EFE)
    Einstein's equation relates the matter content
    (right side of the equation) to the geometry (the
    left side) of the system. It can be summed up with
    "mass creates geometry, and geometry acts like
    mass".

    View Slide

  7. Schwarzschild Solution
    ● Kerr Solution
    ● Kerr-Newman Solution
    ● No-hair theorem

    View Slide

  8. What is

    View Slide

  9. Astropy Affiliated
    Package (Recently)

    View Slide

  10. Astropy Affiliated
    Package
    The only project which
    targets GR

    View Slide

  11. The EinsteinPy Core Team
    Shreyas Bapat
    Lead Developer
    Coordinates,
    Plotting and
    Packaging
    Ritwik Saha
    Lead Developer
    Symbolic
    Bhavya Bhatt
    Theoretical
    Physicist
    Metrics and ODE
    Priyanshu Khandelwal
    Lead Developer
    Conda Packaging,
    Adaptive Mesh Refinement

    View Slide

  12. Complete Workflow on GitHub

    View Slide

  13. OSI Approved Licence

    View Slide

  14. General Details
    ~ 28 Contributors so far!
    ~ 3200 Downloads (PyPi + conda)
    ~ 112 Stars (We want more :p)
    Packaged in Debian Astro Pure Blend

    View Slide

  15. Testing and Continuous Integration

    View Slide

  16. The EinsteinPy Package
    Key functionality and common tools needed for doing general relativity,
    gravitational physics, relativistically corrected orbit dynamics with Python

    View Slide

  17. The EinsteinPy Package
    Key functionality and common tools needed for doing general relativity,
    gravitational physics, relativistically corrected orbit dynamics with Python
    Key Features :
    Geometry analysis and trajectory calculation in vacuum solutions of
    Einstein’s field equations.
    - Schwarzschild Space-Time
    - Kerr Space-Time
    - Kerr-Newman Space-Time

    View Slide

  18. The EinsteinPy Package
    Key functionality and common tools needed for doing general relativity,
    gravitational physics, relativistically corrected orbit dynamics with Python
    Key Features :
    Coordinates support
    (~einsteinpy.coordinates)
    - Cartesian Coordinates
    - Spherical Coordinates
    - Boyer Lindquist Coordinates

    View Slide

  19. The EinsteinPy Package
    Key functionality and common tools needed for doing general relativity,
    gravitational physics, relativistically corrected orbit dynamics with Python
    Key Features :
    Symbolic Calculations
    - Christoffel Symbols
    - Riemann Curvature Tensor
    - Simplification of symbolic expressions
    - Weyl Tensor, Einstein Tensor
    SOCIS Student: Sofía Ortín Vela, Universidad de Zaragoza (Spain)

    View Slide

  20. The EinsteinPy Package
    Key functionality and common tools needed for doing general relativity,
    gravitational physics, relativistically corrected orbit dynamics with Python
    Key Features :
    Visualisation of Geodesics
    - 2D, 3D Visualisation using Matplotlib
    - 2D, 3D Interactive Visualisation using Plotly
    - Environment aware plotting and backend selection

    View Slide

  21. Let’s shoot a particle towards a Kerr Black hole

    View Slide

  22. Interesting : The Logo! They are geodesics
    (Plotted using matplotlib and EinsteinPy :P)

    View Slide

  23. Get in touch with EPy Community!
    Mailing List : [email protected] (https://groups.io/g/einsteinpy-dev)
    Chatroom : https://matrix.to/#/#einsteinpy:matrix.org
    Developer Support : [email protected]
    GitHub : https://github.com/einsteinpy/einsteinpy
    Blog : https://einsteinpy.org
    Documentation: https://docs.einsteinpy.org

    View Slide

  24. Get in touch :D
    GitHub : shreyasbapat
    Twitter : @astroshreyas
    You can follow me to keep updated :)
    Or mail me :
    [email protected] , [email protected]

    View Slide