Skip to content

Commit 8e8a8ed

Browse files
Merge branch 'main' of github.com:michael-petersen/LinearResponse.jl
2 parents 8701e4d + 1f92259 commit 8e8a8ed

File tree

1 file changed

+26
-12
lines changed

1 file changed

+26
-12
lines changed

README.md

Lines changed: 26 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,20 +12,22 @@ To fully use **LinearResponse.jl**, you will need **OrbitalElements.jl**, **Fini
1212

1313
The libraries under the JuliaStellarDynamics organisation are currently unregistered[^1]. To add them to your julia[^2] registry, follow these steps:
1414

15-
You may add all the packages[^3][^4] at once with this command:
15+
You may add all the packages[^3] at once with this command:
1616
```
17-
julia -e 'using Pkg; Pkg.add(url="https://github.com/JuliaStellarDynamics/OrbitalElements.jl.git"); Pkg.add(url="https://github.com/JuliaStellarDynamics/AstroBasis.jl.git"); Pkg.add(url="https://github.com/JuliaStellarDynamics/FiniteHilbertTransform.jl.git"); Pkg.add(url="https://github.com/JuliaStellarDynamics/LinearResponse.jl.git")'
17+
julia -e 'using Pkg; Pkg.add(url="https://github.com/JuliaStellarDynamics/FiniteHilbertTransform.jl.git");
18+
Pkg.add(url="https://github.com/JuliaStellarDynamics/OrbitalElements.jl.git");
19+
Pkg.add(url="https://github.com/JuliaStellarDynamics/AstroBasis.jl.git");
20+
Pkg.add(url="https://github.com/JuliaStellarDynamics/LinearResponse.jl.git")'
1821
```
1922

2023
You can confirm the current version with `status LinearResponse` in the julia package manager.
2124

22-
2325
---
2426
## Quickstart
2527

2628
To reproduce the Plummer radial orbit instability calculation, see the example script in `examples/PlummerE/runExamplePlummer.jl`. Download the file by running:
2729
```
28-
wget ttps://github.com/JuliaStellarDynamics/LinearResponse.jl/blob/main/examples/PlummerE/runExamplePlummer.jl
30+
wget https://github.com/JuliaStellarDynamics/LinearResponse.jl/blob/main/examples/PlummerE/runExamplePlummer.jl
2931
```
3032
This script will compute the location of the unstable radial orbit instability mode, using a simplified version of the calculation from [Petersen et al. (2024)](https://ui.adsabs.harvard.edu/abs/2023arXiv231110630P/abstract) (`n1max=1` instead of `n1max=10`, which results in a factor of 10 speedup). The outputs will all be cached (appearing as several files with the `.h5` extension in the folder where the script is run), so re-running the example is inexpensive. This script will take approximately one minute to run.
3133

@@ -48,6 +50,7 @@ In this image and test, we are highlighting two key results:
4850

4951
An extension of this script, where the growth rate is computed for a range of radial anisotropy parameters, is Figure 1 in [Petersen et al. (2024)](https://ui.adsabs.harvard.edu/abs/2023arXiv231110630P/abstract).
5052

53+
---
5154
### Other examples
5255

5356
The `examples` directory also includes several other basic calculations for the Isochrone, Plummer, and Zang disc models. For example, to (very nearly) reproduce the Isochrone damped dipole mode calculation from Fouvry & Prunet (2022), see the example driver script in `examples/IsochroneE/runlinearresponseIsochroneISO.jl`. Note that this mode is not converged: adjusting parameters (in particular `n1max`) will result in different pole locations. The example `examples/IsochroneA/runlinearresponseIsochroneISO.jl` is precisely the calculation performed by [Fouvry & Prunet (2022)](https://ui.adsabs.harvard.edu/abs/2022MNRAS.509.2443F/abstract) -- that is, with the analytic isochrone relations. This example will take substantially more computational effort, and can take up to twenty minutes to complete.
@@ -60,15 +63,31 @@ If you prefer interactive Jupyter notebooks, you will need to install `IJulia` f
6063
The interactive introduction example is then given in `examples/PlummerE/runExamplePlummer.ipynb`.
6164

6265

66+
---
67+
## Uninstall
68+
69+
70+
First start by removing the packages from the environment by running
71+
```
72+
julia -e 'using Pkg; Pkg.rm("OrbitalElements"); Pkg.rm("AstroBasis");Pkg.rm("FiniteHilbertTransform");Pkg.rm("LinearResponse");'
73+
```
6374

75+
If you worked in a test environment (that you do not want to keep) you can also simply erase the folder using `rm -r /path/to/my_env`.
76+
77+
Then to fully erase the package (installed in ~/.julia), run
78+
```
79+
julia -e 'using Pkg; using Dates; Pkg.gc(collect_delay=Day(0));'
80+
```
81+
82+
It will erase all the packages which are not known in any of your "active" (i.e., for which the Manifest.toml file is reachable) project/environments, in particular `LinearResponse`.
6483

6584
---
6685

6786
## Authors
6887

69-
Mathieu Roule - @MathieuRoule - [email protected]
88+
Mike Petersen - [@michael-petersen](https://github.com/michael-petersen) - [email protected]
7089

71-
Mike Petersen - @michael-petersen - [email protected]
90+
Mathieu Roule - [@MathieuRoule](https://github.com/MathieuRoule) - [email protected]
7291

7392
---
7493

@@ -77,9 +96,4 @@ Mike Petersen - @michael-petersen - [email protected]
7796
[^2]: If you are new to `julia`, install by following the instructions at [julialang.org/downloads/](https://julialang.org/downloads/). To invoke Julia in the Terminal, you need to make sure that the `julia` command-line program is in your `PATH`.
7897
See [here](https://julialang.org/downloads/platform/#optional_add_julia_to_path) for detailed instructions.
7998

80-
[^3]: **Note on working with environments.** By default packages are added to the default environment at ~/.julia/environments/v1.#. It is however easy to create other, independent, projects. If you want to install the `LinearResponse` package in a different/test environment, first create a folder to host the environment files (Project.toml and Manifest.toml which will be created later on). Then, for every command line invoking Julia, use `julia --project=/path/to/my_env` instead of `julia` alone. Note that packages will always be cloned in ~/.julia/packages but only accessible in your project's context.
81-
82-
[^4]: You may also uninstall the libraries by removing the packages, by running
83-
```
84-
julia -e 'using Pkg; Pkg.rm("OrbitalElements"); Pkg.rm("AstroBasis");Pkg.rm("FiniteHilbertTransform");Pkg.rm("LinearResponse");'
85-
```
99+
[^3]: **Note on working with environments.** By default packages are added to the default environment at ~/.julia/environments/v1.#. It is however easy to create other, independent, projects. If you want to install the packages in a different/test environment, first create a folder to host the environment files (Project.toml and Manifest.toml which will be created later on). Then, for every command line invoking Julia, use `julia --project=/path/to/my_env` instead of `julia` alone. Note that packages will always be cloned in ~/.julia/packages but only accessible in your project's context.

0 commit comments

Comments
 (0)