Skip to content

Multiphase over integration#2217

Merged
gloopydoop merged 12 commits intotuan/case/lid-multiphasefrom
multiphase_over_integration
Apr 24, 2026
Merged

Multiphase over integration#2217
gloopydoop merged 12 commits intotuan/case/lid-multiphasefrom
multiphase_over_integration

Conversation

@gloopydoop
Copy link
Copy Markdown
Collaborator

Finally a commit to multiphase!
In this PR I add a way of performing over integration (dealiasing) on the term

$\nabla \cdot \left( \phi (1-\phi) \frac{\nabla \phi}{|\nabla \phi|}\right)$

If one considers the test function too, this is 4 polynomials multiplied together, so it's not a 3/2 rules, it's a 4/2=2 rule.

You should be able to enable it with "dealias_normal": true under scalar.

There's also a little profiler wrapping each computations, I'm seeing (from small tests)


                        Total time        Avg. time       Range  +/-
 --------------------------------------------------------------------
 n_dealias            0.9233649E+02    0.7694707E-02    0.1670377E-01
 n_no_dealias         0.3231977E+01    0.2693314E-03    0.2046465E-04

"numerics": {
"time_order": 3,
"polynomial_order": 7,
"dealias": true
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

perhaps it makes more sense to place it here in the JSON

@gloopydoop gloopydoop requested a review from tuananhdao December 3, 2025 15:45
@Shiyu-Sandy-Du
Copy link
Copy Markdown
Collaborator

why is it slower by 30 times? I would probably expect it's 10 times when assenble the total forcing term, and approximately the same time for the pressure and velocity equation (so in total much smaller than 30 times).

@pschlatt1
Copy link
Copy Markdown
Collaborator

I am wondering in this regard whether implementing some type of 2/3 rule instead could be beneficial, so that one does not need to dealias many individual terms...? Or is there a drawback on doing that?

@timofeymukha
Copy link
Copy Markdown
Collaborator

Can we merge this in, so it doesn't hang around in the PR list :)?

@njansson
Copy link
Copy Markdown
Collaborator

Can we merge this in, so it doesn't hang around in the PR list :)?

Sounds like a good plan

@njansson
Copy link
Copy Markdown
Collaborator

Can we merge this in, so it doesn't hang around in the PR list :)?

Bump this thread, should we get it in?

@timofeymukha
Copy link
Copy Markdown
Collaborator

@gloopydoop merges tomorrow.

@gloopydoop gloopydoop merged commit 25f2dbe into tuan/case/lid-multiphase Apr 24, 2026
@gloopydoop gloopydoop deleted the multiphase_over_integration branch April 24, 2026 10:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants