Hi James,
This is a somewhat tricky system to represent in Cantera, and there are a few pitfalls to be wary of. Some of these issues are documented in Enhancement #202, and I hope we can simplify some of this modeling in a future version of Cantera.
One thing you should be careful about is the units of the Redlich-Kwong coefficients. Based on the magnitudes of the “a” parameter, I think these values are in CGS units. You can specify this unit system locally within the equation-of-state field of the species entry, for example:
equation-of-state: units: {length: cm, quantity: mol, activation-energy: cal/mol} model: Redlich-Kwong a: [1.4480e+13, 0] b: 39.45With the mis-interpreted coefficients, the phase was giving activity coefficients of zero, which caused the reaction rates to be zero. I also noticed that the site-density key in the input file is typoed as sites-density.
Second, while you have imported an Interface phase, that interface hasn’t been connected to the reactor network as a surface with a particular extent. As shown in Enhancement #202, you currently need to create two ReactorSurface objects, one to represent the interaction with each bulk phase, something like:
area = 1.0 s1 = ct.ReactorSurface(test7, r=r1, A=area) s1 = ct.ReactorSurface(test7, r=r2, A=area)I think you can simplify your reaction definition and skip defining a “surface” SO2 species, and define a reaction that goes directly from the gas to the liquid phase:
- equation: SO2(g) => SO2 # reaction rate-constant: {A: 3.4E+02, b: 0.0, Ea: 0.0}One other thing is that you want to make sure that the system of equations is well behaved as the reactants are consumed. In the given setup, the gas phase is specified as only having a single component (SO2) and being a constant pressure reactor. In this case, as the reaction proceeds, the volume and mass of the reactor will go down, but the reaction rate will remain constant even as the mass approaches zero because the concentration of SO2 is held fixed. This can be fixed either by using a gas with at least some diluent species, or by using a constant volume reactor, in which case the concentration (and therefore reaction rate) will decrease as the reactant is consumed.
Regarding a couple of your other questions:
Regards,
Ray