-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* updated docstrings in places * added documentation directory * ci deploy * test workflow for documentation * fix glaring typo * documentation badge * updated documentation workflow
- Loading branch information
Showing
32 changed files
with
468 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: docs | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
docs: | ||
name: Build and publish | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: julia-actions/setup-julia@v1 | ||
with: | ||
version: '1' | ||
- run: | | ||
julia --project=docs -e ' | ||
using Pkg | ||
Pkg.develop(PackageSpec(path=pwd())) | ||
Pkg.instantiate()' | ||
- run: julia --project=docs docs/make.jl | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[deps] | ||
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
push!(LOAD_PATH,"src") | ||
|
||
using Documenter | ||
using Gradus | ||
|
||
makedocs( | ||
modules=[Gradus], | ||
clean=true, | ||
sitename="Gradus.jl Documentation", | ||
|
||
pages = [ | ||
"Home" => "index.md", | ||
"Overview" => [ | ||
# "Examples" | ||
"Geodesic integration" => "overview/geodesic-integration.md" | ||
"Implemented metrics" => "overview/metrics.md" | ||
], | ||
"Internals" => [ | ||
"Custom metrics" => "internals/custom-metrics.md" | ||
], | ||
"Module API" => [ | ||
"Gradus" => "api-documentation/Gradus.md", | ||
"GradusBase" => "api-documentation/GradusBase.md" | ||
] | ||
] | ||
) | ||
|
||
deploydocs( | ||
repo = "github.com/astro-group-bristol/Gradus.jl.git" | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Gradus API | ||
|
||
```@meta | ||
CurrentModule = Gradus | ||
``` | ||
## Special radii | ||
|
||
```@docs | ||
isco | ||
r_ph | ||
r_mb | ||
r_s | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# GradusBase API | ||
|
||
```@meta | ||
CurrentModule = Gradus.GradusBase | ||
``` | ||
|
||
```@docs | ||
AbstractMetricParams | ||
geodesic_eq | ||
geodesic_eq! | ||
constrain | ||
inner_radius | ||
metric | ||
vector_to_local_sky | ||
``` | ||
|
||
## Physical Quantities | ||
```@docs | ||
E | ||
Lz | ||
``` | ||
|
||
## Geodesic Points | ||
|
||
```@docs | ||
GeodesicPoint | ||
getgeodesicpoint | ||
unpack_solution | ||
``` |
Empty file.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Gradus.jl Documentation | ||
|
||
A pure Julia geodesic integration system built on [DifferentialEquations.jl](https://github.com/SciML/DifferentialEquations.jl) using automatic differentiation (AD) and computer algebra systems (CAS) to efficiently compute the geodesic equation. This package requires only a specification of the non-zero metric components in order to solve the 2nd order geodesic system. Alternatively, an implementation of the four velocity components may be specified to integrate a regular 1st order system. | ||
|
||
The motivation behind this package began with an interest in studying reverberation lags around accreting black holes, however the scope has since expanded to facilitate the exploration of generic metrics through time-like, space-like, and null geodesics. | ||
|
||
Our aim is to make testing modified Kerr metrics and alternative gravity theories _fast_. | ||
|
||
```@raw html | ||
<p align="center" pa="0" ma="0"> | ||
<img width="30%" src="assets/uob-astro-grey.png"> | ||
</p> | ||
``` | ||
|
||
Gradus.jl allows for drastically different relativistic simulations to be computed with a composable and reusable API, permitting an end user to simply and expressively calculate physical formulae, create observational signatures, and interface with other popular astrophysics tools. Gradus.jl implements a number of high level abstractions, on the path towards a fully parallelized, high performance numerical relativity ecosystem, scalable from personal computers to super computers. | ||
|
||
## About | ||
|
||
Gradus.jl is a research tool for calculating geodesic paths in arbitrary space-times. It is currently work-in-progress, and breaking changes are frequent, as the interface is redesigned to match changing use-cases. | ||
|
||
It is part of a larger developing eco-system of *Strong Gravity Codes*, created by members of the University of Bristol Astrophysics Group | ||
|
||
- Fergus Baker (PhD Student) | ||
- Dr. Andrew Young (Associate Professor) | ||
|
||
For more University of Bristol Astrophysics Group codes, see [our GitHub organisation](https://github.com/astro-group-bristol). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Defining a new metric | ||
|
||
```@meta | ||
CurrentModule = Gradus | ||
``` | ||
|
||
Gradus.jl is able to integrate any 3+1 dimensional metric, however provides a few derivative abstract types to implement to ensure the most efficient code is executed for a given metric. Currently, Gradus differentiates the following specializations: | ||
|
||
|
||
## First-Order | ||
|
||
```@docs | ||
FirstOrderMethods.AbstractFirstOrderMetricParams | ||
FirstOrderMethods.four_velocity | ||
FirstOrderMethods.calc_lq | ||
FirstOrderMethods.Vr | ||
FirstOrderMethods.Vθ | ||
``` | ||
|
||
## Second-Order | ||
|
||
```@docs | ||
GeodesicTracer.AbstractAutoDiffMetricParams | ||
GeodesicTracer.metric_components | ||
GeodesicTracer.AbstractAutoDiffStaticAxisSymmetricParams | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
# Geodesic integration strategies | ||
|
||
|
||
## Second-Order | ||
|
||
The motivation behind the second-order methods is to permit the computation of geodesics in generic spacetimes, via the geodesic equation | ||
|
||
```math | ||
\frac{\text{d}^2 x^\mu}{\text{d} \lambda^2} | ||
+ \Gamma^{\mu}_{\phantom{\mu}\nu\sigma} | ||
\frac{\text{d}x^\nu}{\text{d} \lambda} | ||
\frac{\text{d}x^\sigma}{\text{d} \lambda} | ||
= 0, | ||
``` | ||
|
||
where ``x^\mu`` is a position four-vector, ``\Gamma^{\mu}_{\phantom{\mu}\nu\sigma}`` are the Christoffel symbols of the second kind, and ``\lambda`` the affine parameter describing the curve. | ||
|
||
The above can be solved as a second-order ODE, subject to an initial position and initial velocity | ||
|
||
```math | ||
u^\mu = \left(t, r, \theta, \phi \right), | ||
\quad | ||
\text{and} | ||
\quad | ||
\dot{u}^\mu | ||
= \left( \dot{t}, \dot{r}, \dot{\theta}, \dot{\phi} \right), | ||
``` | ||
where the dot refers to the derivative with respect to ``\lambda``. In general, the spatial components of the initial velocity are known _a priori_, and the time-component is determined via the constraint: | ||
|
||
```math | ||
g_{\sigma\nu} \dot{u}^\sigma \dot{u}^\nu = -\mu^2, | ||
``` | ||
|
||
with the metric tensor ``g_{\mu\nu}``, and where ``\mu`` is related to the effective mass associated with the geodesic. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# Implemented Metrics | ||
|
||
```@meta | ||
CurrentModule = Gradus | ||
``` | ||
|
||
## First-Order | ||
```@docs | ||
BoyerLindquistFO | ||
``` | ||
|
||
## Second-Order | ||
```@docs | ||
BoyerLindquistAD | ||
JohannsenAD | ||
KerrRefractiveAD | ||
DilatonAxionAD | ||
MorrisThorneAD | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.