A Object-Oriented Implementation of a Chemical Waste Consolidation Expert System
Return to front page
1. Background and Rationale
2. Interface Design
3. System Design
4. Evaluation and Results
5. Future Work
Bibliography and References
Appendix A. Example Drum Report
Appendix B. Chemical Compatibility Testing Data
2.1. The Chemical and Chemical Mixture Interface
Choosing option C from the Main Menu takes the user directly to the Chemical and Mixture Menu as depicted in Figure 2.4.
Figure 2.4. Chemical and Mixture Menu
This is the interface to allow the user to manipulate the chemical library. To add a chemical to the library, inputting A leads to the Add a Chemical or Mixture interface, which systematically interrogates the user to obtain exhaustive information about the candidate chemical. The user inputs the chemical name, the Chemical Abstract Service (CAS) number, the NFPA numbers, and physical data including melting point, boiling point, density, molecular weight, water solubility, heat of dilution, incompatibilities and chemical type. The input is checked for absurd and spurious data. For example, it looks for an integer value between 0 and 4 for the NFPA numbers. The software populates the chemical library with these chemical properties and derived information. Choosing S from the Chemical and Mixture Menu leads to the Chemical Search Routine, which is the user interface to the chemical library. It begins by asking for the first letter of the chemical in question and displaying all library chemicals beginning with that letter. An example of the chemicals beginning with d is shown in Figure 2.5.
Figure 2.5. Chemical Search Routine
The user types the index number of the chemical in question. If the chemical is not on the list, the user can input -1. This will allow the user to input a new chemical into the library or abort the search. Inputting the number 34 takes the user to the Chemical Information display for Dichloromethane as shown in Figure 2.6.
Figure 2.6. Chemical Information Display
The Chemical Information display shows all the chemical information that the library uses to make the waste designation and compatibility decisions. It lists all the chemical type descriptors and the incompatibilities with other chemicals and general chemical types. It also includes waste type and the waste ‘H’ code used by the chemical waste company EOG. The Chemical Compatibility of Chemical Pairs interface allows the user to check the compatibility of any two selected library chemicals and provides the software’s analysis of whether the two can or should be mixed. This computation is the basis of determining the reactions when multiple chemicals are mixed. The reason that the binary comparisons are valid for trinary or quartenary or even more complex reaction scenarios lies with the theory of chemical kinetics [Petrucci 2002] and the definition of a spontaneous reaction. Figure 2.7 shows the potential energy of a chemical species diagram for a spontaneous and a non-spontaneous reaction.
Figure 2.7. Spontaneous and Non-Spontaneous Reactions
All reactions require an energy input to cross the activation energy barrier. In spontaneous reactions, the reaction eventually releases energy, producing compounds with lower potential energy and therefore less chemical reactivity than the reactants. A non-spontaneous reaction generates products with higher potential energy and higher reactivity by requiring an input of energy, usually in the form of heat. This does not happen in an unheated bottle or drum sitting in thermal stasis over time. To say that compound A spontaneously reacts with compound B to give compound C which is more reactive that A or B ignores the reality of chemical kinetics. Certainly spurious extra reactions are occurring, but they are minimally significant in the calculations and generate product compounds that are lower in chemical energy and reactivity. After very few degradation reactions, the products become practically chemically inert and insignificant to the calculations of the more reactive species. Molecular kinetic theory allows the inference that the reactions become less likely as the reactants are diluted [McMurry 2003]. The current consolidator functions using an identical methodology of incompatibility comparison and it is physically impossible for any human to mentally remember or consider every possible reaction of every possible combination of perhaps hundreds of chemicals. Simply knowing all the incompatibilities of the chemicals in the mixture has proved a reliable method of consolidation. The results of a comparison between dichloromethane and nitric acid are shown in Figure 2.8.
Figure 2.8. Compatibility of Dichloromethane and Nitric Acid
The Chemical and Mixture Menu has routines to Add a Chemical Type Descriptor and Add a Incompatible Type Descriptor to further describe a chemical and its incompatibles. There is also a routine to remove a chemical from the library obviously titled Delete a Chemical/Mixture.