Dyna Jupyter Notebooks

Notebooks on GitLab

These notebooks provide interactive, GUI-independent examples for users who
prefer to explore Dyna calculations step by step.

Available Notebooks

01_basic_reflectivity.ipynb

Builds the default W/Si sample, runs a Stepanov angle scan, plots the
reflectivity, and saves the calculated observables to CSV.

02_compare_formalisms.ipynb

Runs the Elzo and Stepanov formalisms on the same magnetic sample, plots the
two reflectivity curves, and reports the relative numerical difference.

03_kerr_faraday.ipynb

Evaluates Kerr and Faraday magneto-optical rotations for a published dielectric
tensor benchmark.

04_load_yaml_project.ipynb

Loads a YAML project file, inspects the sample, runs the simulation, and shows
the equivalent headless SimulationConfig workflow.

05_fit_experimental_data.ipynb

Creates a small synthetic dataset, fits one layer thickness without the GUI,
plots model/data/residuals, and writes fit outputs.

Running

From the repository root:

jupyter lab examples/notebooks

or:

jupyter notebook examples/notebooks

The notebooks first try to use the local src/ tree when they are opened from
a Dyna source checkout. If no source checkout is found, they use the installed
DynaRef package.