|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.davidson.chm.equilibria.Phase
public abstract class Phase
The phase (a gas, liquid, solid, or solution) is a component in a chemical system and contains one or more chemical species. The user must explicitly define each species in addition to defining the phase.
Physical States:
s indicates a pure solid, which contains a single species whose charge must be zero.
l indicates a pure liquid, which contains a single species whose charge must be zero.
g indicates a gas, which contains one or more species, each of which must have a charge of zero.
d indicates a solution, which contains one or more species. The solvent must have a charge of zero. If the solvent is protic, the solvent acid and base species are automatically generated and given labels "acid" and "base".
All "set" methods for extensive quantities (moles, mass, volume) set the analytical value. All "get" methods return the actual value. If the "get" method is called after the equilibrium problem is solved, the returned value is the equilibrium value. If the "get" method is called prior to solving the equilibrium problem, the value has no reliable meaning.
Copyright (c) David N. Blauch
| Field Summary | |
|---|---|
protected boolean |
autoChargeBalance
|
protected ChemSystem |
chemSystem
|
protected double |
density
|
protected double |
dielectricConstant
|
protected boolean |
isProtic
|
protected java.lang.String |
label
|
protected char |
physState
|
protected java.util.Vector<Species> |
species
|
protected double |
volume
|
| Fields inherited from interface edu.davidson.chm.equilibria.PhysicalConstants |
|---|
F, k, No, perm, qe, R, RJ |
| Constructor Summary | |
|---|---|
Phase()
|
|
| Method Summary | |
|---|---|
Species |
addSpecies(ChemSpecies _chemSpecies,
double _moles)
Adds more of an existing ChemSpecies to the phase. |
void |
addSpecies(Species _species)
Adds a Species to the phase. |
Species |
addSpecies(java.lang.String _chemSpeciesLabel,
double _moles)
Adds more of an existing ChemSpecies to the phase. |
abstract Phase |
copyOf(ChemSystem _chemSystem)
Creates a copy of the phase and places it in the indicated ChemSystem. |
Species[] |
createSpecies(ChemSpecies[] _chemSpecies,
double[] _moles)
Creates a series of new Species and adds them to the Phase. |
Species |
createSpecies(ChemSpecies _chemSpecies,
double _moles)
Creates a new Species and adds it to the Phase. |
abstract Species |
getAcid()
Returns the conjugate acid of the solvent for a solution with a protic solvent. |
boolean |
getAutoChargeBalance()
Returns the autoChargeBalance property |
abstract Species |
getBase()
Returns the conjugate base of the solvent for a solution with a protic solvent. |
ChemSystem |
getChemSystem()
Returns the chemical system in which the phase exists |
double |
getDensity()
Returns the density of the phase in grams per milliliter |
double |
getDielectricConstant()
Returns the dielectric constant of the phase |
double |
getEDHEa()
Returns the Extended Debye-Huckel Equations a parameter, which appears in the numerator of the expression for ln f. |
double |
getEDHEb()
Returns the Extended Debye-Huckel Equations b parameter in units of 1/angstrom, which appears in the denominator of the expression for ln f. |
java.lang.String |
getInfo()
Returns information about this class |
abstract double |
getIonicStrength()
Returns the ionic strength of the phase |
boolean |
getIsProtic()
Returns true if the phase is a solution with a protic solvent |
java.lang.String |
getLabel()
Returns the phase label |
double |
getMass()
Returns the total mass of the phase in grams |
double |
getMoles()
Returns the total moles of species in the phase |
int |
getNbrSpecies()
Returns the number of species in the phase |
double |
getpH()
Returns the pH of the phase. |
char |
getPhysicalState()
Returns the physical state of the phase. |
double |
getpOH()
Returns the pOH of the phase. |
abstract double |
getPressure()
Returns the pressure of the phase. |
double |
getPressure(double _moles,
double _volume)
Returns the pressure of the phase for the specified number of moles and the indicated volume (in Liters). |
abstract Species |
getSolvent()
Returns the solvent species of a solution. |
Species[] |
getSpecies()
Returns an array of species in the system |
Species |
getSpecies(ChemSpecies _chemSpecies)
Returns the Species with the given ChemSpecies. |
Species |
getSpecies(java.lang.String _label)
Returns the species with the given label; returns null if the species does not exist. |
Species |
getSpeciesAt(int _index)
Returns species at given index |
abstract double |
getVolume()
Returns the volume of the phase in liters |
boolean |
removeSpecies(Species _species)
Removes the species from the phase. |
boolean |
removeSpecies(java.lang.String _label)
Removes the species with the given label. |
void |
scale(double _factor)
Scales the amount of the phase. |
void |
setAutoChargeBalance(boolean _val)
Sets the autoChargeBalance property. |
abstract void |
setDensity(double _density)
Sets the density of the phase. |
void |
setDielectricConstant(double _dielectricConstant)
Sets the dielectric constant for the phase (solvent in a solution) |
void |
setLabel(java.lang.String _label)
Sets the label for a phase |
abstract void |
setMass(double _mass)
Sets the mass for the phase. |
abstract void |
setVolume(double _volume)
Sets the volume for the phase. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.lang.String label
protected java.util.Vector<Species> species
protected ChemSystem chemSystem
protected char physState
protected boolean isProtic
protected double density
protected double dielectricConstant
protected double volume
protected boolean autoChargeBalance
| Constructor Detail |
|---|
public Phase()
| Method Detail |
|---|
public void addSpecies(Species _species)
public Species addSpecies(ChemSpecies _chemSpecies,
double _moles)
_moles - amount of the species to be added
public Species addSpecies(java.lang.String _chemSpeciesLabel,
double _moles)
_moles - amount of the species to be added
public Species[] createSpecies(ChemSpecies[] _chemSpecies,
double[] _moles)
_moles - array containing the amount of each species to be created or added
public abstract Phase copyOf(ChemSystem _chemSystem)
public Species createSpecies(ChemSpecies _chemSpecies,
double _moles)
_moles - amount of the species to be created or added
public abstract Species getAcid()
public boolean getAutoChargeBalance()
public abstract Species getBase()
public ChemSystem getChemSystem()
public double getDensity()
public double getDielectricConstant()
public double getEDHEa()
public double getEDHEb()
public java.lang.String getInfo()
public abstract double getIonicStrength()
public boolean getIsProtic()
public java.lang.String getLabel()
public double getMass()
public double getMoles()
public int getNbrSpecies()
public double getpH()
public char getPhysicalState()
s = solid (this phase contains only one species)
l = liquid (this phase contains only one species)
g = gas
d = solution (the phase contains a solvent and solutes)
public double getpOH()
public abstract double getPressure()
public double getPressure(double _moles,
double _volume)
public abstract Species getSolvent()
public Species getSpecies(java.lang.String _label)
public Species getSpecies(ChemSpecies _chemSpecies)
public Species[] getSpecies()
public Species getSpeciesAt(int _index)
public abstract double getVolume()
public boolean removeSpecies(Species _species)
addSpecies(edu.davidson.chm.equilibria.Species)public boolean removeSpecies(java.lang.String _label)
addSpecies(edu.davidson.chm.equilibria.Species)public void scale(double _factor)
_factor - scaling factorpublic void setAutoChargeBalance(boolean _val)
public abstract void setDensity(double _density)
_density - density in grams per milliliterpublic void setDielectricConstant(double _dielectricConstant)
public void setLabel(java.lang.String _label)
public abstract void setMass(double _mass)
_mass - mass in gramspublic abstract void setVolume(double _volume)
_volume - volume in liters
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||