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

Feature balance #9

Merged
merged 9 commits into from
Sep 15, 2021
Merged

Feature balance #9

merged 9 commits into from
Sep 15, 2021

Conversation

esclapez
Copy link
Collaborator

Add some balance capabilities. At this point it simply allows to check that d \int_V(m)dt = ∑mass_fluxes.
To check your simulation, simply type gnuplot $(PELELMEX_HOME)/Utils/Plots/massplot.gnu and it'll show the following:
Screen Shot 2021-09-15 at 3 08 18 PM

@esclapez esclapez merged commit 571d5fc into development Sep 15, 2021
@esclapez esclapez deleted the feature_balance branch September 21, 2021 00:55
esclapez added a commit that referenced this pull request Oct 1, 2021
* Move the CoveredMask reset flag out of the if statement.

* Add user-defined chemistry tolerances.

* Add a Triple flame in Exec/Cases/TripleFlame

* While making new level from coarse, get 1 ghost cell right so that
AmrNewTime data have one ghost cell properly set.

* Add a simple 2D CH4/Air premixed bunsen case. Tested up to 5 levels.

* Add a 3Dversion of the premixed bunsen flame.

* Need to reset the covered cell mask after restart in case regrid is not called right after.

* Add option to restart an efield simulation from a non-efield one.

* When restarting from non-efield chk, initialize electro-neutral nE
field.

* Fix PlotFile to plot I_R(nE) with efield and write/read in phiV/nE in
chk.

* Machinery to restart from non-efield chk.

* Update Precond operator to implement the second approximation of Stilda.

* Make use of the absolute tolerance in MLGMRES.

* Add fillpatch functions for the non-linear state components.

* Enable Schur complement approximation 2.

* Define and ParmParse m_ef_schur_approx.

* Floor nE along with species if required.

* Fix typos in PeleLMBC.cpp

* Update PeleLMeX header for new fillpatch functions.

* Replace mechanism.h by mechanism.H

* Setup gravity.

* Use gravity in velocity forces.

* Replace .copy by .ParallelCopy.

* Add a lifting hot bubble case in RegTests.

* Default the pprocConvOrder.py to CoVo inputs.

* Enable CoVo in all directions.

* Default input.2d_CoVo to diagonal direction.

* Update pprocConvOrder.py with version checking the convergence order.

* Init convergence testing CI.

* Fix convergence CI (#6)

* Fix deps in convergence CI.

* Update pprocConvOrder.py.

* Fix Pele Physics (#7)

* Update make system to catch up with PP.

* Update sources for latest PP.

* Fix parsing of constant transport parameters.

* Switch AMReX-Hydro (#8)

* Add AMReX-Hydro to deps and GMake.

* Remove LMX Godunov folder from listed sources.

* Fix AMReX-Hydro makefile again and need MOL.

* Swtich to HydroUtils to predict velocity and use
create_umac_grown_constrained.

* Remove stranded Godunov include.

* Add m_advection_type. Only Godunov in LMeX.

* Switch to HydroUtils::ComputeFluxesOnBoxFromState for advection fluxes.

* Remove Godunov from LMeX sources.

* Rewritte the advective flux divergence to comply with AMReX-Hydro way.

* Update CI.

* Feature balance (#9)

* Add kin. energy derive function.

* Add kin.energy derive and ParmParse temporals input.

* Start setting-up run-time diagnostics.

* Update MLNorm0 to not account for fine-covered cells.

* Setup mass balance in runtime diagnostics.

* Add temporal keys to FlameSheet regtests

* Git ignore

* Add gnuplot script for mass balance.

* Fix runtime selection of reactor. (#10)

* Missing AMReX-Hydro home in convergence testing.

* Update Make.PeleLMeX

* Update reactor in Sources.

* Remove one call too many to deallocate of transport.

* Update FlameSheet GMake

* Add CVODE input keys.

* Udpate GMake in Periodic and HotBubble

* Fix typo on ReactorNull default:

* Make LMeX GPU-compatible (#11)

* Remove device from lineaChmeForcing.

* Can't init capture in host_device functions.

* Fix call to host function on device lambdas.

* Change OMP.

* Should be the same, but make sure.

* Don't init transport for incompressible flows.

* Missing Gpu Managed. Will be updated later.

* Minor clean up in PeriodicCases.

* Fix parm in FLameSheet too.

* Restore FlameSheet 3D.

* Remove unused.

* Add Sundials memory helper.

* Remove auto-TPL. Recompile all the source each time. Need fix.

* Restore make TPL in GH workflow for now.

* Fix velocity ghost cells for Nodal projection. Function (#12)

should only overwrite Inflow BCs.

* Implement closed chamber algorithm. (#13)

* Add auto-detection of closed chamber and unable overwrite.
Add PPquery of linear solves tolerances.

* Add GammmaInv kernel.

* Move MFSum in Utils and initialize uncovered volume computation.

* MAC projection function handles closed chamber corrections.

* Nodal projection functions handle -/+ of Sbar in RHS.

* Remove TODO comment.

* Pass dp0dt in diffusion forcing.

* Pass dp0dt in Advection forcing.

* Add pOld <-> pNew in advance function.

* Add adjustPandDivU in Eos file.

* Add accessor to divU levels vector

* Add declarations.

* Add ambient pressure to checkpoint file header.

* Uses pNew to get dPdt.

* Fix BL_PROF in UMAC

* Add an enclosed flame test to test closed chamber.

* Add a CI testing closed chamber.
esclapez added a commit that referenced this pull request Nov 4, 2021
* Move the CoveredMask reset flag out of the if statement.

* Add user-defined chemistry tolerances.

* Add a Triple flame in Exec/Cases/TripleFlame

* While making new level from coarse, get 1 ghost cell right so that
AmrNewTime data have one ghost cell properly set.

* Add a simple 2D CH4/Air premixed bunsen case. Tested up to 5 levels.

* Add a 3Dversion of the premixed bunsen flame.

* Need to reset the covered cell mask after restart in case regrid is not called right after.

* Add option to restart an efield simulation from a non-efield one.

* When restarting from non-efield chk, initialize electro-neutral nE
field.

* Fix PlotFile to plot I_R(nE) with efield and write/read in phiV/nE in
chk.

* Machinery to restart from non-efield chk.

* Update Precond operator to implement the second approximation of Stilda.

* Make use of the absolute tolerance in MLGMRES.

* Add fillpatch functions for the non-linear state components.

* Enable Schur complement approximation 2.

* Define and ParmParse m_ef_schur_approx.

* Floor nE along with species if required.

* Fix typos in PeleLMBC.cpp

* Update PeleLMeX header for new fillpatch functions.

* Replace mechanism.h by mechanism.H

* Setup gravity.

* Use gravity in velocity forces.

* Replace .copy by .ParallelCopy.

* Add a lifting hot bubble case in RegTests.

* Default the pprocConvOrder.py to CoVo inputs.

* Enable CoVo in all directions.

* Default input.2d_CoVo to diagonal direction.

* Update pprocConvOrder.py with version checking the convergence order.

* Init convergence testing CI.

* Fix convergence CI (#6)

* Fix deps in convergence CI.

* Update pprocConvOrder.py.

* Fix Pele Physics (#7)

* Update make system to catch up with PP.

* Update sources for latest PP.

* Fix parsing of constant transport parameters.

* Switch AMReX-Hydro (#8)

* Add AMReX-Hydro to deps and GMake.

* Remove LMX Godunov folder from listed sources.

* Fix AMReX-Hydro makefile again and need MOL.

* Swtich to HydroUtils to predict velocity and use
create_umac_grown_constrained.

* Remove stranded Godunov include.

* Add m_advection_type. Only Godunov in LMeX.

* Switch to HydroUtils::ComputeFluxesOnBoxFromState for advection fluxes.

* Remove Godunov from LMeX sources.

* Rewritte the advective flux divergence to comply with AMReX-Hydro way.

* Update CI.

* Feature balance (#9)

* Add kin. energy derive function.

* Add kin.energy derive and ParmParse temporals input.

* Start setting-up run-time diagnostics.

* Update MLNorm0 to not account for fine-covered cells.

* Setup mass balance in runtime diagnostics.

* Add temporal keys to FlameSheet regtests

* Git ignore

* Add gnuplot script for mass balance.

* Fix runtime selection of reactor. (#10)

* Missing AMReX-Hydro home in convergence testing.

* Update Make.PeleLMeX

* Update reactor in Sources.

* Remove one call too many to deallocate of transport.

* Update FlameSheet GMake

* Add CVODE input keys.

* Udpate GMake in Periodic and HotBubble

* Fix typo on ReactorNull default:

* Make LMeX GPU-compatible (#11)

* Remove device from lineaChmeForcing.

* Can't init capture in host_device functions.

* Fix call to host function on device lambdas.

* Change OMP.

* Should be the same, but make sure.

* Don't init transport for incompressible flows.

* Missing Gpu Managed. Will be updated later.

* Minor clean up in PeriodicCases.

* Fix parm in FLameSheet too.

* Restore FlameSheet 3D.

* Remove unused.

* Add Sundials memory helper.

* Remove auto-TPL. Recompile all the source each time. Need fix.

* Restore make TPL in GH workflow for now.

* Fix velocity ghost cells for Nodal projection. Function (#12)

should only overwrite Inflow BCs.

* Implement closed chamber algorithm. (#13)

* Add auto-detection of closed chamber and unable overwrite.
Add PPquery of linear solves tolerances.

* Add GammmaInv kernel.

* Move MFSum in Utils and initialize uncovered volume computation.

* MAC projection function handles closed chamber corrections.

* Nodal projection functions handle -/+ of Sbar in RHS.

* Remove TODO comment.

* Pass dp0dt in diffusion forcing.

* Pass dp0dt in Advection forcing.

* Add pOld <-> pNew in advance function.

* Add adjustPandDivU in Eos file.

* Add accessor to divU levels vector

* Add declarations.

* Add ambient pressure to checkpoint file header.

* Uses pNew to get dPdt.

* Fix BL_PROF in UMAC

* Add an enclosed flame test to test closed chamber.

* Add a CI testing closed chamber.

* Enable EB in LMeX (#16)

* Add missing EB sources to Make.

* Add volFrac to plotfile.

* Add PeleLM EB source file.

* Add a static_cast accessor to ebfactory.

* Update AMReX-Hydro calls to pass ebfactory in.

* Missing include for volfrac tagging.

* Update diffusion operator for EB.

* EB compiles and initialize properly.

* Make sure divTau has right Factory.

* Fix getDiffusivity to not set covered face to 0,0 but huge val.

* _OPENMP -> AMREX_USE_OMP

* Remove plot/abort after init.

* First pass at updating DiffusionOp for EB. Mostly done.

* Fix divergence of advective flux function for EB.

* Minor tweak in PeleLMDiffusion. FluxRedist still need to be implemented.

* Re-organive advection to get divergnce and then redistribute when EB.
fillBoundary in between req. a temporary.

* redistribute_AofS function.

* Add redist schemes for adv/diff, ensure enough ghost cells and declarations.

* Add ParmParse to control nodal solve MG depth.

* Enforce EB-covered to 0 for nodal projection.

* Add fluxdivegenceRD to handle diffusive flux redistribution. Fix MFSum
to exclude EB-covered regions.

* Diffusive flux redistribution function.

* Tedious switch between div/divRD for diffusiob fluxes. Might want to simplify later.

* Accessor to RhoH tower.

* Declarations.

* Add 3D case for EnclosedFlame and a thermo-diffusive CH4/H2 PMF.

* Number of ghost cells in EBFactory should be 6 because of StateRedist

* EBFlag test inst. reaction rate.

* Set covered to 0.0 in plotfiles.

* EBFlag in getHGivenT in enthalpy flux.

* Do initial redisitribution and get a covered state.

* Add initial redistribution machinery and first version of covered state. Need to improve !

* Less confusing message since we now have EB.

* StateRedist -> NewStateRedist default and EB-covered declaration.

* Add EB_FlowPastCylinder case, 2D/3D.

* Set EB-covered chi_incr to zero.

* Add FlowPastCylinder CI.

* A series of minor tweaks: (#17)

- git hash subrepo to screen
 - TPROF region cleaned. Add /level chem VARS
 - print to screen nCells/extend of each level during regridding

* Add typical value machinery (#18)

* Setup multi-level min/max excluding for EB/fine covered cells
and use that for typical values.

* Add typical values to chk.

* Reset typval at the beginning of advance when needed.

* ParmParse typval options.

* Typical value declarations & call during the initialization.

* Enable Hypre interface to Nodal/MAC linear solves (#19)

* Add Hypre interface ParmParse hook.

* Pass the right hypre_namespace to MacProj.

* MG depth for MAC solve.

* Pass hypre_namespace to nodal solve.

* Add examples of Nodal/MAC hypre options for FlowPastCylinder case.

* update README

* Add a few EB test cases (#20)

* Add an enclosed vortex, failing linear solves.

* Add an input file using Hypre for the Nodal solver

* Add an EB_EnclosedFlame case too.

* Add an Hypre input for the EB_EnclosedFlame case.

* Fix TypVal bug.

* Add the UserDefined hook to EB geom.

* Add Challenge problem. Something's up, not generating the EB geom
properly at this point.

* Error BC array sizes.

* Add commented out debug statement.

* Remove DEBUG and USE_HYPRE default.

* Restore complete PistonBowl geom.

* A bit more velocity.

* Update sample input file for GMG/Hypre nodal solves.

* EB mask operations (#21)

* Fix EB-covered test while building advective update.

* Check eb-covered while assembling divu

* Set covered diffusion term.

* Check EB-covered on advective face state reconstruction.
Set covered adv. fluxes/term.

* Add 3d input version of the enclosed vortex.

* Forgotten ANREX_USE_EB ifdef.

* Remove LMeX chem tol, now directly handled by the reactor.
Add flag to skip instantaneous RR when using ReactorNull.

* Reactor ini outside OMP region, turn ON skipInstantRR flag.

* Small rearrange of TPROF region for instantRR.

* Skip instantRR if triggered. Update the logic in divU calculation.

* Add a gaseous methane laminar counterflow diffusion flame. (#23)

* Update efield portions of the Sources/Exec (#24)

* Change compiler variable for Efield.

* Bring ABecCec operator up to date with some changes in GPU handling.

* Update Efield cases GNUMakefile

* Update input to FlameSheetIons

* Update Efield compiler check through the sources.

* Modify pltfile to include HRR and re-arrange a bit to not include I_R (#25)

in ReactorNull, drop rhoYs from pltfile by default for ligher plt.

* Update includes of Projector source location and names. (#26)

* Update includes of Projector source location and names.

* Update set typical values too.

* Update to catch up with new PelePhysics PMF (#27)

* Change PMF sources location.

* Update init and bc calls to updated PMF.

* Update the Cases files.

* Update PremBunsen3D input file.

* Update PeriodicCases

* Update EnclosedFlame

* Update EB_FlowPastCylinder

* Update FlameSheet

* Update HotBubble

* Update EB_EnclosedFlame

* Projector now moved to Hydro namespace

* Update input of EnclosedFlame

* update GNUmakefiles for templated PelePhysics (#28)

Co-authored-by: Bruce Perry <baperry@princeton.edu>

* Temporary test another branch of PP.

* Restore using PP development brqnch in CI.

Co-authored-by: Bruce Perry <53018946+baperry2@users.noreply.github.com>
Co-authored-by: Bruce Perry <baperry@princeton.edu>

Co-authored-by: nickwimer <nicholas.wimer@gmail.com>
Co-authored-by: Bruce Perry <53018946+baperry2@users.noreply.github.com>
Co-authored-by: Bruce Perry <baperry@princeton.edu>
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.

1 participant