Skip to content

Commit

Permalink
Updated dynamo elixir example to make it deterministic by using deter…
Browse files Browse the repository at this point in the history
…ministic seeds

for our random numbers.
  • Loading branch information
SimonCan committed Jul 12, 2023
1 parent 6385f06 commit 4c10b8b
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions examples/tree_3d_dgsem/elixir_mhd_dynamo.jl
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ Define the initial condition with a weak small-scale Gaussian noise magnetic fie
function initial_condition_gaussian_noise_mhd(x, t, equations)
amplitude = 1e-8

seed = reinterpret(UInt64, t + x[1] + x[2] + x[3])
Random.seed!(seed)

rho = 1.0
rho_v1 = 0.0
rho_v2 = 0.0
Expand Down

0 comments on commit 4c10b8b

Please sign in to comment.