ReactionMechanismGenerator / ReactionMechanismSimulator.jl

The amazing Reaction Mechanism Simulator for simulating large chemical kinetic mechanisms
https://reactionmechanismgenerator.github.io/ReactionMechanismSimulator.jl
MIT License
74 stars 33 forks source link

Fix multidomain AutomaticMechanismAnalysis #183

Closed hwpang closed 2 years ago

hwpang commented 2 years ago

Bigger changes:

  1. Append the global p vector (corresponding to multidomain) to each Simulation object in SystemSimulation, instead of the local p vector (corresponding to one domain). Append interfaces as well.
  2. Uses the global p vector to calculate dSdt and the corresponding global indexes for species and reactions
hwpang commented 2 years ago

Previous push crashes single domain AMA. New push fixes it.

hwpang commented 2 years ago

Previous push crashes the test due to incorrect indexing. New push fixes it.

hwpang commented 2 years ago

New push fixes a bug related to the test for multidomain AMA

codecov[bot] commented 2 years ago

Codecov Report

Merging #183 (f462a06) into main (1dd0471) will increase coverage by 0.12%. The diff coverage is 62.16%.

@@            Coverage Diff             @@
##             main     #183      +/-   ##
==========================================
+ Coverage   52.28%   52.40%   +0.12%     
==========================================
  Files          29       29              
  Lines        5876     5883       +7     
==========================================
+ Hits         3072     3083      +11     
+ Misses       2804     2800       -4     
Impacted Files Coverage Δ
src/TestReactors.jl 100.00% <ø> (ø)
src/TransitorySensitivities.jl 25.31% <21.42%> (ø)
src/Simulation.jl 31.55% <83.33%> (+0.59%) :arrow_up:
src/AutomaticMechanismAnalysis.jl 88.97% <88.23%> (+0.09%) :arrow_up:
src/Reactor.jl 75.78% <0.00%> (+0.87%) :arrow_up:

:mega: Codecov can now indicate which changes are the most critical in Pull Requests. Learn more

hwpang commented 2 years ago

Previous push encountered package version incompatibility problem after removing and reinstalling numpy, as well as installing nomkl. New push removed the related code.

hwpang commented 2 years ago

@mjohnson541 I have addressed all the comments.

hwpang commented 2 years ago

@mjohnson541 I have addressed all your comments & all tests have passed.