Coder Social home page Coder Social logo

1155092080 / engrenage Goto Github PK

View Code? Open in Web Editor NEW

This project forked from grtlcollaboration/engrenage

0.0 0.0 0.0 7.21 MB

A spherically symmetric BSSN code used for teaching NR

License: BSD 3-Clause "New" or "Revised" License

Python 16.14% Mathematica 9.29% Jupyter Notebook 74.57%

engrenage's Introduction

Engrenage (the code formerly known as BabyGRChombo)

Engrenage is a spherically symmetric BSSN code designed for teaching Numerical Relativity (NR), which is the solution of the Einstein Equations of General Relativity (GR) using numerical methods. The code includes a scalar field (obeying the Klein Gordon equation for a minimally coupled spin 0 field) as the matter source of the metric curvature. It currently includes two physical examples - a black hole and a real scalar boson star (or oscillaton).

Warning: This code was not designed to be a good example of optimised python usage or even of numerical relativity. The goal was to write a code where some non trivial physical examples could be studied and users could get an overview of the different parts of a numerical relativity code in action, without the optimisation and level of detail that exists in a typical research code like its parent GRChombo.

For more information and class resources see the wiki.

(Engrenage is the French word for a system of gears. Understanding any code is very much like understanding how the parts of a mechanical system fit together. It is also very common when coding to be "pris dans l'engrenage".)

Installation

Note that if you already have an installation of python3 including Jupyter, and don't want to add to the code, you could just download the zip file of the repository and save it somewhere manually.

The "correct" way to do it is as follows:

  1. Fork and clone this repository (or just download the zipped files).

  2. Having obtained a python distribution on your computer (if you are just starting out you may want to use Anaconda), create a Python environment (e.g. in ./env) using the terminal command:

    python3 -m venv ./env
  3. Activate the environment and install the Python requirements:

    # Activate the Python environment
    . ./env/bin/activate
    # Install the requirements
    pip install -r ./requirements.txt
  4. Run the Jupyter notebook:

    jupyter notebook

Acknowledgements

This code is based on a private spherically adapted (but not spherically symmetric) code by Thomas Baumgarte, and the NRpy code of Zac Etienne, in particular the formalism used closely follows that described in the papers Numerical relativity in spherical polar coordinates: Evolution calculations with the BSSN formulation and SENR/NRPy+: Numerical relativity in singular curvilinear coordinate systems.

This code has also benefitted from input from Nils Vu @nilsvu ("You don't use python environments? I don't even know where to start..."), Leo Stein @duetosymmetry ("Why wouldn't you use the existing numpy functions for that?") and bug spotting from Cristian Joana @cjoana and Cheng-Hsin Cheng @chcheng3 when this code debuted at the ICERM Numerical Relativity Community Summer School in August 2022, and David Sola Gil @David-Sola-Gil in the London LTCC course February 2023. Thanks also to Marcus Hatton @MarcusHatton for the addition of animation to the figures.

The main developer of engrenage is Katy Clough, who is supported by a UK STFC Ernest Rutherford Fellowship ST/V003240/1.

engrenage's People

Contributors

kaclough avatar 1155092080 avatar chcheng3 avatar duetosymmetry avatar cjoana avatar marcushatton avatar nilsvu avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.