Skip to content

Commit

Permalink
Added thermal conductivity test to TestDustyGas class
Browse files Browse the repository at this point in the history
  • Loading branch information
chinahg authored and speth committed Apr 18, 2021
1 parent 80a3c89 commit 3cd220b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
5 changes: 5 additions & 0 deletions interfaces/cython/cantera/test/test_transport.py
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,11 @@ def test_molar_fluxes(self):
# Not sure why the following condition is not satisfied:
# self.assertNear(sum(fluxes1) / sum(abs(fluxes1)), 0.0)

def test_thermal_conductivity(self):
gas1 = ct.Solution('h2o2.xml', transport_model='multicomponent')
gas1.TPX = self.phase.TPX

self.assertEqual(self.phase.thermal_conductivity, gas1.thermal_conductivity)

class TestWaterTransport(utilities.CanteraTest):
"""
Expand Down
6 changes: 5 additions & 1 deletion interfaces/cython/cantera/transport.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,11 @@ cdef class Transport(_SolutionBase):
return self.transport.electricalConductivity()

property thermal_conductivity:
"""Thermal conductivity. [W/m/K]."""
"""
Thermal conductivity. [W/m/K]
Returns thermal conductivity of the ideal gas object using the multicomponent
model. The value is not specific to the dusty gas model.
"""
def __get__(self):
return self.transport.thermalConductivity()

Expand Down

0 comments on commit 3cd220b

Please sign in to comment.