[Thermo] Deprecate classes tpx::leekesler and tpx::RedlichKwong
These are implementations of tpx::Substance which cannot actually be instantiated from within the PureFluidPhase wrapper class. The broken implementation of a CTML class for redlich_kwong is removed here. A functional implementation of the Redlich-Kwong equation of state remains in class RedlichKwongMFTP. Resolves #263
This commit is contained in:
parent
36cff8e368
commit
668634c969
3 changed files with 8 additions and 41 deletions
|
|
@ -2294,47 +2294,6 @@ class RedlichKwongMFTP(phase):
|
|||
k['model'] = self._kin
|
||||
|
||||
|
||||
class redlich_kwong(phase):
|
||||
"""A fluid with a complete liquid/vapor equation of state.
|
||||
This entry type selects one of a set of predefined fluids with
|
||||
built-in liquid/vapor equations of state. The substance_flag
|
||||
parameter selects the fluid. See purefluids.py for the usage
|
||||
of this entry type."""
|
||||
|
||||
def __init__(self,
|
||||
name = '',
|
||||
elements = '',
|
||||
species = '',
|
||||
note = '',
|
||||
substance_flag = 7,
|
||||
initial_state = None,
|
||||
Tcrit = 1.0,
|
||||
Pcrit = 1.0,
|
||||
options = []):
|
||||
|
||||
phase.__init__(self, name, 3, elements, species, note, 'none',
|
||||
initial_state, options)
|
||||
self._subflag = 7
|
||||
self._pure = 1
|
||||
self._tc = 1
|
||||
self._pc = 1
|
||||
|
||||
def conc_dim(self):
|
||||
return (0,0)
|
||||
|
||||
def build(self, p):
|
||||
ph = phase.build(self, p)
|
||||
e = ph.child("thermo")
|
||||
e['model'] = 'PureFluid'
|
||||
e['fluid_type'] = repr(self._subflag)
|
||||
addFloat(e, 'Tc', self._tc, defunits = "K")
|
||||
addFloat(e, 'Pc', self._pc, defunits = "Pa")
|
||||
addFloat(e, 'MolWt', self._mw, defunits = _umass+"/"+_umol)
|
||||
ph.addChild("kinetics")
|
||||
k['model'] = 'none'
|
||||
|
||||
|
||||
|
||||
class ideal_interface(phase):
|
||||
"""A chemically-reacting ideal surface solution of multiple species."""
|
||||
def __init__(self,
|
||||
|
|
|
|||
|
|
@ -3,18 +3,22 @@
|
|||
#define TPX_RK_H
|
||||
|
||||
#include "cantera/tpx/Sub.h"
|
||||
#include "cantera/base/global.h"
|
||||
#include <math.h>
|
||||
|
||||
namespace tpx
|
||||
{
|
||||
const double GasConstant = 8314.3;
|
||||
|
||||
//! @deprecated To be removed after Cantera 2.3.
|
||||
class RedlichKwong : public Substance
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
RedlichKwong() {
|
||||
Cantera::warn_deprecated("class RedlichKwong",
|
||||
"To be removed after Cantera 2.3.");
|
||||
setParameters(1.0, 1.0, 1.0);
|
||||
m_name = "Redlich-Kwong";
|
||||
m_formula = "-";
|
||||
|
|
|
|||
|
|
@ -3,16 +3,20 @@
|
|||
#define TPX_LK_H
|
||||
|
||||
#include "cantera/tpx/Sub.h"
|
||||
#include "cantera/base/global.h"
|
||||
|
||||
namespace tpx
|
||||
{
|
||||
|
||||
//! @deprecated To be removed after Cantera 2.3.
|
||||
class leekesler : public Substance
|
||||
{
|
||||
public:
|
||||
leekesler(double tc = 1.0, double pc = 1.0,
|
||||
double wt = 1.0, int itype = 0) {
|
||||
Tcr = tc;
|
||||
Cantera::warn_deprecated("class leekesler",
|
||||
"To be removed after Cantera 2.3.");
|
||||
Pcr = pc;
|
||||
Mw = wt;
|
||||
Isr = itype; // simple fluid or reference
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue