Introducing Colorimetric Analysis with Camera Phones and Digital

Aug 9, 2013 - Introducing Colorimetric Analysis with Camera Phones and Digital Cameras: An Activity for High School or General Chemistry. Eric Kehoeâ€...
0 downloads 6 Views 3MB Size
Activity pubs.acs.org/jchemeduc

Introducing Colorimetric Analysis with Camera Phones and Digital Cameras: An Activity for High School or General Chemistry Eric Kehoe† and R. Lee Penn*,‡ †

Janesville Waldorf Pemberton High School, Janesville, Minnesota 56048, United States Department of Chemistry, University of Minnesota, Minneapolis, Minnesota 55455, United States



S Supporting Information *

ABSTRACT: A common task in chemistry is the determination of concentration of unknown compounds. The Beer− Lambert law, also commonly referred to as Beer’s law, enables the quantitation of the concentration of an absorbing analyte in solution. Results from experiments using solutions of blue food dye, lemon−lime sports drink, and iron(III) chloride demonstrated that absorbance versus concentration data are linear for data collected using digital cameras and camera phones. The key to obtaining reliable data is collecting a single image of samples, standards, and blanks arranged in front of a uniform light source, such as a light box or a computer screen. The approach provides a facile method for performing colorimetric analysis in a wide range of settings, from the high school chemistry laboratory, in the field, and the research laboratory. KEYWORDS: High School/Introductory Chemistry, First-Year Undergraduate/General, Analytical Chemistry: Laboratory Instruction, Physical Chemistry, Hands-On Learning/Manipulatives, Dyes/Pigments, UV−Vis Spectroscopy

A

used a cell phone charge-coupled device to quantify an ovarian cancer biomarker, HE4, in urine.4 Here, we report the results from experiments using several different absorbing analytes (food dye, sports drink, and iron chloride) and demonstrate a large range of concentrations over which the absorbance versus concentration data are linear by data collection using various makes of digital cameras and camera phones. Then, we present an inquiry-based activity that can be implemented in a high school or university chemistry setting.

common task in chemistry is the determination of concentration of a particular analyte. The Beer−Lambert law, also commonly referred to as Beer’s law, enables a chemist to quantify the concentration of an absorbing analyte. In general chemistry laboratories at both the high school and university levels, Beer’s law is commonly employed to calculate concentration from an experimental measurement of absorbance or determine the molar absorptivity for a dissolved compound of known concentration. For example, Pringle et al. developed a lab using crepe paper, which is commonly used at K−12 school events, to introduce the concept of quantifying concentration using Beer’s law.1 Absorbance is commonly measured using instruments such as a Spectronic 20 (Spec 20), a UV−vis light spectrometer, or colorimeter that can quantify absorbance at a single wavelength. Many high school labs do not have adequate access to such equipment. However, many high school students have access to quantitative equipment that can achieve sufficient precision and accuracy for quantitation of the concentration of colored compounds: digital cameras, including those contained in handheld devices like IPads and mobile phones. Implementation of an accessible and inexpensive method for colorimetric analysis was described by Liebhafsky and Winslow in 1950, and their device, built using an incandescent light bulb, a graduated cylinder, and other objects, was used to quantify dissolved iron and copper in water.2 In 2004, Mathews et al. reported results using a desktop scanner to quantify the concentration of a starch−iodine complex using scanned images of solutions in well plates.3 A particularly compelling and recent example is the work of Wang et al., in which they © 2013 American Chemical Society and Division of Chemical Education, Inc.



EXPERIMENTAL DETAILS The analytes were the following, commonly available, colored substances: Gatorade instant powder dry mix energy drink, lemon−lime flavor; blue food coloring solution (Market Pantry, Target Corporation); and iron(III) chloride hexahydrate (Sargent Welch, reagent grade). Each substance was dissolved into water, using distilled, deionized, or tap water. The source of water did not influence the quality of the results. Serial dilutions were performed to obtain solutions ranging from “full strength” to as dilute as 0.3% of the stock solution concentration. The serial dilutions were performed using autopipets or simple graduated cylinders, depending upon the equipment available. Either standard glass test tubes or plastic cuvettes (Flinn Scientific, Inc.), with path lengths of 1 cm, were used. In the case of the blue food coloring, each solution was volumetrically added to the cuvette by way of an auto pipet, and images were collected from the side (perpendicular to the Published: August 9, 2013 1191

dx.doi.org/10.1021/ed300567p | J. Chem. Educ. 2013, 90, 1191−1195

Journal of Chemical Education

Activity

square walls) as well as from the top (parallel to the square walls). Solutions were arranged in front of (or on top of, in one case) a Flinn light box (Flinn Scientific, Inc.), and images were collected using a Spectronic 20, a digital camera (Casio Exilim or a Nikon Cool Pics L120), or a Samsung Galaxy SIII phone. With a distance of 50 cm between the lens of the camera and the front of the samples (for 14 square cuvettes arranged sideby-side in front of the light source), the variation in path length of the outermost samples versus the center two samples is 1.0%. Thus, a distance of 0.5 m or more should be employed so as to minimize systematic error introduced by slight differences in path length. The key element to obtaining reliable data is arranging all solutions, including blanks and unknowns, in a single image. Absorbance values were obtained from the digital images by first measuring the RGB (red, green, blue) values (on a scale of 0−255 in intensity) of the samples using either ImageJ, Adobe Photoshop, or Image Color Picker (Android Application v2.4 by GITS Indonesia). Either single pixels were selected, or average RGB values were determined for multiple pixels. In Photoshop, the value was determined by single-point analysis. ImageJ (v1.43u) is an open-source image processing and analysis program written in Java by Wayne Rasband at the U.S. National Institutes of Health.5,6 With ImageJ, a rectangle covering the majority of the uniform color within each cuvette (ca. 0.9 cm by 2.0 cm in size) was used to determine each value. Then, the plugin titled RGB Measure was used to determine the mean R, G, and B values for the pixels contained within the rectangle. Alternatively, the Analyze−Histogram command can be used to generate the means or modes of the R, G, and B values for the pixels contained within each of the selected areas. With Image Color Picker, three different points were selected for analysis, and the value plotted was the average of those three values. For a discussion on the conversion of RGB values to wavelength, the reader is referred to Williams et al.7 and on the use of digital cameras for accurate assessment of color, which includes a discussion of using appropriate standards, to Wu et al.8 Finally, differences observed in the absolute RGB values is simply a consequence of the algorithm employed by the software packages. Each of the three approaches produced excellent results, and any software package that can determine RGB values of individual pixels or average RGB values of multiple pixels is expected to produce similar results. Absorbance (A), which is the negative log of the transmittance (In/Iblank), was then calculated using the following formula:

A = −log(In/Iblank )

Figure 1. Image of solutions prepared using the blue food coloring, collected using the Casio Exilim digital camera with the solutions either arranged in front of (A) or on top of (B) the light box. Each 1 cm path length cuvette contains 2.50 mL of each solution, delivered by autopipet.

ImageJ or Adobe Photoshop, were prepared, and the data were fit using a linear regression (Figure 2). The coefficient of determination, R2, values were all greater than 0.98. In addition, data collected using the Spec 20 are shown in Figure 3, and the R2 value is similar to those calculated using the data obtained via digital camera. The data shown in Figure 3 were collected using a wavelength of 635 nm, which is red and was chosen because it is one of the wavelengths commonly available on inexpensive three-wavelength colorimeters. The data shown in Figure 2 correspond to the green values of RGB. The red channel analysis using ImageJ and Photoshop failed to produce useful results because the red values dropped to zero for concentrations greater than 4% of the stock solution concentration. In addition, a grayscale analysis was attempted, but the data were not linear. This experiment demonstrates that simple RGB analysis of images collected using a digital camera produces suitably quantitative data.



COMPARING DATA COLLECTED USING A DIGITAL CAMERA OR A CAMERA PHONE A major goal of this work was to make this experiment even more accessible to the high school laboratory. Thus, images of sports drink solutions were collected using a camera phone (the Samsung Galaxy SIII phone). The cropped, but otherwise unmodified (the uncropped image is in the teacher notes in the Supporting Information), images collected using the camera phone or the Nikon digital camera are shown in Figure 4, and the absorbance versus concentration plots are shown in Figure 5. In Figure 4, the upper image shows substantial horizontal banding, which was observed in all images of solutions backlit by the fluorescent bulb light box and collected by camera phone (regardless of make). However, backlighting the solutions is necessary for quantitation. When the data are collected from regions outside the dark horizontal banding in the camera phone images (i.e., between the black lines shown on the upper image of Figure 4), results are quantitative and reliable. As with the data presented for the solutions of blue food coloring, this experiment demonstrates that simple RGB analysis of images collected using a camera phone produces suitably quantitative

(1)

in which In denotes the R, G, or B value for the sample and Iblank the R, G, or B value for the blank, both obtained from the experimental image. Finally, plots of absorbance versus “concentration” were prepared and evaluated for linearity and used for determining concentrations of unknown solutions.



COMPARING DATA COLLECTED USING A DIGITAL CAMERA OR A SPECTRONIC 20 The first experiment employed the blue food coloring and the Casio EXILIM digital camera or a Spec 20 (Figure 1). Concentration ranged from the stock concentration, which was prepared by adding a drop of the food coloring to 25 mL of water, down to a concentration that was 0.3% of the stock concentration. Plots of absorbance, which were quantified using 1192

dx.doi.org/10.1021/ed300567p | J. Chem. Educ. 2013, 90, 1191−1195

Journal of Chemical Education

Activity

Figure 2. Plots of absorbance versus concentration as determined by point sampling (open squares, Photoshop) or area sampling (gray circles, ImageJ) analysis of the green values from the images shown in Figure 1A (side view) or Figure 1B (top down). Note that the highest concentration was excluded from the top-down plot due to deviation from the expected linear relationship between absorbance and concentration.

Figure 3. Absorbance versus concentration of the blue food coloring solutions. Absorbance was measured using a Spec 20 with a wavelength of 635. The data deviated from linearity at the highest concentration.

Figure 4. Images of the sports drink solutions arranged in front of the light box and collected using the (A) camera phone or (B) Nikon digital camera. The horizontal banding observed in the upper image is likely the result of interference between the frequency of the fluorescent light in the light box versus the collection time of the camera phone. This effect was observed in all images collected using camera phones when a fluorescent bulb light box was employed. The added black line serves to highlight the region of the image from which the RGB measurements were made. The cuvette on the right-hand side contained a solution of “unknown” concentration.

data. In addition, the free application, Color Picker, provides a convenient and quantitative analysis of the images.



ADEQUATE RESULTS WITH SOLUTIONS IN ROUND TEST TUBES Finally, a series of iron(III) chloride solutions was prepared and loaded into test tubes (inset in Figure 6) to test whether the data collected could be suitably quantitative. Analysis of the images of these solutions produced data that was suitably quantitative for colorimetric analysis (Figure 6). However, a key aspect is to perform the analysis in the center of the image of the test tube to ensure that the same path length is used for each measurement and to avoid any glare from the surface of the glass. However, even with those challenges, the test tubes worked adequately. This demonstrates that the method can be applied even with less than ideal laboratory equipment. However, the square cuvettes give consistently better results.

class period is used to explain the lab and for students to prepare their solutions and to take the photo. In the second class period, the students are told how to analyze the image and do it. The students prepared solutions that appeared similar to those shown in Figure 4 and determined the concentration of an unknown solution provided by the teacher. The students used imageJ to gather the color channel values and then used Microsoft Excel to turn the values into absorbances and graph them. The average concentration over nine groups was 0.10 g/ mL (st. dev. 0.04) with only two significant outliers. Students used simple graduated cylinders to prepare solutions and a variety of camera phones and digital cameras to collect images. On the basis of examination of the student data, the most



CLASSROOM ACTIVITY Colorimetric analysis of sports drink solutions was performed by ∼20 high school students, divided into groups of 2−3 students. The activity took two 50-min class periods. The first 1193

dx.doi.org/10.1021/ed300567p | J. Chem. Educ. 2013, 90, 1191−1195

Journal of Chemical Education

Activity

Figure 5. Plots of absorbance versus concentration of the sports drink solutions determined using (A) a Galaxy SIII phone and Color Picker with blue values from the image shown in Figure 4A and (B) a Nikon camera and ImageJ with blue values from the image shown in Figure 4B.

There are a few important considerations. First, data should be collected from single images of all solutions (standards, the blank, and unknowns). Second, the quality of back lighting is important. A possible improvement would be arranging samples and standards in front of an LCD display showing only white (e.g., displaying a simple white slide). This would provide a useful way for students to produce professionallooking labels for each sample as well as provide an opportunity to test lighting alternatives, such as using a colored slide in the background (e.g., see Supporting Information for a description of using a blue versus white background for methyl orange solutions). Using a background color that is the complement to the observed solution color should produce the most quantitative results. If the wavelength of the absorption maximum for a particular solution is known, then a background prepared using the R, G, and B values corresponding to that wavelength is expected to produce the most quantitative results. Finally, this method can be applied to a wide range of laboratory settings, both in research and in education. The recent example of Wang et al., in which they used a cell phone charge-coupled device to quantify an ovarian cancer biomarker, HE4, in urine4 is one such example. One can envision implementation of camera phones and digital cameras for quantitative colorimetric methods such as the ferrozine method9 for quantifying dissolved iron(II) in aqueous solutions. This method is commonly employed in environmental chemistry and geochemistry. In addition, there are dozens of colorimetric methods used for the quantitation of various species in water and wastewater, such as the standard colorimetric methods for quantifying chemical oxygen demand, chlorine, arsenic, phosphorus, nitrate, and more.10 Any of these methods could be readily adapted to use camera phones for the colorimetric analysis steps, which could make such methods more easily implemented in teaching laboratories (e.g., ranging from general chemistry to organic chemistry to water and environmental chemistry) as well as in the field.

Figure 6. Plot of absorbance versus concentration for the solutions shown in the insert and analyzed using ImageJ. The inset shows the image of acidic iron(III) chloride solutions in test tubes, arranged in front of the light box and collected using the Casio digital camera. The solution in the left-hand test tube is 0.10 M FeCl3.

probable explanation for the two outlier data points is dilution or computation errors. The student handout is available in the Supporting Information.

■ ■

HAZARDS There are no hazards associated with this activity. DISCUSSION High school students were able to collect quantitative colorimetric data of solutions of colored substances using common handheld devices such as digital cameras and camera phones. The data demonstrated that the method is suitably quantitative for an instructive lab exercise using using Beer’s law to calculate concentration from colorimetric data. A wide range of colored substances of interest to students, such as beverages or water-soluble dyes from crepe paper,1 can be employed. Furthermore, the data collected were of suitable quality for quantitative analysis, regardless of the brand or style of camera employed. The above experiments pose no safety concerns, and the supplies are inexpensive and procedures easy to perform for students of nearly any age.



ASSOCIATED CONTENT

S Supporting Information *

A student handout; notes for the teacher. This material is available via the Internet at http://pubs.acs.org. 1194

dx.doi.org/10.1021/ed300567p | J. Chem. Educ. 2013, 90, 1191−1195

Journal of Chemical Education



Activity

AUTHOR INFORMATION

Corresponding Author

*E-mail: [email protected]. Notes

The authors declare no competing financial interest.

■ ■

ACKNOWLEDGMENTS We acknowledge the National Science Foundation for financial support (NSF-0957696). REFERENCES

(1) Pringle, D. L.; Chaloupka, K.; Varankamartin, M. J. Chem. Educ. 1995, 72, 722−723. (2) Liebhafsky, H. A.; Winslow, E. H. J. Chem. Educ. 1950, 27, 61− 62. (3) Mathews, K. R.; Landmark, J. D.; Stickle, D. F. J. Chem. Educ. 2004, 81, 702−704. (4) Wang, S. Q.; Zhao, X. H.; Khimji, I.; Akbas, R.; Qiu, W. L.; Edwards, D.; Cramer, D. W.; Ye, B.; Demirci, U. Lab Chip 2011, 11, 3411−3418. (5) Abramoff, M.; Magalhães, P.; Ram, S. Biophotonics Int. 2004, 11, 36−42. (6) Rasband, W. S. ImageJ User Guide, 1st ed.; National Institutes of Health: Bethesda, MD, 1997. (7) Williams, D. L.; Flaherty, T. J.; Jupe, C. L.; Coleman, S. A.; Marquez, K. A.; Stanton, J. J. J. Chem. Educ. 2007, 84, 1873−1877. (8) Wu, W.; Allebach, J. P.; Analoui, M. J. Imaging Sci. Technol. 2000, 44, 267−279. (9) Stookey, L. L. Anal. Chem. 1970, 42, 779−781. (10) Eaton, A. D.; Clesceri, L. S.; Greenberg, A. E., Eds. Standard Methods for the Examination of Water and Wastewater, 19th ed.;American Public Health Association, American Water Works Association, and Water Environment Federation: Washington DC, 1995.

1195

dx.doi.org/10.1021/ed300567p | J. Chem. Educ. 2013, 90, 1191−1195