Skip to content

KerrP2P is a software designed for forward ray tracing in Kerr spacetime. It is specifically tailored to efficiently calculate multiple null geodesics between designated "source" and "observer" points, locate apparent positions of the corresponding images, and quantify their shapes.

License

Notifications You must be signed in to change notification settings

AuroraDysis/KerrP2P

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

KerrP2P (Kerr Point-to-Point)

KerrP2P is a software designed for forward ray tracing in Kerr spacetime. It is specifically tailored to efficiently calculate multiple null geodesics between designated "source" and "observer" points, locate apparent positions of the corresponding images, and quantify their shapes. Detailed information can be found in the paper Forward Ray Tracing and Hot Spots in Kerr Spacetime by Lihang Zhou, Zhen Zhong, Yifan Chen, and Vitor Cardoso.

Using Jacobi elliptic functions to express the solutions to the geodesic equations based on Gralla and Lupsasca 2019, this software consists of two tools.

  1. A Python/C++ package that computes null geodesics and thoroughly explores the parameter space to identify multiple images. Tutorials for it are presented in the folder examples:

    • tutorial_float64_sweep.ipynb: geodesic calculation and parameter space sweep in double precision
    • tutorial_float128or256.ipynb: geodesic calculation in quad/oct precision
    • cpp_tutorial_basic.cpp: geodesic calculation
    • cpp_tutorial_sweep.cpp: parameter space sweep
  2. A Mathematica code: examples/tutorial_geodesic_and_image.nb. It also includes functions for geodesic calculation and can be utilized to visualize geodesics, image positions, and image shapes.

Paper License

Features

  • Forward ray tracing in Kerr spacetime: this involves calculating multiple null geodesics that connects a given source to an observer
  • Support for arbitrary precision arithmetic
  • Python bindings for easy to use interface
  • Support for multiple platforms: Linux, macOS, and Windows

Installation

Prerequisites

Before installing KerrP2P, ensure that you have the following dependencies installed on your system:

  • Boost (with filesystem components)
  • Catch2 (optional, for testing)
  • fmt
  • GMP (optional)
  • MPFR (optional)
  • MPC (optional)
  • Eigen
  • Intel oneAPI TBB
  • Python (optional)
  • pybind11 (optional)

Linux

On Linux, you can use Spack to install the dependencies:

spack:
  specs:
    - boost+filesystem
    - catch2
    - fmt
    - gmp
    - mpfr
    - mpc
    - eigen
    - intel-oneapi-tbb
    - python
    - py-pybind11
  view: true
  concretizer:
    unify: true

macOS

On macOS, you can use Homebrew to install the dependencies:

brew install boost catch2 fmt gmp mpfr mpc eigen tbb python pybind11

Windows

On Windows, you can use vcpkg to install the dependencies:

vcpkg.exe install boost catch2 fmt eigen3 tbb python3 pybind11

Usage

To use KerrP2P, follow these steps:

  1. Clone the repository:
git clone https://github.com/your_username/KerrP2P.git
  1. Build the project using CMake.
cd KerrP2P
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
make

Remember to copy the generated .so file to your working directory.

Contributing

Contributions to KerrP2P are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request on the GitHub repository.

License

KerrP2P is released under the MIT License. See the LICENSE file for more details.

Citation

If you use KerrP2P in your research, please cite the following paper:

@article{Zhou:2024dbc,
    author = "Zhou, Lihang and Zhong, Zhen and Chen, Yifan and Cardoso, Vitor",
    title = "{Forward Ray Tracing and Hot Spots in Kerr Spacetime}",
    eprint = "2408.16049",
    journal = "",
    archivePrefix = "arXiv",
    primaryClass = "gr-qc",
    month = "8",
    year = "2024"
}

About

KerrP2P is a software designed for forward ray tracing in Kerr spacetime. It is specifically tailored to efficiently calculate multiple null geodesics between designated "source" and "observer" points, locate apparent positions of the corresponding images, and quantify their shapes.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published