Skip to content

Commit

Permalink
Fix: Wrong cell separators
Browse files Browse the repository at this point in the history
  • Loading branch information
agdestein committed Dec 1, 2023
1 parent e16b2a5 commit 593f5ca
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions examples/Actuator2D.jl
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ state, outputs = solve_unsteady(
Δt = 0.05,
processors = (
rtp = realtimeplotter(; setup, plot = fieldplot, nupdate = 1),
# ehist = realtimeplotter(; setup, plot = energy_history_plot, nupdate = 1),
# espec = realtimeplotter(; setup, plot = energy_spectrum_plot, nupdate = 1),
## ehist = realtimeplotter(; setup, plot = energy_history_plot, nupdate = 1),
## espec = realtimeplotter(; setup, plot = energy_spectrum_plot, nupdate = 1),
## anim = animator(; setup, path = "$output/vorticity.mkv", nupdate = 20),
## vtk = vtk_writer(; setup, nupdate = 10, dir = "$output", filename = "solution"),
## field = fieldsaver(; setup, nupdate = 10),
Expand Down
16 changes: 8 additions & 8 deletions examples/PlaneJets2D.jl
Original file line number Diff line number Diff line change
Expand Up @@ -115,15 +115,15 @@ function meanplot(state; setup)
K = Nu[1][2] ÷ 2
k = 1:(K-1)

# Find energy spectrum where y = 0
## Find energy spectrum where y = 0
n₀ = findmin(abs, xp[2])[2]
E₀ = lift(state) do (; u, p, t)
u_y = u[1][:, n₀]
abs.(fft(u_y .^ 2))[k.+1]
end
y₀ = xp[2][n₀]

# Find energy spectrum where y = 1
## Find energy spectrum where y = 1
n₁ = findmin(y -> abs(y - 1), xp[2])[2]
E₁ = lift(state) do (; u, p, t)
u_y = u[1][:, n₁]
Expand All @@ -147,14 +147,14 @@ function meanplot(state; setup)
xlabel = L"k_x",
ylabel = L"\hat{U}_{cl} / U_0",
)
# ylims!(ax, (10^(0.0), 10^4.0))
## ylims!(ax, (10^(0.0), 10^4.0))
ksub = k[10:end]
# lines!(ax, ksub, 1000 .* ksub .^ (-5 / 3); label = L"k^{-5/3}")
## lines!(ax, ksub, 1000 .* ksub .^ (-5 / 3); label = L"k^{-5/3}")
lines!(ax, ksub, 1e7 .* ksub .^ -3; label = L"k^{-3}")
scatter!(ax, k, E₀; label = "y = $y₀")
scatter!(ax, k, E₁; label = "y = $y₁")
axislegend(ax; position = :lb)
# on(_ -> autolimits!(ax), E₁)
## on(_ -> autolimits!(ax), E₁)

fig
end
Expand All @@ -171,9 +171,9 @@ state, outputs = solve_unsteady(
processors = (
rtp = realtimeplotter(;
setup,
# plot = fieldplot,
# plot = energy_history_plot,
# plot = energy_spectrum_plot,
## plot = fieldplot,
## plot = energy_history_plot,
## plot = energy_spectrum_plot,
plot = meanplot,
nupdate = 1,
),
Expand Down

0 comments on commit 593f5ca

Please sign in to comment.