This repository contains code for calculating Hawking radiation measurements by an Unruh-DeWitt particle detector near the horizon of a Schwarzschild black hole.
Results and a discussion of the implementation can be found in the paper:
C.J. Shallue and S.M. Carroll, What Hawking Radiation Looks Like as You Fall into a Black Hole, 2024.
Required packages and their versions can be found in the hawkrad.yml
Conda environment file. The easiest way to install the pre-requisites is to make a new Conda environment from that file:
conda env create -f hawkrad.yml
The code in this repository does not need any special installation because it is pure Python. The easiest way to use it is to add the top-level repository directory (i.e., the one containing the hawkrad
directory) to the PYTHONPATH
environment variable.
As described in more detail below, the code makes use of asymptotic expansions of solutions to the radial wave equation. Tables of coefficients of these asymptotic expansions have been pre-computed and are archived at https://zenodo.org/records/14205556.
Measurements by an infalling detector can be generated by the script scripts/radial_response.py
.
Required command-line flags:
-
--Omega
: Detector energy gap ($E$ in the paper) in units of$R_S^{-1}$ . Can be a list. -
--omega
: List of$\omega$ values to evaluate in units of$R_S^{-1}$ . -
--ell
: Which ells to evaluate. -
--r_mid
or--tau_mid
:$r_\text{mid}$ or$\tau_\text{mid}$ in units of$R_S$ . Can be a list. -
--delta_tau
:$\Delta \tau$ in units of$R_S$ . Can be a list. -
--R_rest
: Schwarzschild radial coordinate in units of$R_S$ at which the detector is instantaneously at rest ($R$ in the paper). Default is "inf" (meaning$R=\infty$ ). -
--asym_coeffs_dir
: Directory containing tables of coefficients of the asymptotic forms of the radial modes (from this data archive or computed as described in more detail below). -
--output_dir
: Output directory.
Additional options can be found by running radial_response.py --help
. These control the precision of the integrals and ODE solvers, the convergence tests, etc., and can be used to optimize the runtime.
The main output files have the form terms_ell*.npy
. Each of these corresponds to a particular value of numpy
array of shape (n_omega, n_Omega, n_chi, 6)
, where n_omega
is the number of n_Omega
is the number of detector energy gaps, n_chi
is the number of switching functions each defined by a pair of values
$F_\text{B}^\text{in}$ $F_\text{B}^\text{up}$ $F_\text{H}^\text{in} - F_\text{B}^\text{in}$ $F_\text{H}^\text{up} - F_\text{B}^\text{up}$ $F_\text{H}^{\overline{\text{in}}}$ $F_\text{H}^{\overline{\text{up}}}$
Each of these quantities needs to be integrated over
The instantaneous response rate of a static detector (i.e., with fixed Schwarzschild coordinates) near the horizon can be calculated using the script scripts/radial_static.py
.
The required flags are
-
--R
: Schwarzschild radial coordinate in units of$R_S$ . Can be a list. -
--ell_max
: Maximum value of$\ell$ . -
--omega
: Same as inradial_response.py
. -
--asym_coeffs_dir
:Same as inradial_response.py
. -
--output_dir
: Output directory.
The output is saved in a file F_in_up.npy
, which contains a numpy
array of shape (n_ell, n_omega, n_R, 2)
, where n_ell
is the number of n_omega
is the number of n_R
is the number of
$|\Phi_{\omega\ell}^\text{in}(R)|^2$ $|\Phi_{\omega\ell}^\text{up}(R)|^2$
These two values can be combined to compute the instantaneous response of a static detector using the formulas in Hodgkinson et al. [2].
The code uses units in which the fundamental constants
This means, for example, that lengths have units of
In these units, the Hawking temperature of the black hole is
Another choice of units, which is used in the paper, is to set
Depending on the context, the Schwarzschild radial coordinate is encoded in 3 different ways in the code:
-
$r$ , the Schwarzschild radial coordinate in units of$R_S$ . -
$x \equiv r - 1$ . We use this representation because when$r$ is very close the horizon (within around1e-16
for 64-bit floating point numbers),$r$ is effectively truncated to 1.0, whereas$x$ can represent values much closer to the horizon (within around1e-308
). -
$r_*$ , the Regge-Wheeler tortoise coordinate, defined by
In the code (and in the remainder of this README), rhoIn
and rhoUp
correspond to the radial functions rhoIn
means rhoUp
means
xiIn
and xiUp
in the code correspond to
tildePhiIn
and tildePhiUp
in the code correspond to
We use power series expansions for the in modes asymptotically close to the horizon and for the up modes asymptotically far from the horizon, as described in Hodgkinson [1].
For the in modes, we write
and expand
for
The
For the up modes, we write
and expand
for
The c-coeffs-100.dat
in the data archive contains the coefficients for Get
function. The file c-coeffs-100.csv
contains the same coefficients in a format that can be read by the CoeffGenerator
class.
The CoeffGenerator
class (the file c-coeffs-100.csv
is needed for the sympy
to avoid roundoff errors and keep the coefficients as precise as possible.
To avoid re-calculating the coefficients every time, we generated tables of in/
and up/
directories should be passed to the --asym_coeffs_dir
flag. New tables can be generated using the script scripts/gen_asym_coeffs_tables.py
.
We use scipy
to solve for the scipy.integrate.solve_ivp
. We solve with
where
In order to solve for the in and up modes, we specify boundary conditions by evaluating the asymptotic solutions near the horizon (for the in modes) and far from the horizon (for the up modes).
Since solving these ODEs accounts for a significant component of the overall runtime, we made various optimizations to reduce the time spent solving them, which can be found in the file ode_system.py
.
If you find this code useful, please consider citing the paper
C.J. Shallue and S.M. Carroll, What Hawking Radiation Looks Like as You Fall into a Black Hole, 2024.
[1] L. Hodgkinson, Particle Detectors in Curved Spacetime Quantum Field Theory (2013) https://arxiv.org/abs/1309.7281.
[2] L. Hodgkinson, J. Louko, and A. Ottewill, Static detectors and circular-geodesic detectors on the Schwarzschild black hole, Physical Review D (2014) https://doi.org/10.1103/PhysRevD.89.104002.