From 124cc56443e27e2c251955bf5e246ffd0082fbdd Mon Sep 17 00:00:00 2001 From: John Omotani Date: Fri, 20 Sep 2024 16:36:18 +0100 Subject: [PATCH] Implement show_element_boundaries in plot/animate_f_unnorm_vs_vpa() --- .../makie_post_processing/src/makie_post_processing.jl | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/makie_post_processing/makie_post_processing/src/makie_post_processing.jl b/makie_post_processing/makie_post_processing/src/makie_post_processing.jl index 840875c375..eab805a70c 100644 --- a/makie_post_processing/makie_post_processing/src/makie_post_processing.jl +++ b/makie_post_processing/makie_post_processing/src/makie_post_processing.jl @@ -3942,6 +3942,13 @@ function plot_f_unnorm_vs_vpa(run_info; f_over_vpa2=false, input=nothing, neutra l = plot_1d(dzdt, f_unnorm; ax=ax, label=run_info.run_name, kwargs...) + if input.show_element_boundaries && fig !== nothing + element_boundary_inds = + [i for i ∈ 1:run_info.vpa.ngrid-1:run_info.vpa.n_global] + element_boundary_positions = dzdt[element_boundary_inds] + vlines!(ax, element_boundary_positions, color=:black, alpha=0.3) + end + if outfile !== nothing if fig === nothing error("When ax is passed, fig must also be passed to save the plot using "