Improve handling of duplicate reaction check for reactions that are multiples of one another

Open
#704 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
cpp
Domain
backend, cli

Research direction

Start by tracing the duplicate-reaction handling in the Chemkin conversion entry points ck2cti and ck2yaml, then inspect how converted CTI or YAML mechanisms are validated. Compare the two proposed resolution options and identify the existing reaction checks they affect. Done means the stated multiple-reaction mechanism is usable without manual edits, with behavior covered by the relevant existing test suite.

Written by the indexing model from the issue text.

Description

Input Kinetics
Cantera version

2.4.0 (and master)

Expected Behavior

Chemkin-format mechanisms containing reactions that are "multiples" of one another, such as A <=> B and 2 A <=> 2 B that are not marked as duplicates (and do not need to be marked for use with Chemkin) should be usable with Cantera without having to manually edit the CTI or YAML version of the mechanism.

Actual Behavior

Cantera identifies the reactions as unmarked duplicates. See https://groups.google.com/forum/?fromgroups#!topic/cantera-users/CPniMFXxafQ for an example of this behavior in the wild.

Resolution options
  1. Treat reactions which are multiples of one another as not being duplicates. This would be a change to the long-standing duplicate reaction check that Cantera uses.
  2. Automatically add the appropriate "duplicate" notation to the reactions when converting from Chemkin format using ck2cti or ck2yaml.

I think either of these options is a viable fix, and don't have a strong preference either way. I think there are other cases where we definitely shouldn't just replicate Chemkin's definition of duplicate reactions, so implementing the ability to do (2) would be useful for those as well.

Dominant language
C++
Stars
883
Forks
436
Avg merge
3h 41m
Merged PRs (30d)
1

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Cantera/cantera

All issues in Cantera/cantera

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.