diff --git a/doc/sphinx/cython/importing.rst b/doc/sphinx/cython/importing.rst new file mode 100644 index 000000000..fcb7763d4 --- /dev/null +++ b/doc/sphinx/cython/importing.rst @@ -0,0 +1,18 @@ +.. py:currentmodule:: cantera + +Importing Phase Objects +======================= + +These classes are composite representations of a substance which has +thermodynamic, chemical kinetic, and (optionally) transport properties. + +.. autoclass:: Solution + +.. autoclass:: Interface + +.. autoclass:: DustyGas + +Utility Functions +----------------- + +.. autofunction:: addDirectory diff --git a/doc/sphinx/cython/index.rst b/doc/sphinx/cython/index.rst index 6472041fe..b9589104a 100644 --- a/doc/sphinx/cython/index.rst +++ b/doc/sphinx/cython/index.rst @@ -6,6 +6,7 @@ Contents: .. toctree:: :maxdepth: 2 + importing thermo kinetics transport diff --git a/interfaces/cython/cantera/composite.pyx b/interfaces/cython/cantera/composite.pyx index 0ce7b7d93..c111726e5 100644 --- a/interfaces/cython/cantera/composite.pyx +++ b/interfaces/cython/cantera/composite.pyx @@ -1,8 +1,32 @@ class Solution(ThermoPhase, Kinetics, Transport): - pass + """ + A class for chemically-reacting solutions. + + Instances can be created to represent any type of solution -- a + mixture of gases, a liquid solution, or a solid solution, for + example. + + Class Solution derives from classes `ThermoPhase`, `Kinetics`, and + `Transport`. It defines very few methods of its own, and is provided so + that a single object can be used to compute thermodynamic, kinetic, and + transport properties of a solution. + """ class Interface(InterfacePhase, InterfaceKinetics): - pass + """ + Two-dimensional interfaces. + + Instances of class Interface represent reacting 2D interfaces + between bulk 3D phases. Class Interface defines no methods of its + own. All of its methods derive from either `InterfacePhase` or + `InterfaceKinetics`. + """ class DustyGas(ThermoPhase, Kinetics, DustyGasTransport): - pass + """ + A composite class which models a gas in a stationary, solid, porous medium. + + The only transport properties computed are the multicomponent diffusion + coefficients. The model does not compute viscosity or thermal conductivity. + + """ diff --git a/interfaces/cython/cantera/utils.pyx b/interfaces/cython/cantera/utils.pyx index 634181c2e..77f2ba162 100644 --- a/interfaces/cython/cantera/utils.pyx +++ b/interfaces/cython/cantera/utils.pyx @@ -17,6 +17,7 @@ cdef pystr(string x): return s.decode() def addDirectory(directory): + """ Add a directory to search for Cantera data files. """ CxxAddDirectory(stringify(directory)) def _have_sundials():