Skip to content

Commit 5c9ac55

Browse files
committed
update README
1 parent bcefcf9 commit 5c9ac55

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

README.md

+13-3
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,18 @@ There are two ways of using Luna:
3636
For a short introduction on how to use the simple interface, see the [Quickstart](#quickstart) or [GNLSE](#gnlse) sections below. More information, including on the internals of Luna, can be found in the [Documentation](http://lupo-lab.com/Luna.jl).
3737

3838
## Installation
39-
Luna requires Julia v1.9 or later, which can be obtained from [here](https://julialang.org/downloads/). In a Julia terminal, to install Luna simply enter the package manager with `]` and run `add Luna`:
39+
Luna requires Julia v1.9 or later, which can be obtained from [here](https://julialang.org/downloads/). It is recommended to always use the most recent released Julia version. In a Julia terminal, to install Luna simply enter the package manager with `]` and run `add Luna`:
4040

4141
```julia
4242
]
4343
add Luna
4444
```
45-
This will install and precompile Luna and all its dependencies.
45+
This will install and precompile Luna and all its dependencies. For plotting you also need to install a plotting backend. We recommend `PythonPlot` which can be installed by calling:
46+
47+
```julia
48+
]
49+
add PythonPlot, PythonCall
50+
```
4651

4752
## Quickstart
4853
To run a simple simulation of ultrafast pulse propagation in a gas-filled hollow capillary fibre, you can use `prop_capillary`. As an example, take a 3-metre length of HCF with 125 μm core radius, filled with 1 bar of helium gas, and driving pulses centred at 800 nm wavelength with 120 μJ of energy and 10 fs duration. We consider a frequency grid which spans from 120 nm to 4 μm and a time window of 1 ps.
@@ -86,8 +91,9 @@ julia> output_multimode["Eω"]
8691
```
8792
**NOTE:** Setting `modes=:HE11` and `modes=1` are **not** equivalent, except if only the Kerr effect is included in the simulation. The former uses mode-averaged propagation (treating all spatial dependence of the nonlinear polarisation the same as the Kerr effect) whereas the latter projects the spatially dependent nonlinear polarisation onto a single mode. This difference is especially important when photoionisation plays a major role.
8893
### Plotting results
89-
More usefully, you can directly plot the propagation results using `Plotting.prop_2D()` (`Plotting` is imported at the same time as `prop_capillary` by the `using Luna` statement):
94+
More usefully, you can directly plot the propagation results using `Plotting.prop_2D()`. While `Plotting` is imported at the same time as `prop_capillary` by the `using Luna` statement, you also need to import a plotting backend, e.g. `PythonPlot`:
9095
```julia
96+
julia> using PythonPlot
9197
julia> Plotting.prop_2D(output)
9298
Python Figure: <Figure size 1200x400 with 4 Axes>
9399
```
@@ -138,6 +144,7 @@ MemoryOutput["simulation_type", "dumps", "meta", "Eω", "prop_capillary_args", "
138144
```
139145
After this has run, you can visualise the output, with e.g.
140146
```julia
147+
julia> using PythonPlot
141148
julia> Plotting.prop_2D(output_gnlse, , dBmin=-40.0, λrange=(400e-9, 1300e-9), trange=(-1e-12, 5e-12))
142149
Python Figure: <Figure size 1200x400 with 4 Axes>
143150
```
@@ -154,6 +161,9 @@ At its core, Luna is extremely flexible, and the simple interface using `prop_ca
154161
## Running parameter scans
155162
Luna comes with a built-in interface which allows for the running of single- and multi-dimensional parameter scans with very little additional code. An example can be found in the [examples folder](examples/simple_interface/scan.jl) and more information is available in the [documentation](http://lupo-lab.com/Luna.jl/dev/scans.html).
156163
164+
## Plotting backends
165+
Luna supports three plotting backends; PythonPlot, PyPlot and GLMakie. For most use cases, you should use PythonPlot. We support PyPlot for backwards compatibility. Currently, support for GLMakie is experimental.
166+
157167
## New to Julia?
158168
There are many resources to help you learn Julia. A good place to start is [Julia Academy](https://juliaacademy.com/) which has several courses for learning Julia depending on your current experience. There are additional resources linked from the [Julia website](https://julialang.org/learning/).
159169

0 commit comments

Comments
 (0)