Welcome to Summer 2000 CONFCHEM Internet Conference on Chemistry |
---|
A system may be set up according to some theories. For example, van der Waals equation can be used for real gases to illustrate how real gases differ from the ideal gas. These equations are implemented in a Java applet to simulate a system for a user to explore the difference. From this simulation, a user is asked to find out conditions in which the ideal gas law gives results within a set error limit.
A Java applet is written to simulate properties of gases. A user can choose one of several gases to investigate at a time. The temperature and volume are two independent variables that can be altered, and the pressures calculated by the two models are presented. This is a deterministic simulation, but the calculated pressures may be misleading. One of the suggested application is to ask students to formulate a general statement regarding the conditions, under which the model is valid. Gases such as He, H_{2}, N_{2}, H_{2}O, CO_{2}, etc are included the Java applet.
Differential equations are excellent for defining a system. Instead of solving these differential equations for explicit form, numerical methods may be applied. Numerical methods are often used for computer simulations.
Monte Carlo Simulation is another popular method used to explore systems involving large ranges of parameters. Instead of covering the entire range, results at some random points are calculated to represent the results over the entire range. Some examples of Monte Carlo simulations will be presented.
Some years ago, one of us taught a course Application of Computers in Chemical Problem Solving. Programs have been written to illustrate animations and simulations, and we will outline some of these projects.
Scientific investigations model nature under some limited conditions. Nature is complicated, ant it has many rules and parameters. Few people agree if we consider Nature as a complicated simulator, but there are many similar aspects between a simulation and Nature. Despite the many laws discovered and validated in the past, there are still more to be explored or discovered. Of course, building a simulator of Nature is impossible, because we still do not have all the rules or laws. However, by putting in as many rules as possible, many computer simulations have been built to predict the results under a set of conditions.
A simulation incorporates one or more rules to define a model. These rules apply within some limited conditions. Thus, a simulation is a good model for exploration or learning. Unfortunately, most educators create simulations as a hobby, we lack the expertise or time to construct sophisticated models.
In this paper, we present some simulations that have been used in general chemistry. We recognize their limitations, but we have had the pleasure in their creation, and they have delighted some students. A few Java applets are included to illustrate their potential. These applets are preliminary, because we have not had much experience in using Java to write simulations.
The first step to create a simulation is to define an appropriate system and collect the theories governing the changes in it. The foundation of the system is built on well-tested theories.
A simulation for teaching general chemistry is usually based on a few theories in the domain of this level. Perhaps the major attraction in these simulations is a lively visual effect to teach these theories. When creating a computer simulation, we plan to present the theory more attractively than those using words, equations, tables, and graphs. To achieve this goal, however, depends on many factors.
Changes in nature are usually continuous, but quantities in computers are discrete. The digital representation of quantities often causes problem for the simulation of physical and chemical changes. Special conditions have to be imposed in the program for meaningful results.
There are many books regarding computer simulations, and we list three (1, 2 & 3) for general guidance. We follow some typical steps for our creation of simulations:
Among these types, we choose to model the conversion from A to C via an intermediate B as indicated below.
A ---^{ka}---> B ---^{kb}---> C |
---|
where k_{a} and k_{b} are rate constants for the indicated steps. These models apply to the kinetics of consecutive radioactive decays, and also to an isomeric conversion with an intermediate. In the case of decomposition to produce two products, C represents the amount of one of the products.
For simplicity, we consider both steps follow a first order mechanism, and the differential equations for the chemical kinetics are:
dA - ----- dt | = k_{a} A | |
---|---|---|
dB - ----- dt | = k_{b} B - k_{a}
A | dC = ----- dt |
These are the rules that govern the changes of the system. Rate constants k_{a} and k_{b} are independent variables. Furthermore, we assume the system starts with an initial amount of A, and for simplicity, the initial conditions are restricted. A more sophisticated system allows the user to set up an initial amount of A and B. Quantities A, B and C are evaluated by numerical methods (4, 5 & 6) in the Java program. The italicized letters denote the amounts of the various species. A more complicated simulation can include the order of the reactions to be different from the first order.
In this simple simulation, the user may choose any combination of values for k_{a} and k_{b}. When the values are chosen, the amounts of A, B, and C vary as functions of time. A bar graph shows the variations of the amounts as the functions are plotted.
There are many different ways to present the results for each simulation, but a choice has to be made. The present choice is somewhat academic, because the plots require additional interpretation.
If a definite set of instructions is given, students will simply follow the instructions. Thus, we suggest some questions for the students to answer as they explore the simulation. It will be interesting to ask students to write a report to discuss how they have used the simulation if the class is small.
We have used this simulation to demonstrate how the intermediate B varies as the ratio of the two rate constants change, but there are other applications. We will be interested in knowing how you might use it.
We have also written a simulation to show the variation of reactants and products using random rate constants and order of reactions. The object of this simulation is for the user to figure out the order and the rate constants. Some aids were built in. For example, by pressing certain keys, the user can plot diagrams to figure out the order of the reactions. Evaluation of the rate constant is easy.
For real gases, the van der Waals equation provides a slight improvement in predicting the gas properties compared to the ideal gas law. However, both the ideal gas law and the van der Waals equation work well only for some ranges of temperatures and pressures. Few students at this level paid much attention to the limitations. An interesting exercise is to ask them to find out the limitations of a simulation for the modelling of real gases. In this simulation, some conditions will result in negative pressures, meaningless quantities.
In this simulation, the properties of helium are given as the default. Please change the gas from helium to a different gas to begin, because for some unknown reason, the simulation from the default at the start does not give the desirable results. On the other hand, once a different gas has been chosen, the simulation works fine. This error may be caused by a bug in Java or the Netscape 4.6 browser. The user can investigate a gas by changing the amount in moles, the volume in L and the temperature in K. The simulation gives the pressures calculated according to Model A and Model B.
We will develop a more sophisticated simulation, but in the time frame we have, this preliminary version is included here.
The wavefunctions of molecular orbitals of H_{2} can be a linear combination of atomic orbitals (LCAO) of the two hydrogen atoms in the molecule. Utilizing appropriate normalizing factors, the bonding orbital is the sum of two 1s atomic orbitals, whereas the antibonding orbital is the difference of the atomic orbitals. The electron density is proportional to the square of the wavefunctions.
To calculate the electron density throughout the entire space is time consuming, and impractical even if a very coarse grid is chosen. However, we can randomly (the Monte Carlo method) choose points in the space of interest to us and evaluate the square of the wavefunction. The program actually places a dot at that point in the 2-dimensional space if a random value is greater than the probability. Thus, the density of the dots is proportional to the electron density of the orbitals.
Since the points are randomly chosen, it takes very little time to plot many dots to fill the entire plane. Since the dots fall randomly on the plane, the actual plotting is very interesting to watch. It is particularly impressive to plot the dots in a dark room with light blue dots. A plot resembles a clear night sky.
In this simulation, symmetry of the wave functions is assumed in plotting the dots, but electron density does not have to follow the symmetry. The presentation is a matter of choice.
The effect of this type of simulation depends on the computer speed. When we first execute a version of this simulation, we adjust the speed of plotting to make watching the plot rather interesting. When the same version is executed later in fast computers, the dots are plotted too fast to be interesting.
In this Java applet, we limit the number of dots plotted. Otherwise, the dots will cover the entire window in little time.
Since downloading a file is much more trouble than browsing it on the screen, only a few programs that require no additional data files are included for those who are interested.
when one of the reagent is in excess. For a seasoned chemist, this animation is trivial, but atomic science is stressed in this simulation.
k_{f} A ¬® B k_{b} |
---|
with a forward and a backward reaction rate constants, k_{f} and k_{b}. In this version, any value is accepted for these rate constants, including negative ones. The strategy for this type of simulations has been discussed in Chemical Reaction Simulations earlier.
Few students while taking general chemistry have said much about the simulations or animations. However, a few senior students plus some graduates have commented that they appreciate having seen the simulations. As they mature, they appreciate the amount of work in making the simulations. Today, students are familiar with computers, and they probably are not excited by simple simulations.
Computer simulations are used for education, problem solving, and prediction of natural phenomena. These simulations involve many theories and parameters, and their calculations are very complicated. For example, H. M. Bell at Virginia Tech has written PC software for NMR, radioactive decay, and IR simulations. A Compilation of Educational NMR Software collected by P. Lundberg gives many sites that have NMR simulations. Overview of interactive programming methods for the World Wide Web by B. M. Tissue includes simulations using JavaScript and Java applets. A search on the Internet usually results in many links related to simulation.
There are many different ways to make up simulations and animations. D.E. Mencer's Internet site gives simulations made up using forms on the web page and scripts on the server. He has discussed this aspect in his paper: Developing and Implementing Web-based Computer Simulations for In-Class, Individual, and Small Group Work (Summer 2000 CONFCHEM, Paper A-1). Students' usage can be monitored with scripts in the server for this type of implementation.
Animations and simulations have been made up using Macromedia Director by B. Pankuch, who has presented some of these in his paper: Why use animations and simulations? (Paper A-3) The extensible markup language XML is on the horizon for simulations. Some examples of its application can be found in the MoDL tutorial. We have attempted these options, but we have yet to implement any animation or simulation using these technologies.
Java applets are suitable for course Internet sites. We have An Internet Site for General Chemistry for many years, and we are planning to add Java applets to some of the pages. Java applets are now widely accepted by most browsers. However, the computer technology changes rapidly, and we work hard at catching up. The dependence of simulation on technology is a discouragement for us, because by the time we have caught up, the situation is again different. However, change is the invariance of life, and we have accepted it.
E-mail: cchieh@uwaterloo.ca