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

Revised twin flame #356

Closed

Conversation

santoshshanbhogue
Copy link
Contributor

There are two problems with the existing example (premixed_counterflow_twin_flame.py)

  1. The strain rates are not computed the right way (differentiation of the velocity field as well as the characteristic strain rate)
  2. The example does not work anymore in 2.3.0a2 with GRI3.0 (It worked with 2.2)

In this commit, I fixed the first problem. I checked it against the Smooke and Giovangigli mechanism for methane, for which this file works. I also tried lots of ways to curv, gradient, etc and various compositions, but gave up. Looks like a numerical (convergence) issue, but there is a good chance that the code will work with other mechanisms that do not ship with Cantera

Secondly, I added a function to compute the consumption speed, since this is a popular use for the twin flame solver. The integration is done using np.trapz, overriding the need for scipy.integrate.trapz as was done in the previous commit

@speth
Copy link
Member

speth commented Jul 25, 2016

The second issue is fixed by 6b588c5. Not actually a numerical issue.

@santoshshanbhogue
Copy link
Contributor Author

Based on previous comment, I explicitly added reference to select mixture-averaged model. The example now works with GRI 3.0

@@ -1,20 +1,59 @@
# coding: utf-8

"""
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason for removing this summary?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Accidentally omitted. Reinserted in e738001

# Use mixture-averaged properties
oppFlame.transport_model = 'Mix'
# Uncomment this line to use a Multi-component formulation. Default is mixture-averaged
#oppFlame.transport_model = 'Mix'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this say 'Multi' to match the comment? Or should the comment be changed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the catch. Changed in 833e850

@speth
Copy link
Member

speth commented Jul 27, 2016

Merged as 1dc7071 and 036eeb1.

@speth speth closed this Jul 27, 2016
@santoshshanbhogue santoshshanbhogue deleted the revisedTwinFlame branch August 18, 2016 18:08
@speth speth mentioned this pull request Nov 29, 2016
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.

3 participants