-
Notifications
You must be signed in to change notification settings - Fork 126
Unity Lewis Implementation #1084
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
Open
DimAdam-01
wants to merge
15
commits into
MFlowCode:master
Choose a base branch
from
DimAdam-01:Unity_Lewis_V2
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
c142fe3
Redo the branch
d18106b
Forgotten stuff
4e5a63f
aaaaaa
3ac5690
Wrong Syntax
7f5bac8
Format
a001291
Format/Lint
58910dc
Lint v2
1da8408
Small Change
259f2a5
Merge branch 'master' into Unity_Lewis_V2
sbryngelson 05fd51f
Merge branch 'master' into Unity_Lewis_V2
sbryngelson 72233e0
Doxygen
cb259ec
Documentation + Example with Diffusion
476967a
Spellig error
15f1260
AI suggestions
0e8124f
Update examples/1D_multispecies_diffusion/case.py
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
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
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
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 |
|---|---|---|
| @@ -0,0 +1,78 @@ | ||
| #!/usr/bin/env python3 | ||
| # References: | ||
| # + https://doi.org/10.1016/j.compfluid.2013.10.014: 4.4. Multicomponent diffusion test case | ||
|
|
||
| import json | ||
| import argparse | ||
| import math | ||
| import cantera as ct | ||
|
|
||
| ctfile = "gri30.yaml" | ||
| sol_L = ct.Solution(ctfile) | ||
| sol_L.TPX = 300, 8000, "O2:2,N2:2,H2O:5" | ||
|
|
||
| L = 0.05 | ||
| Nx = 100 | ||
| dx = L / Nx | ||
| dt = 0.3e-6 | ||
| Tend = 0.05 | ||
|
|
||
| NT = int(Tend / dt) | ||
| SAVE_COUNT = 2000 | ||
| NS = 2000 | ||
| case = { | ||
| "run_time_info": "T", | ||
| "x_domain%beg": 0, | ||
| "x_domain%end": +L, | ||
| "m": Nx, | ||
| "n": 0, | ||
| "p": 0, | ||
| "dt": float(dt), | ||
| "t_step_start": 0, | ||
| "t_step_stop": NT, | ||
| "t_step_save": NS, | ||
| "t_step_print": NS, | ||
| "parallel_io": "F", | ||
| "model_eqns": 2, | ||
| "num_fluids": 1, | ||
| "num_patches": 1, | ||
| "mpp_lim": "F", | ||
| "mixture_err": "F", | ||
| "time_stepper": 3, | ||
| "weno_order": 5, | ||
| "weno_eps": 1e-16, | ||
| "weno_avg": "F", | ||
| "mapped_weno": "T", | ||
| "mp_weno": "T", | ||
| "riemann_solver": 2, | ||
| "wave_speeds": 2, | ||
| "avg_state": 1, | ||
| "bc_x%beg": -1, | ||
| "bc_x%end": -1, | ||
| "viscous": "F", | ||
| "chemistry": "T", | ||
| "chem_params%diffusion": "T", | ||
| "chem_params%reactions": "F", | ||
| "chem_params%transport_model": 2, # Unity-Lewis | ||
| "format": 1, | ||
| "precision": 2, | ||
| "prim_vars_wrt": "T", | ||
| "chem_wrt_T": "T", | ||
| "patch_icpp(1)%geometry": 1, | ||
| "patch_icpp(1)%hcid": 182, | ||
| "patch_icpp(1)%x_centroid": L / 2, | ||
| "patch_icpp(1)%length_x": L, | ||
| "patch_icpp(1)%vel(1)": "0", | ||
| "patch_icpp(1)%pres": 1.01325e5, | ||
| "patch_icpp(1)%alpha(1)": 1, | ||
| "patch_icpp(1)%alpha_rho(1)": 1, | ||
| "fluid_pp(1)%gamma": 1.0e00 / (1.9326e00 - 1.0e00), | ||
| "fluid_pp(1)%pi_inf": 0, | ||
| "cantera_file": ctfile, | ||
| } | ||
|
|
||
| for i in range(len(sol_L.Y)): | ||
| case[f"chem_wrt_Y({i + 1})"] = "T" | ||
| case[f"patch_icpp(1)%Y({i+1})"] = 0.0 | ||
| if __name__ == "__main__": | ||
| print(json.dumps(case)) |
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
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
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
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
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
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.
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.