Simulation of chemical instrumentation. I: Computer-graphics

Northern Arizona University, Flagstaff, AZ 8601 1. The emulation of instrumentation by interactive com- puter-graphics is proposed as one approach in ...
2 downloads 0 Views 3MB Size
computer mrief. 31 This month's Comnuter Series consists of two senarate articles, each of which describes a simulation of an instrument or results obtainable from an instrument. Rroad amlication of techniques like those described here could providevaluable experience with up-to-date instrumentation to students in many departments of chemistry who cannot afford the latest model of every important type of instrument.

edited by MOORE Eastern Michigan University. Ypsiianti. Mi 48197 JOHN W.

( W ; )and wavelength of maximum absorbance of each peak (Pi). Absorhances are computed for 250 wavelengths (xj) beginning with the longest wavelength. Lorentzian and gaussian functions3, eqns. (1)and (21, are used to calculate their respective contributions, L, and Gj, to the absorbance a t the jth wavelength.

Computer-Graphics Emulation of Chemical D. D. Gilbert, 1.1.Mounts 11,' and A. A. Frost2 Northern Arizona University, Flagstaff, AZ 8601 1

The emulation of instrumentation by interactive computer-graphics is proposed as one approach in chemical education to give students a well-rounded instrumental methods course in a time of smaller budgets, spiraling inflation, and rapid growth of instrumentation technology. This report describes an interactive computer-graphics program which emulates the behavior of a high resolution ultraviolet-visible, analog recording spectrophotometer. The graphics terminal behaves as though it were a recording absorption spectrophotometer. The instructional objective of the emulation is the study of the optimization of the instrument to yield accurate absorption spectra, including the effects and interrelationships of spectral band width (SBW), wavelength scan speed (SS), and a recorder pen period (PP). Graphics Software, Operating System Fortran IV is the source code with subroutine calls to the Tektronix Terminal Control System (TCS) software package for the graphics. The program is transportable only if the Tektronix package is available to the user. The program is used with a Xerox Sigma 6 computer with a CP-5 operating system. The code includes some INPUT and OUTPUT instead of READ. WRITE. FORMAT statements. The graphics terminal used in this appllration is a Tektronix model 4010 which has a viewable rrsolution nf 1W1 X 780 (X,Y) units. Communication rates between the terminal and central computer are either 300 or 1200 baud, with the latter, faster transmission rate preferred.

The total absorbance (Aj) a t the jth wavelength is then obtained by summing the two functions with a weight of 70% lorentzian (LORFR) and 30% gaussian, eqn. (3). As each point is computed, it is plotted and connected by a straight line to the preceding point. The resulting curve is displayed within previously drawn axes as the Resolved Spectrum, Curve A, Figure 1.Curve B is generated and plotted using functions which relate peak height, width, and position t o a predefined set of the operating parameters of spectral band width, scan time, and pen period. Curve C is generated after the user specifies values for the operating parameters. The user is given the option to stop or continue. If the latter option is chosen, the screen is erased and only the RESOLVED CURVE is displayed before the user is queried for a new set of conditions. Spectrophotometer Parameters There are well-established relationships between spectrophotometer parameters and spectrum characteristics4. The effect of s ~ e c t r a bandwidth l on a sDectrum is instrumentindependent and is chosen as the parameter to be specified in the program rather than the mechanical slit width, which is instrument-dependent. The rrlationship hetwem the slit width and its corresponding snectral bandwidth is found in a user's instrument ianuai: -

General Algorithm The specifications for an arbitrary, resolved spectrum are assigned in the program: baseline ( B ) ,number of peaks (P), . starting wavelength, range of wavelengths, height (absorhhalf-width a t half-heieht of each peak ance) of each neak (H;), Presented in part at the 198th American Chemical Society National Meeting. Atlanta. GA. March 1981. ' Present address: Cities Service Company, Box 300. Tulsa. OK 74102.

Professor Emeritus, Northwestern University; Adjunct Professor, Northern Arizona University. "Software System User's Manual-Lab 8/e," Digital Equipment Corporation, Maynard, MA 01754. p. S-I. "Optimum Spectrophotometer Parameters." Varian Instrument Division, 61 1 Hansen Way. Palo Alto, CA 94303.

UYLLEYDIll

llllOlETSR81

Figure 1. Initial Screen. Curves A and Baredisplayed.lhe u~erspecities values to be used lor Curve C. The program waits far each value afler the respective question marks.

Volume 59 Number 8 August 1982

661

,mm/mu ~1.1s! ql8ualaaem s!ql l a luamnqsu! aql JO uo!srads!p aq& .mu 099 78 ralamoloqdorpads OLZ'; Tapom wmyaaa E q l ! ~pau!mralap aiam 't alqe& u! ua44 ' s a n p lasuo aq& 'as!ou JO lasuo aql IOJ sqlp!mpueq p p a d s pue po!rad uad 30 s a n p paymialap Lpluam!radxa~o?as e sasn 'arojaraq$ 'uo!$e[nma aq& ,alqe[!ene )ou am po!rad uad p w qlp!mpueq p p a d s ql!m sla.%a[as!ou loqs Bu!pqar saarn3 .cm " " Z10

a n p e ua@ s! J ralamerad aq& qanpord po!rad uad-paads w a s pue 13!qs aql uaamlaq pamnsse SFd!qsuo!plar ream[ v

01'0 80'0 80'0 P0'0 EO'O

.mu 01lnoqs JO q l p ! ~p w q [ernleu e q l ! ~ '3 amorqagi(a JO p w q - a aq? 2tqm '9qep p$uamyadxa ~ O I pan!rap J s! $ a m Q .dd'popad uad pue 'SS 'paads ue3s aql JO lanpord aql q qq8!aq qead anqlpaarasqo aql jo oqsr aql 'g arn2t.j ur umoqs aama aql

S'o

0'1 0'1 0'b 0'8

IAVELEWOIH

IYLWOYETEOll

Figure 6. Effeet of Spectral Bard width ard Pen Period. At small MlWS fw SBW and PP. shot noise becomes apparent, Curve B. Table 2. Student Calculated Path Lengths of an Optlcal Cell lnshument Chem-Anal Coleman 124

Spectral Bandwidth

Calculated Path Length

nm

cm

20.0 1.0

0.800 1.002 1.010

0.5

1.024

2.0

The noise algorithm is more involved than the others used in the emulation. A test of user-specified pen period and spectral bandwidth values is made to determine if any of the onset of noise conditions are met. If the spectral bandwidth, a t a given pen period, is greater than the onset value, no noise is introduced into the spectrum. If the specified spectral handwidth is equal to or less than the onset value, noise is introduced into the spectrum. A random number for each spectrum is generated and is multiplied by an amplitude factor for a set of given pen period and spectral handwidths. The noise amplitude factor is directly proportional to the inverse of the spectral bandwidth and inversely proportional to the square root of the pen period. Care is taken in the plotting routine to force the noise-containing spectrum to follow the noiseless curve. This is done by forcing the total noise to he zero every 16 points. Example Outputs

Fieures 4 throueh 6 show actual terminal screen c o ~ i e of s the spectra generated by the program. Figure 4 showsihe effect of spectral bandwidth on resolution and absorbance accuracy; peaks are depressed and wider a t larger spectral handwidths. Peaks with more narrow natural bandwidths are more sensitive to spectral bandwidths than those with larger natural handwidths. Figure 5 shows depressed absorbances and spectrum shifts t o shorter wavelengths as a result of faster scan speeds. A similar set of curves are obtained at different pen period. Figure 6 shows the introduction of noise into the spectrum at a pen period of 0.5 second and spectral bandwidth of 0.03 nanometer. Student Use and Comments

The emulation is used in an instrumental methods laboratory by students who have completed work with a singlebeam spectrophotometer, e.g., Bausch & Lomb Spectronic 20 or Sargent-Welch Chem-Anal. Students study the effects of the wavelenzth dependence of detector sensitivitv and source radiaiivr ou.tput. in addition, they determine theerror in the nominal wnvelmath reading of deliberately misadiusted instrument and determine thk path length of an optical cell, using a potassium chromate solution of known concentration and National Bureau of Standards data from which the ahsorptivity of the chromate can be calculated. This latter ex-

ercise is repeated on other instruments a t a total of four different spectral handwidths. Typical results are given in Table 2. The dependence of the path length determination on spectral bandwidth is a lead-in to the emulation program. Students are directed to vary the spectrophotometer parameters of spectral bandwidth, scan speed, and pen period and relate how each one affects waveleneths of maximum absorbance, values of maximum absorbance, spectral handwidths compared to the natural bandwidths,. sianal - to noise ratios, and instrument time required to obtain spectra. After com~letinathe emulation exercise, students use a Beckman model 5270 absorption spectrophotometer to obtain an "optimized" spectrum of an unknown substance. Students report that the various spectrophotometer controls are readily understood and instructon observe that very little instruction need be given the students for them to operate the instrument. Students react very positively to the rapidity of learning with the graphics-emulator rather than the slower instrument itself. The rapidity of a graphics emulator is very important for this work as well as any extensions to other instruments. At 1200 baud a snectrum is eenerated and disolaved within 5 s. using a ~ e r o x ' ~ i ~6mtime a share system. hist time increases if the svstem resnonse time is ~ o o rA. microcom~uterstandalone system is not communication-rate limited, but the execution time to calculate and display a single spectrum with an 8-hit microprocessor may increase to 57 sec or longer. If a student must wait for more than 30 sec for a spectrum, the emulation may lose its effectiveness. Spectra have been generated with a 16-hit microprocessor system within 6 sec. I t is believed that screen resolution can he sacrificed to a greater extent than execution time and still have an effective emulation system.

A Program for the Synthesis of Mass Spectral Isotopic Abundances Marllyn L. Brownawell and Joseph San Fillppo, Jr. Rutgers University, New Brunswick, NJ 08903 Medium- and low-resolution mass spectrometers are capable of resolving ions with ma~s-to-ch&~e (mle) values that differ by 0.01-1 mass unit. Under such resolution, a molecular or fragment formula cannot be determined from m/e values alone. However, such formula assignment frequently can he accomplished by the method of isotopic ahundances as described below.' Since each ionic species produced in a mass sprctromrtrr is normally observed as a cluster of peaks, the intemitv ratlo of these peaks is uniquely characteristic of the iskopic abundance ratios of the elements that comprise the particular ionic species. Thus, for example, the stable carbon isotopes of natural abundance are 12C (98.9%) and 13C (1.1%). If the peak containing all 12Catoms is designated M+, then the peak in which one 12Catom is replaced by a '3C atom must he the ( M I)+ peak. In the absence of interference from isotones of othe; eiements, the intensity ratio of the M+I(M + i)+ peaks will depend on the abundance ratio of 12C/'3C and on the number of carbon atoms present. Using the isotopic abundance ratio and the peak intensity ratios, the numher of

+

' The computation of either the molecular or a frabment ion cluster Obsewed in the mass spectrum of a poiyisotopic substance has been stlldied fw some time. (See Sukharev, Yu. N., Sizoi. V. F.. and Nekrasov. Yu. S., Org. Mass Spec.. 16, 23 (1981)andreferencestherein.)Early anempts to address this problem had the disadvantage of being limited in scope and in particular did not permit the calculation of isotopically enriched substances. Volume 59 Number 8 August 1982

663