Skip to content

Commit

Permalink
Fix simple demo
Browse files Browse the repository at this point in the history
  • Loading branch information
eldond committed Feb 20, 2024
1 parent b4c4ffa commit 09933c3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions example/simple_demo.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,16 @@ sample_path = "$(@__DIR__)/../sample/ITER_Lore_2296_00000/"
solps2imas_samples = splitdir(pathof(SOLPS2IMAS))[1] * "/../samples"

dd = SD4SOLPS.preparation(
"Baseline2008-li0.70.x4.mod3.eqdsk",
"Baseline2008-li0.70.x4.mod2.eqdsk",
[sample_path, solps2imas_samples]...;
)

grid_ggd = ids.edge_profiles.grid_ggd[1] # First grid_ggd time slice. It is allowed to vary in time
grid_ggd = dd.edge_profiles.grid_ggd[1] # First grid_ggd time slice. It is allowed to vary in time
space = grid_ggd.space[1] # First space in this grid_ggd

# Choose backend
gr() # Fast and can save pdf
# plotlyjs() # Use for interactive plot, can only save png
n_e = GGDUtils.get_prop_with_grid_subset_index(ids.edge_profiles.ggd[1].electrons.density, 5)
plot(ids.edge_profiles.grid_ggd, n_e, colorbar_title="Electrons density / m^(-3)")
n_e = GGDUtils.get_prop_with_grid_subset_index(dd.edge_profiles.ggd[1].electrons.density, 5)
plot(dd.edge_profiles.grid_ggd, n_e, colorbar_title="Electrons density / m^(-3)")
plot!(space, GGDUtils.get_grid_subset_with_index(grid_ggd, 16), linecolor=:black, linewidth=2, linestyle=:solid, label="Separatix", legend=true)

0 comments on commit 09933c3

Please sign in to comment.