-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Move some initial conditions (mostly 1D) #847
Conversation
Codecov Report
@@ Coverage Diff @@
## main #847 +/- ##
==========================================
- Coverage 92.96% 92.96% -0.00%
==========================================
Files 190 211 +21
Lines 17815 17880 +65
==========================================
+ Hits 16561 16621 +60
- Misses 1254 1259 +5
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall LGTM. Out of curiosity, how did you choose which ICs to keep as exported?
examples/tree_1d_dgsem/elixir_eulermulti_two_interacting_blast_waves.jl
Outdated
Show resolved
Hide resolved
rho = x[1] <= x_0 ? 3.5 : 1.0 + 0.2 * sin(5.0 * x[1]) | ||
v1 = x[1] <= x_0 ? 5.8846 : 0.0 | ||
v2 = x[1] <= x_0 ? 1.1198 : 0.0 | ||
v3 = 0.0 | ||
p = x[1] <= x_0 ? 42.0267 : 1.0 | ||
B1 = 1.0 | ||
B2 = x[1] <= x_0 ? 3.6359 : 1.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same question on <=
vs <
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andrewwinters5000? You added this in 53fd46a
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the setup that Dominik and I used back in the day for the FLASH code. He found it in this PhD thesis https://uwspace.uwaterloo.ca/handle/10012/8597
rho = x[1] <= 0.5 ? 1.08 : 1.0 | ||
v1 = x[1] <= 0.5 ? 1.2 : 0.0 | ||
v2 = x[1] <= 0.5 ? 0.01 : 0.0 | ||
v3 = x[1] <= 0.5 ? 0.5 : 0.0 | ||
p = x[1] <= 0.5 ? 0.95 : 1.0 | ||
inv_sqrt4pi = 1.0 / sqrt(4 * pi) | ||
B1 = 2 * inv_sqrt4pi | ||
B2 = x[1] <= 0.5 ? 3.6 * inv_sqrt4pi : 4.0 * inv_sqrt4pi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just out of curiosity, why <=
and not <
here? The Brio-Wu shock tube also uses <
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andrewwinters5000? You added this in 53fd46a
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Ryu & Jones reference is slightly ambiguous in that they just define a left and right state but don't actually state things in terms of <
versus <=
so I just made a decision. The same is true for the Torrilhon shocktube test. For Brio & Wu I followed how FLASH does it and they use the <
rho = x[1] <= x_0 ? 1.0 + 0.2 * sin(5.0 * x[1]) : 3.5 | ||
v1 = x[1] <= x_0 ? 0.0 : -5.8846 | ||
v2 = x[1] <= x_0 ? 0.0 : -1.1198 | ||
v3 = 0.0 | ||
p = x[1] <= x_0 ? 1.0 : 42.0267 | ||
B1 = 1.0 | ||
B2 = x[1] <= x_0 ? 1.0 : 3.6359 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same question on <= vs <
rho = x[1] <= 0 ? 3.0 : 1.0 | ||
v1 = 0.0 | ||
v2 = 0.0 | ||
v3 = 0.0 | ||
p = x[1] <= 0 ? 3.0 : 1.0 | ||
B1 = 1.5 | ||
B2 = x[1] <= 0 ? 1.0 : cos(1.5) | ||
B3 = x[1] <= 0 ? 0.0 : sin(1.5) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same question on <= vs <
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andrewwinters5000? You added this in 518899d
prim_rho = SVector{ncomponents(equations), real(equations)}(2^(i-1) * (1-2)/(1-2^ncomponents(equations)) * rho for i in eachcomponent(equations)) | ||
else | ||
rho = 0.125 | ||
prim_rho = SVector{ncomponents(equations), real(equations)}(2^(i-1) * (1-2)/(1-2^ncomponents(equations)) * rho for i in eachcomponent(equations)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why (1-2)
and not just -1
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No deeper meaning, -1 can also be used
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't do a full review but left a few comments. Overall, I'm ok with this PR, I just would like to have at least one "canonical" setup in the Trixi that is entropy-producing (but I think the medium Sedov blast accounts for that).
Doesn't any discontinuous IC also produce entropy? I seem to remember the weak blast wave being used as an entropy conservation test. |
Yes, but the weak blast wave is so weak that it is not a very hard test case for EC/ES schemes. You can run it with an EC flux and it remains stable IIRC |
Co-authored-by: Jesse Chan <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
with the remaining comments resolved, this LGTM
Co-authored-by: Michael Schlottke-Lakemper <[email protected]>
I would like to keep the questions on specific implementations of some ICs open (since this PR didn't change them at all, just moved them somewhere else). This allows us to merge this one soon and move on while we can keep discussing the open questions here and make new PRs if appropriate. |
I concentrated on 1D here. Thus, I touched only the 2D/3D parts that were necessary after doing the 1D changes. My rules were
I tried to follow #685 (comment) and #237 (comment) |
Sounds good. Since my comments were mostly on old commits we can ignore those for this PR. LGTM - feel free to merge when ready. |
Contributes to #685