Skip to content

Commit

Permalink
Fix small amount of Float64 computation
Browse files Browse the repository at this point in the history
  • Loading branch information
huiyuxie authored Oct 14, 2024
1 parent 44ad3b1 commit a05a68d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 12 deletions.
11 changes: 5 additions & 6 deletions src/equations/compressible_euler_multicomponent_1d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -204,13 +204,12 @@ function initial_condition_weak_blast_wave(x, t,

prim_rho = SVector{ncomponents(equations), real(equations)}(r > 0.5f0 ?
2^(i - 1) * (1 - 2) /
(RealT(1) -
2^ncomponents(equations)) :
2^(i - 1) * (1 - 2) *
RealT(1.1691) /
(1 -
2^ncomponents(equations)) *
one(RealT) :
2^(i - 1) * (1 - 2) /
(1 -
2^ncomponents(equations)) *
convert(RealT, 1.1691)
2^ncomponents(equations))
for i in eachcomponent(equations))

v1 = r > 0.5f0 ? zero(RealT) : convert(RealT, 0.1882) * cos_phi
Expand Down
11 changes: 5 additions & 6 deletions src/equations/compressible_euler_multicomponent_2d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -222,13 +222,12 @@ function initial_condition_weak_blast_wave(x, t,

prim_rho = SVector{ncomponents(equations), real(equations)}(r > 0.5f0 ?
2^(i - 1) * (1 - 2) /
(RealT(1) -
2^ncomponents(equations)) :
2^(i - 1) * (1 - 2) *
RealT(1.1691) /
(1 -
2^ncomponents(equations)) *
one(RealT) :
2^(i - 1) * (1 - 2) /
(1 -
2^ncomponents(equations)) *
convert(RealT, 1.1691)
2^ncomponents(equations))
for i in eachcomponent(equations))

v1 = r > 0.5f0 ? zero(RealT) : convert(RealT, 0.1882) * cos_phi
Expand Down

0 comments on commit a05a68d

Please sign in to comment.