Skip to content
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

2D Axisymmetric Issues #801

Open
ChrisZYJ opened this issue Feb 7, 2025 · 1 comment
Open

2D Axisymmetric Issues #801

ChrisZYJ opened this issue Feb 7, 2025 · 1 comment

Comments

@ChrisZYJ
Copy link
Contributor

ChrisZYJ commented Feb 7, 2025

Summary

All the issues are related to 2D axisymmetric HLLC

  • Instability along r=0 / inconsistency in geometric source term αv/r with K*div U activated/deactivated
  • Missing terms in axisymmetric BC
  • Mass not conserved for axisymmetric bubble collapse

Conversation on Slack

Jose Rodolfo Chreim
Hi, @ here. I hope you are doing well. I am wondering if there is anyone working with the implementation of boundary conditions on MFC? Particularly the cylindrical symmetric boundary conditions: it seems that there are some missing terms for this BC to work correctly, but I wanted to double check if I am not missing anything before coming to this conclusion. Here is what I believe to be missing (see image):
"The cylindrical coordinate treatment also requires velocity gradients, rather than just velocities, at cell boundaries. For this, we use a second-order-accurate finite-difference and averaging procedure to obtain the necessary velocity gradients at these points."
Thank you!

Image

Spencer
this is the MFC ‘main paper’ in CPC from 2021 right? this looks like my writing. if so, the discussion of the implementation you read here is almost certainly lifted from Jomela’s dissertation + papers. it’s possible that something is missing in the code, though you’d have to convince me that this is so. for example, there is flux_src_g (or whatever) in the riemann solvers and RHS code that is meant to handle cylindrical coordinates

Jose Rodolfo Chreim
Correct about the paper. Part of the fluxes were missing and I added them back, but something else seems missing to enforce proper BCs.
I will investigate further

Mauro Rodriguez
@ Sawyer Remillard Has also been observing boundary condition issues with the cylindrical symmetric boundary conditions.

Spencer
it is certainly possible there is a problem. It’s actually unclear to me what cylindrical symmetric means in this context
what are you assuming to be symmetric, and how is it a boundary condition? i assume it’s a BC at the r=0 axis in 3D coordinates, what else?

Mauro Rodriguez
@ Sawyer Remillard provide the details

Sawyer Remillard
@ Spencer I have been trying to run some simple, 2D cylindrical, axissymmetric bubble collapse simulations. I noticed that when I use the 5 equation model with the k div u, there seems so be some instability that forms along the r=0 boundary. However, this did not appear when I turned off the k div u terms.

Spencer
interesting, i’m not sure we’ve ever tried this before
do you have a hypothesis as to why?

Jose Rodolfo Chreim
The reason for this instability is not the BCs per se, but rather the presence of geometric source terms.

  • When you deactivate K * div U, m_rhs is (mistakenly) disregarding the sources.
    • they SHOULD be present in either models
  • If you put them in either models, they will both fail
    • You can simply do the test and remove those terms, and your simulation should work. The other ways around is also true
  • @ Chris Zhang tracked this too
  • I observed an indecent amount of total mass being generated for the bubble collapse when they should be numerically conserved.
    • This does not happen for the Cartesian grid case
      • I understand conservation should be more difficult to be numerically enforced in the cylindrical case, but I have the gut feeling that this might be the reason

Don't bother about the variable names, they refer to total mass. There is relatively A LOT of mass being produced for the cylindrical/axisymmetric spherical cases

Image

With regards to stability: if you are talking about observing what I show in the next figures, I also understand that there is a consequence of choosing the domain of the simulation, which impacts the results. I believe the issue shown on this figure will never be addressed with the current configuration, because we are using elements that are not aligned with the curvature; no matter how fine your grid is, you will always suffer from poor discretization due to the geometry of the bubble. They might happen more intensely at the bottom as a consequence of the improper BC at r = 0, but they happen at the top of the bubble too (consequence of the discretization, majorly)

Image

Image

Chris Zhang
Yes, I discussed the missing geometric source terms in axisymmetric HLLC with Jose. Initially, I was confused why applying HLLC's axisymmetric radial treatment to HLL didn't resolve the issue (PR #794 remains incorrect for multi-component). The HLL is now fixed properly, and I'll submit a PR soon. The added terms are exactly what HLLC don't have.

#800 changes a single line for HLL. Axisymmetric HLL is now fixed, but the line now differs from HLLC.

Spencer
@ Chris Zhang thanks so much! and @ Sawyer Remillard @ Jose Rodolfo Chreim thanks for detailing the issue here.
@ Chris Zhang if you want to open a github issue discussing the issue (even copy/pasting text from this thread) that could be handy so we have a track record of what was wrong and what the PR fixed. but if you plan on fixing it soon and putting all the details in the PR description, then that’s cool with me as well.

Chris Zhang
@ Spencer There are many issues discussed by Jose - I'll migrate the conversation to a GitHub issue. I've been working with axisymmetric hypoelasticity, so I tracked down the HLL issue. What remains are (@ Jose Rodolfo Chreim please correct me if I'm wrong):

  • Missing αv/r term in axisymmetric HLLC
  • Missing terms in axisymmetric BC
  • Mass not conserved for axisymmetric bubble collapse
    Any insights would be really appreciated! Problems 2 & 3 are more related to Jose's work, so he knows them much better.

Spencer
agreed! the k \div u term was only implemented some years ago, and likely without cylindrical coordinates in mind. this was before we had checkers in place in any serious manner. if we need other additions (or features are broken), then we should add them to the checker until they are fixed

@sbryngelson
Copy link
Member

This is perfect, thanks for creating the issue @ChrisZYJ. If you fix issues associated with this PR, you can link to this PR or even create sub-issues that you resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants