A Dedicated Educational Expert System Coupled to a
C. Cachet and D. Cabrol Centre de Recherches Pedagogiques et de Renovation Didactique en Chimie, Universite de Nice, F-06034 Nice, France A. Milleliri Ecole des Sciences et Techniaues de I'lnaenieur de Nancy, Centre de Sophia Antipolis. Avenue Beethoven, F-06560 Valbonne, France
-
From the verv beeinnine of computer usage in science a valuahle education, simuiatioi has-been re&gnized technique. Quite commonly, simulation is accepted hy educators in canes where it could replace or complement real experiments that would be too expensive, too dangerous, or imoossible in the teachine lab. Althoueh this reasoning is vaiid, i t has been pointed i u t by J. ~ e b e n s t r e i (t I ) that 2 is onlv a verv limited view of simulation that misses the main conEerning the cognitive aspects. "What the user is actine uoon durine a simulation is neither the real concrete phenomknon or system which is simulaced nor the abstract (mathematical, model which has been implemented on the computer and which is not visible to the "ser.. . . The very original nature of any simulated object implies a new type of intellectual activity" that is a t an intermediate level between concrete action and abstract thinking. This allows the design of learning situations which have been proven to be effective in science education (2). In fact. the word "simulation" is used to denote very different 'activities that fall into t h e e broad categories: buildine a model. exnlorine a model, and discovering a model. In tgswork wkark inteisted inthethirdactivit);hecause our eoal is w d e v e l o ~the student's scientific methodology. ~ i tthis i objective &mind, i t is important to design learning environments that allow the student a maximum of freedom in the conceiving and realization of hisher experimentation plan as well as in the analysis of obtained results and formulation of hisher own hypothesis. This is rarely possible under ordinary teaching conditions, in which i t is necessarv for nractical reasons to restrict the assienment to a few closely directed experiments. The use of 1ab;oratory-equivalent simulated exneriments allowed us to desien - such an interactive learning environment several years ago, using minicomnuters available a t that time (3). Next, a series of programs was developed for teaching chemical kinetics ( 4 ) based upon the same idea and making.use of the availability of micr&omputers. For more than 12 years we have been able t o observe and analyze the difficulties encountered by students faced with this unusual situation, i.e., they are assigned a general objective. and are not driven to the solution bv the software. bv the student's guides, or by the instructor:Students have tb discover their own ~ a t to h the obiective. As a matter of fact, the instructor in tke teaching lab is even more in demand than in conventional classes. On the one hand, many requests to the instructor do not require a high level of expertise or human communication skills t o be satisfied, and, on
the other, the instructor might be engaged in subtle discussions concerning complex situations. In the meantime, the power of microcomputers increased dramatically, and i t became possible to apply techniques developed from research in artificial intelligence. Considering these new possibilities, we decided to build a new system with the objective of handling automatically most of the "lower level" requests, which are also the more frequent. In our mind the system should not replace the instructor but release h i m h e r from trivial tasks, thus making time available for dialogues requiring deeper expertise, both in the subject matter (chemical kinetics) and in pedagogy. We also thought that making various helpful information and advice available throughout the program would allow a greater autonomy to the student without the risk of wasting too much time in unstructured explorations. In order to achieve these goals, i t was necessary to identify and classify the students' needs and corresponding instructor's responses and to prepare a formal set of rules that allow the dynamic construction of these responses. The Chemlcal Example Several chemical reactions have been selected to build simulation modules in the previous series (e.g., ESSOR). In order to derive the greatest benefit of the proposed approach, these examples must share some characteristics. I t should be possible tostudythese examples a t differentlevels of complexity. More precisely, it is highly desirable that the study can be undertaken initially without too much difficulty. Deeper examination later should reveal the more complex structure of the models used. For this particular application, we have selected the gas phase reaction of acrolein with butadiene. This reaction has the required characteristics indicated above; it is also the one on which we have collected the most information concerning student attitudes and the difficulties they encountered. In the temperature range 420-600 K, this reaction can be modelled by two second-order reactions (5): acrolein + butadiene tetrahydrobenzaldehyde 2 butadiene dimer All the species being gaseous in the experimental conditions, the reaction progress is observed by measurement of total pressure in a fixed-volume reactor maintained a t constant temperature. Thus, it is convenient to use partial pressure to express the rate equations:
--
Volume 66
Number 7 July 1989
553
structure is representedin part B of Figure 1.I t is built using the classical architecture of a rule-based expert system. The data base holds information transmitted by the simulation module that describes the simulated exneriments and the analyses performed by the user. The infeience engine builds the appropriate advisory statements, which are transmitted back t o the simulation module. During its "reasoning", the inference eneine updates the data base with the conclusions reached and-the riles used. The two modules have been installed in a standard IBMPC-compatible microcomputer witb a t least 512K under the control of a resident module. Communication between the modules is achieved using software pipes. (Technical details are available upon request from the authors.)
Figure 2. Design af an experiment: typical values for a first trial.
Problem
?
Experiment n.
I
Crperimantai paraneterr
-
P.AC P.B" =
2
Resuits
Advice
LXIt
I 100
P.T"B
5 m
m.1nsrt
= =
0 0
Tempsratura :
150
Figure 3. Results of expwiment number 2 in tabular form. Using cursor keys it is possibletoexamine the wholeanay and display the rateof reactionfor each point. Results can also be displayed as graphs.
The Counselor Module The counselor module is activated from the simulation module only when the user asks for advice by pressing a reserved function kev or bv selecting the "Advice" option from a menu. ~ o w e i e rcomments , i d messages are automatically issued by the system, even without the user's request, when special conditions are fulfilled. Generally these messages concern inappropriate choices of experimental conditions or inconsistency between mathematical models selected for the analysis of results and the results themselves. These messaees are directlv bv the simula.eenerated " tion module because it does not require much "reasoning" to build them. A simnle series of filters is a n ~ l i e dto each innut before processing: However, i t should be pointed out chat the user has no means of knowing the origin of a message. Explicit requests for help by t c e user may relate to dl:fferent needs. The user may simply be asking for information on how to use the system to perform a particular operation, or about one of the parameters (for example, a range of acceptable temperatures), or it may be a request concerning the validity of some obtained result or some methodological aspectof the study. The first kind of request does not require knowledge of what the user has done before in order to be satisfied: the second cateeorv reauires deener analvsis. usine both chdmical and ped~go&l'knowledge, in eider to be answered. In practice it is almost impossible t o discriminate between these two kinds of requests. Thus two different function kevs have been assimed to them. The first kind of request (asking for information) can be activated a t any time, and is handled locally by the simulation module. This is similar to context-sensitive help systems available on most professional software. The second kind of request is available only a t critical points of the simulation module, which are explicitly indicated on the screen by an active "Advice" option. These requests are transmitted to the counselor module as a message that conveys the context of the call.
-
A Typical Scenario
Figure 4. Result of the analysis of experiment number 2 using a secondarder law.
chosen model and the experimental data can be displayed visually by a linear representation (see Fig. 4) and numerically by looking a t the stability versus time of the calculated rate constant. Each time such an analysis is performed by the user, information concerning the experiment, the model chosen, and the quality of the fit of the model are sent to the counselor module. The counselor module is written in Turbo Prolog: its
Although i t is impossible to show on a static medium like these printed pages the dynamic of the student-screenkeyboard interaction, the reader may attain a better idea of the flexibility of the system by following a short, commented scenario. I t should be clear that tbis is only one typical scenario amone the mvriad ~ossible. Because thelstudeni is n i t aware a priori of the existence of the side reaction, most students choose t o start witb experimental conditions in which the two reactants have equal initial ~ a r t i a Dressures. l The initial set of default values is 2 and is generally used as is by students. presented in As a matter of fact, this set of values gives poor results because a t tbis temperature (500 K) the reaction is quite slow, and for a total time of 2000 s the percent of reaction (12%)is too low to give significant results. If the student asks for advice after simulating or analyzing the experiment corresponding to the values of Figure 2, helshe would obtain the following piece of advice:
r re
Volume 66
Number 7 July 1969
555
The oercent of reaction is too low to obtain sienificant results. " You should doanother experiment increasing the temperature or the total duration oi the exprriment. Total duration is only 2000 s. Let us assume that for the next experiment (number 2), the temperature, 550 K, and the total time, 3000s. have been chosen; the percent of reaction is then 5470, which is now sufficient. The results can be displayed in tabular form (see Fig. 3) or graphically; after playing a while with the cursor t o examine the graphics, the student will want to analyze the results. The first kinetics hypothesis selected by almost all students corresponds to a rate law of first order with respect to each reactant. This hvnothesis can he selected from a set of hypotheses in a table ;hen thestudent activates the "Analysis" ootion. The result of the analvsis is shown as a eraoh (see F'ig. 4) and the analytical exp;ession used t o cornp& this graph is shown upon request on the screen. The good linearity of this graph shows that the selected model fits the obtained results. The user can also display the value of the rate constant a t any point; using the cursor, he/ she can verifv that the rate constant is nearlv invariant during the reirtion. Asa matter of fart, thestudent satisfied with this result would miss the existence of the secondary reaction and ronclude inrorrectly that the reaction obeying a second-order rate law is an acceptable model. However, if thestudent asks for adviceat thisstaee. would obtain - . helshe . the following response, which should prevent a premature conclusion. The exoeriment no. 2 analvzed with the model no. 3 has eiven good results; you should do other experiments with different sets uf initial conditims. You cannot draw definitive cunclusions withonly oneexperiment! After this recommendation or similar but more incisive ones, the user should arrive after three or four trials a t experiments that lead to sienificant deviations from the second-order law (see for example Fig. 5). With such conditions, the representation is no longer linear, and the rate constant varies from k = 8.72 X 10-'-for t = 0 s to k = 1.48 X a t t = 5000 s. Generally, this observation raises many questions for the student, especially if strongly convinced that hefshe was on the right track. I t is in such situations that the counselor module proves most useful. A request for advice will result in a statement that underlines the lack of fit and recalls the other experiments. The series of advisory statements produced from this point are
I GI: Help for U)
< rr:
Select) 618: Camtant) GZ: M u l a )
(Fsc:
Puit)
I
Figure 5. Result of secnnd-order analysis of a reaction with Pa. = 500. &. = 850, T = 550 K, total time = 5000 r.
556
Journalof Chemical Education
designed to lead the user t o simulate some key experiments that should help h i m h e r to discover the second reaction. For example, i t is suggested that the student design two experiments a t the same t e m ~ e r a t u r ewith the initial pressuies of acrolein and butadiene interchanged. Results obtained with the experiment no. 3 processed with the
model no. 4 are not satisfying. Using the same hypothesis, you obtained inconsistent results for the experiments no. 2 and no. 3. An experiment at 550 K with P, = 850 and Pb, = 500 would probably help you. With the result of this sueeested exoeriment available. i t isquitesimple toshow that the tworeactants play asymmetric roles. Other advice mav underline the fact that tor the same time the total pressure is not the same in the two cases, and the drop in pressure is more significant when more butadiene is used. Other series of advisory statements invite the student to compare initial rates for different experiments and relate these values t o the initial composition. In conclusion, the advisory statements are designed in such a wav that the user should realize that the mechanism cannot be limited only to the first reaction. Definitive results are obtained bv considerine each reactant senaratelv and observing that iutadiene can react by itself andcause drop in oressure. AS mentioned above, the counselor is not expected to have a dialogue with the user, but, as shown in the presented scenario, t o give advice leading the student to a given stage of knowledge. Then the discussion with the teacher can take place in a much better context. because the teacher can relv bn the fact that all necessary ihformation to solve the prodlem has been collected.
--
a
Deslgn of the Knowledge Base I t is largely admitted that the main problem in building expert systems lies in the adoption of a systematic approach on the basis of which rules can he formulated. In the present case we used two different criteria to organize our sets of rules. On the one hand, we take into account the various contexts of calls to the advisor; on the other hand, we use the information available to the expert system to compose the advisory statements. Reouests for advice can be issued directlv from the main menuof the simulation module, from all critical steps of the simulation. or from the analvsis of the obtained results. From each'of these contexts tl;e user has different information nresent on the screen. Deoendine on the context, the advice applies to the last experiment p&formed or to the one currently considered (by viewing, graphing, or analyzing) by the student. Further distinction is made depending upon whether the experiment in question has already been analyzed using one of the mathematical models. The advisory statements are not limited to a simple comment; they may include suggestions for further experiments or analysis. Most of the time these suggestions are intended to invite the student to enlarge the domain that helshe is investigating. Although very different, all advisory statements are built using a single strategy that consists mainly of examining successive layers of production rules in forward chaining. The first layer relies on the examination of asingle experiment. Based on the context, it may be the last simulated experiment or the one the student is currently working with. In both cases, the expert system scans two critical points first. namelv the oercent of reaction reached a t the end of the experimmt &d the reactivity of the system compared to the experimental fluctuations. If one of the production rules that deal with these points can be applied, this means that the corresponding experimental results cannot be analyzed t o obtain significant conclusions. Consequently an advisory statement is generated, and specific experimental conditions are used to customize and enrich the advice. For example, the advice might indicate that the percent reaction is too
low to allow taking the present reaction into account and suggest a longer duration for the experiment or operation a t a higher temperature. Because the inference engine can handle variables, i t is possible to give very precise advice based not only on values stored in the data base but also selected values from the current experiment. The data base is updated each time a production rule is applied. Once completely built, the advice is sent to the simulation module and control is returned to this module. The user is free to follow the suggestions or to ignore them. Helshe may even ask immediately for help again. In this case, the counselor module will produce a more definitive advisory statement that the experiment is not suitable for obtaining a significant conclusion. The next series of rules of this first layer examines whether the obtained simulated results are compatible with the stoichiometry of the first reaction considered alone. For a higher value of percent reaction, and when the second reaction is perceptible, the total pressure can drop below the value which corresponds to total completion of the first reaction. This important information is sometimes missed or underestimated by students. In this case, the advice displayed will underline this point and prompt the student on its importance. If no rules of the previous kind can be activated, the expert system will give no specific advice before any analysis bas been performed. Only very general advice can be given in this situation, which leads t o the conclusion that the student has made no hypothesis concerning the mechanism. If a t least one data analysis has been done and help was requested from the analysis submodule, then another series of rules from the first layer is examined by the inference engine. These rules are designed to comment on the agreement between the linear relationship obtained using the model selected, and the simulated results. The second layer of rules takes into account all the operations and choices made previously by the student. In the case where partial conclusions drawn by the first layer of rules are obtained for the first time, the advice is completed by a suggestion to search for confirmation of these conclusions using different experimental conditions. Depending upon specific classes of conditions, more precise indications can be produced. For example, i t may he suggested that the user increase the temperature or vary the initial composition, giving reference to the values previously used. In the case where these partial conclusions were obtained before, the advice will be completed by a comment that underlines this concordance and recalls the previous experiment that gave the same conclusion. Usually the two experiments have been done with similar conditions, in which case specific directions are given to choose other conditions. If the conditions are sufficiently different, then the system suggests drawing definitive conclusions from these observations. Sometimes, the results of the current experiment are in contradiction to those obtained from a previous one. This is the most interesting situation because i t is the one which should lead to rejection of the first simple model and consideration of the existence of the second reaction. So the rules
have been crafted in a way that emphasizes the contradiction and aives useful hints for the design of the key experiments without giving explicitly the solution to the proGIem. In some limited cases, no rules of the above layers can be applied. This may originate from many requests for help without exploring any useful choices and analyses with the simulation~module.In that case. a third laver of rules is scanned which examines the set oiexperime& and analysis done so far as a whole and tries to give a general indication. Conciuslon In addition to the classical applications of computers in science education (as a tool for acquisition, storage, processing, and retrieval of data) there has been heated debate between partisans of two opposing paradigms: (1)nondirected open-ended problem-solving situations and ( 2 ) tutorial svstems (currenilv aualified as intellieent). " In fact; each approach has its own idvantages and limitations. The former allows develo~mentof ~ e r s o n asolutions l and is generally considered as more motivating, but can also lead t o waste of time and unstructured ex~lorations.The latter leaves little room for initiative hut-is expected to embodv effective teaching strategies. The idea of intelligent tutoring systems (ITS) (7) canno; be applied without a precise model of the learner's knowledge. Consequently such systems require considerable effort and research before practical applications can he considered in a precise domain such as chemical kinetics. Moreover, computer resources needed for ITS are far beyond what is available for education even in fairly well-equipped universities. In this work we tried to take the best of both approaches, using the technology that is currently available. Association of a counselor module built as a rule-based expert system with a simulation module gives an acceptable answer t o the objective stated in the introduction. Experiments with students show very positive responses, and the role of the instructor is enhanced because hisher expertise (both in the subject matter and in pedagogy) is better used than in situations in which helshe mav be o\,erwhelmed with relatively trivial requests. Besides simulation (kind of activitv). and chemical kinetics (to~ics). c h be used . . .. this a ~- ~ r o a can in other situations and for other topics as well. For example, we are currentlv working with Proiect SERAPHIM to associate such a co&selor module with the KC? Discoverer program.. which uses a data base t o allow students to explore the " solvproperties of elements (8)and to dialogues for ing in spectroscopy (9).
.
A
Llterature Cited 1. Heheneveif, J. A Computer for Each Stdenl; Lrwis. a,: Tagg, E. D., Eds.: Elsevier (North-Holland):1987: pp 13-21. 2. Lagowki, J. J. Acod. Cornput. 1981,11,34. 3. Cabrol, D.;Cachet, C.; B m , J. H. J Chem.Edue. 1315,52,2662M(. 4. Csbrol, D.:Cachet, C. Eur. J. Sei. Educ. 1981,3,303312. 5. KistiakosnLy,G. 8.: Lacher, J. R. J . Am. Chem. Sac. 1936,58,123. 6. Moore. J.W.;Pearson. R. G. Kinelica and Mochonism,3rd ed: Wi1cy:Nsw York. 1981: pp 197. 7. Sleman, D.; Brown. J. S. Infolli#enl Tutoring Syafem: Sleman, D.; Brown, J. S.. Ed%; Academic: Landon.1982: pp 1-11. 8. Cabrol. D.; Moore, J. W.; Cachet, C.: Fmg, A. IBM Academic Computing Conference. June 1988, Dalhs, Texaa. 9. Cabral. D.;Rsbine, J.P.:Foneat,T.P. Compul.Edue. 1988,12,24-246.
Volume 66 Number 7 July 1989
557