I'm not sure if this is actually a bug, but I was using the Python interface and looping over the species in the mechanism and printing the transport properties when I ran into an unexpected behavior regarding the binary diffusion coefficients..
Minimal Example:
import cantera as ct
gas = ct.Solution('h2o2.yaml')
gas.TP = 300, 1
gas['H2'].binary_diff_coeffs
If I understand correctly, the specific transport properties of a species in the mechanism can be queried by providing a species name to the object like gas['H2'].viscosity. This would be the pure fluid viscosity of the H2 species. I had expected a similar call to gas['H2'].binary_diff_coeffs to return a list of 10 entries, representing the binary diffusion coefficients for species H2 into the rest of the species in the mechanism. What got returned by the call was the full 10x10 list of lists representing the binary diffusion coefficients for all species into all other species.
I was wrong. That is not how the solution object works at all. I should have been providing an X for a TPX query and setting single species one-at-a-time to get properties for those species.
I'm not sure if this is actually a bug, but I was using the Python interface and looping over the species in the mechanism and printing the transport properties when I ran into an unexpected behavior regarding the binary diffusion coefficients..
Minimal Example:
import cantera as ct gas = ct.Solution('h2o2.yaml') gas.TP = 300, 1 gas['H2'].binary_diff_coeffs
If I understand correctly, the specific transport properties of a species in the mechanism can be queried by providing a species name to the object like gas['H2'].viscosity. This would be the pure fluid viscosity of the H2 species. I had expected a similar call to gas['H2'].binary_diff_coeffs to return a list of 10 entries, representing the binary diffusion coefficients for species H2 into the rest of the species in the mechanism. What got returned by the call was the full 10x10 list of lists representing the binary diffusion coefficients for all species into all other species.
System information