-
Notifications
You must be signed in to change notification settings - Fork 121
Lodi multi component #838
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
Merged
sbryngelson
merged 15 commits into
MFlowCode:master
from
DimAdam-01:Lodi_MultiComponent
May 22, 2025
Merged
Lodi multi component #838
Changes from 12 commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
bcaaa35
Chemistry Bug Fixes
DimAdam-01 4833d7b
Chemistry Bug Fixes
DimAdam-01 c8e7f9f
Format
DimAdam-01 652d0fa
Testing-Changes-In-CodeGenerator-For-Pyrometheus
DimAdam-01 e63683a
Merge branch 'MFlowCode:master' into my_new_branch
DimAdam-01 cc20ee9
Extend Frontier Run Time
DimAdam-01 b720ecc
Debugggg
DimAdam-01 1182c2c
Small Changes
DimAdam-01 24a324c
Lodi for Multicomponent
DimAdam-01 b02547e
Merge
DimAdam-01 308d919
Merge_2
DimAdam-01 043b8a7
Upstream
DimAdam-01 f847598
Merge branch 'master' into Lodi_MultiComponent
DimAdam-01 a5a0198
Images
DimAdam-01 55c9549
Merge remote-tracking branch 'origin/Lodi_MultiComponent' into Lodi_M…
DimAdam-01 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Binary file not shown.
wilfonba marked this conversation as resolved.
Show resolved
Hide resolved
|
Binary file not shown.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1467,6 +1467,8 @@ contains | |
| real(wp) :: qv_K | ||
| real(wp), dimension(2) :: Re_K | ||
| real(wp) :: G_K | ||
| real(wp), dimension(num_species) :: Y_K | ||
| real(wp) :: T_K, mix_mol_weight, R_gas | ||
|
|
||
| integer :: i, j, k, l !< Generic loop iterators | ||
|
|
||
|
|
@@ -1479,7 +1481,7 @@ contains | |
| ! Computing the flux variables from the primitive variables, without | ||
| ! accounting for the contribution of either viscosity or capillarity | ||
| #ifdef MFC_SIMULATION | ||
| !$acc parallel loop collapse(3) gang vector default(present) private(alpha_rho_K, vel_K, alpha_K, Re_K) | ||
| !$acc parallel loop collapse(3) gang vector default(present) private(alpha_rho_K, vel_K, alpha_K, Re_K, Y_K) | ||
| do l = is3b, is3e | ||
| do k = is2b, is2e | ||
| do j = is1b, is1e | ||
|
|
@@ -1518,8 +1520,23 @@ contains | |
| end if | ||
|
|
||
| ! Computing the energy from the pressure | ||
| E_K = gamma_K*pres_K + pi_inf_K & | ||
| + 5e-1_wp*rho_K*vel_K_sum + qv_K | ||
|
|
||
| if (chemistry) then | ||
| !$acc loop seq | ||
| do i = chemxb, chemxe | ||
| Y_K(i - chemxb + 1) = qK_prim_vf(j, k, l, i) | ||
| end do | ||
| !Computing the energy from the internal energy of the mixture | ||
| call get_mixture_molecular_weight(Y_k, mix_mol_weight) | ||
| R_gas = gas_constant/mix_mol_weight | ||
| T_K = pres_K/rho_K/R_gas | ||
| call get_mixture_energy_mass(T_K, Y_K, E_K) | ||
| E_K = rho_K*E_K + 5e-1_wp*rho_K*vel_K_sum | ||
| else | ||
| ! Computing the energy from the pressure | ||
| E_K = gamma_K*pres_K + pi_inf_K & | ||
| + 5e-1_wp*rho_K*vel_K_sum + qv_K | ||
| end if | ||
|
Comment on lines
+1524
to
+1539
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you make sure this doesn't have any performance impact on non-chemistry cases? This variables conversion subroutine can be really touchy on AMD hardware... |
||
|
|
||
| ! mass flux, this should be \alpha_i \rho_i u_i | ||
| !$acc loop seq | ||
|
|
@@ -1538,6 +1555,14 @@ contains | |
| ! energy flux, u(E+p) | ||
| FK_vf(j, k, l, E_idx) = vel_K(dir_idx(1))*(E_K + pres_K) | ||
|
|
||
| ! Species advection Flux, \rho*u*Y | ||
| if (chemistry) then | ||
| !$acc loop seq | ||
| do i = 1, num_species | ||
| FK_vf(j, k, l, i - 1 + chemxb) = vel_K(dir_idx(1))*(rho_K*Y_K(i)) | ||
| end do | ||
| end if | ||
|
|
||
| if (riemann_solver == 1 .or. riemann_solver == 4) then | ||
| !$acc loop seq | ||
| do i = advxb, advxe | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.