Multiple-output multivariate optical computing for spectrum recognition

: We describe a multivariate optical computer that can implement multiple spectral ﬁlters simultaneously. By parallel detection of multiple outputs, our proposed approach is capable of identifying more than two spectra simultaneously, and therefore could signiﬁcantly speed up spectrum recognition based on optical computing. We demonstrate our approach by recognizing two rare-earth-doped glass samples and a third white light sample spectrum with a ﬁdelity of at least 0.83.

At the heart of a multivariate optical computer (also MOC) is a device that performs a spectral correlation.This device is called a spectral matched filter or multivariate optical element.The spectral matched filter can consist of a fixed wavelength-selective element, such as a thin-film interference filter [1,2] or a custom holographic grating [4][5][6][7].But a more common approach to spectral processing is to disperse the light spatially, using a grating or other element, and then use spatial manipulation to process the spectrum [19].Frequently, the spatial processing is implemented using a liquid crystal spatial light modulator (SLM) or digital micromirror device (DMD) for programmability [9][10][11][12][13][14][15]20].Closely related techniques have also been proposed for use in hyperspectral imaging [3][4][5][21][22][23][24].
In the SLM-and DMD-based MOC experiments reported thus far, only one spectral matched filter has been implemented at a time (although it has been suggested that some methods might be able to implement multiple filters [12]).However, many applications require identification of more than one chemical in a single sample, such as testing for multiple contaminants or measuring concentrations of multiple constituents of a mixture.In a traditional MOC, this is achieved by applying each matched filter sequentially to a single sample.But in some MOC implementations (such as fixed holographic filters or some spatial light modulators), changing the spectral matched filter is slow and adds complexity to the system.These factors can increase the total time needed to perform the spectrum recognition operation for multiple chemicals, negating some of the advantage of a MOC.
We describe here a MOC with a unique optical configuration that allows us to implement multiple filters simultaneously, by having the SLM direct light toward multiple detectors (multiple outputs).We use two methods for implementing multiple simultaneous filters on the SLM, and we demonstrate these methods using two simultaneous filters and two detectors.Three different sample spectra are generated, using a white light source with no sample, a glass sample doped with didymium (a combination of neodymium and praseodymium), or one doped with holmium.These three sample spectra are then recognized using our MOC, and the results are presented below.

Theory
Spectral matched filtering, or spectral correlation, is the fundamental optical computation performed by a MOC.Assume a sample spectrum s j to be one of N S different spectra, each representing a different chemical or biological substance to be identified.Conceptually, the spectrum s j is passed separately through each of several different matched filters a k , which are implemented on the SLM.The total transmission through each filter is equal to the correlation c j,k of the filter's spectral response and the sample spectrum Here, lowercase italic letters represent scalar quantities, lowercase bold letters represent column vectors, uppercase bold letters represent matrices, discretized spectra and filters are represented as N-element vectors, and correlation is written as the inner product.Ideally, one would like to use filters that positively identify only a single chemical and no others, i.e., where δ j,k = 1 if j = k and 0 otherwise (the Kronecker delta).If the sample spectra and filters are written as rectangular matrices S = s 1 s 2 . . .T and A = a 1 a 2 . . ., then the ideal response for the spectrum recognition task is where C is a correlation matrix whose elements are c j,k ( j is the column index, and k is the row index), and I is the N S × N S identity matrix.Assuming the spectra that make up the rows of S are linearly independent, there are many possible matrices A that satisfy Eq. (3).One solution is found using the Moore-Penrose pseudoinverse S + of S, which has the property that Left-multiplying Eq. (3) by the pseudoinverse yields Substituting Eq. ( 4) gives In other words, the ideal filters a k for a spectrum recognition operation are given by the pseudoinverse of the target spectra.It has been shown previously that the correlation values produced by these filters are in fact proportional to the molar concentrations of the various chemicals in a sample spectrum [12], and that the optical-depth-dependent broadening of an absorption spectrum's lines can be compensated in a straightforward way [2,25].It is intriguing to note that any right inverse of S will satisfy Eq. ( 4) and produce filters with the desired response C = I, but this topic is not explored further here.
The matched filters a k consist of real numbers, both positive and negative, of any scale.But the SLM can only implement reflectances (matched filter values) between some minimum and maximum.As is common, we separate the positive and negative values into two half-filters and scale them to the SLM reflectance ranges; we then scale the measured results by the reciprocal factors and subtract the negative result from the positive result to produce the final spectral correlation value.
Define two half-filters a + k and a − k containing respectively the positive and negative elements of a k , such that the elements of each half-filter are Then Next, find the maximum value for each half-filter where the ± symbol represents either sign.Finally, define the scaled half-filters The scaled half-filters b ± k have values on a scale of zero to one and can be implemented on the SLM.
When the spectrum s j illuminates the SLM, the power arriving at the detector can be expressed as The vector r represents the SLM reflectance, normalized to a scale from zero to one.When all elements of r are zero, the power measured is the background power P j,bg .(Each sample spectrum has a different background power, hence the j subscript.)To compute the correlation coefficient c j,k for a spectrum s j and a filter a k , a series of three measurements must be made.First, the background power P j,bg must be measured.Next, P + j,k and P − j,k must be measured, by setting r = b + k and r = b − k , respectively.Finally, the correlation coefficient is computed as follows: It is straightforward to show that this c j,k is equal to the one defined in Eq. ( 1).Thus, the spectral correlation of s j with a k can be computed using only three measurements and a simple calculation.
The elements of s j (the spectral powers of sample spectrum j) can be recorded by performing a spectral scan, as follows: First, the background P j,bg is measured.Next, each of the elements of s j is measured, by setting r first to 1 0 0 . . ., then to 0 1 0 . . ., and so forth.Once the a k have been computed from the s j , spectrum recognition measurements can be made repeatedly and rapidly.
To account for the power fluctuations of the optical source, consecutive readings of the background power P j,bg are fit to a low-order polynomial, and measurements are normalized accordingly.(If faster fluctuations were present, an additional power meter could record the source power in parallel with each measurement.)

Experiment
The experimental setup is shown in Fig. 1.Broadband, incoherent white light exits a fiber bundle and passes through condensing optics, a horizontal polarizer, a sample under test, and a vertical entrance slit, which is followed by a pickoff wedge and a commercial spectrometer that monitors the sample spectrum (Ocean Optics model USB2000).The samples used in this experiment are two glass color filters, one doped with didymium (Thorlabs model FGB67) and one doped with holmium (Edmund Optics model NT66-918); the system is also used with no sample, providing a third spectrum.The optical system projects the sample spectrum onto the SLM (Cambridge Correlators model SDE1024) such that each frequency component fills a column of the SLM.The SLM deflects a controllable amount of light at each wavelength toward two detectors (Newport model 2936-R power meter with dual 918D-SL-OD3R sensors).The detectors are located at different heights in the image plane of the entrance slit (pickoff mirrors are used for convenience, but the optical path length to each detector is the same).Horizontally, the optical system images the slit onto the SLM, a grating disperses the slit images horizontally across the SLM, and the optical system re-images the SLM onto the detectors.Vertically, the SLM is located in the Fourier plane of the optical system, and the entrance slit and detectors are located respectively at the input and output planes.The detected output is an optically computed correlation between the sample spectrum and the spectral matched filter implemented on the SLM.
The SLM pattern consists of a blazed grating in each column.The blaze period controls the tilt angle of the reflected light and thereby determines which detector the light reaches (twopixel period for detector A or five-pixel period for detector B).The efficiency of the blazed grating may be varied to control the amount of light received by the detector.The efficiencies of the SLM columns are represented as the normalized vector r and are used to implement the coefficients of the scaled matched half-filters b ± k .The spectrum recognition operation is performed both using a single output (detector A) and using multiple outputs (both detectors).In the single-output case, the entire SLM implements one matched half-filter b ± k at a time, and detector A takes a measurement for each half-filter.For the multiple-output case, multiple matched half-filters are implemented simultaneously on different parts of the SLM, and each half-filter directs light toward a different detector.
Figure 2(a) shows schematically how the SLM is used for multiple outputs.Light shines on the SLM and is deflected toward one of the two detectors, depending on the blaze period in a given column.(In the experiment, the SLM is actually overfilled, and the incoming light is imaged rather than collimated.) Figure 2(b) shows the same information diagrammatically.
We use two different multiple-filter methods, shown in Figs.2(c) and 2(d).The first, which we call the bipolar method, is shown in Fig. 2(c to any number of non-overlapping spectra (such as narrow emission-line spectra); the limiting consideration is that the output images in the detector plane must be non-overlapping, to keep crosstalk low between different filters.(Some crosstalk is unavoidable, though it is possible that a different SLM modulation technique could reduce the crosstalk slightly.) The second multiple-filter method, shown in Fig. 2(d), is called the multiple-zone method.It consists of dividing the SLM into multiple vertical "zones" (specifically, top and bottom halves).Each zone deflects light toward a different detector.Multiple arbitrary filters may be implemented in this fashion.The multiple-zone method reduces the amount of light reaching each detector, but it can easily be scaled up to more than two simultaneous filters by dividing the SLM into a greater number of zones and placing additional detectors at a variety of deflection angles.If more than enough optical power is available, typically the experimenter would reduce the detector integration time to speed spectrum recognition, but if the integration time is constrained by the apparatus, then implementing multiple zones allows a similar spectrum recognition speedup.The number of filters is limited by detector non-overlap (as with the bipolar method), as well as the available optical power and the number of vertical pixels on the SLM.The multiple-zone method can also be combined with the bipolar method by implementing several non-overlapping half-filters in each zone.Based on empirical observations of the vertical overlap of different filters' optical outputs, if the vertical extent of the input slit were reduced (and assuming sufficient optical power), we suppose that perhaps as many as 10 to 20 matched half-filters could be implemented simultaneously in this way, or possibly more on an SLM with a greater number of pixels.
In general, implementing multiple filters requires dividing the optical power, and then increasing the detector integration time in order to maintain the same signal-to-noise ratio.Under these circumstances, multiple simultaneous filters provide little or no speedup compared to a single-filter MOC (except when switching filters is slow, as noted in the introduction).However, in the case of the bipolar method (or any other combination of filters whose spectra do not overlap), the optical power arriving at each detector is the same as in a single-filter system, since each filter does not make use of the entire input spectrum.Additionally, in some systems the detector integration time is constrained to a certain value or set of values; if excess optical power is available but integration time cannot be reduced, using multiple filters puts the excess power to use and gives a speed advantage.In these two cases, using multiple simultaneous filters is faster even than a traditional MOC that can switch filters quickly.The experiment proceeds as follows: First, the SLM response is calibrated across all wavelengths, using the white light source and a custom calibration procedure.Next, each of three sample spectra is recorded, using the MOC in the spectral scan mode; these three power spectra are the s j .Then the pseudoinverse spectral matched filters a k are computed from these spectra, and from these, the b ± k are derived.Finally, the spectrum recognition operation is performed for each of the sample spectra and each of the matched filters, by implementing the b ± k on the SLM.Spectrum recognition is performed once using a single output and once for each multiple-output method (the bipolar method and the multiple-zone method).

Input
Figure 3 demonstrates a good qualitative match between the spectrum recorded by the commercial USB2000 spectrometer and the spectral scans from the MOC.The power spectra are used to compute transmission spectra for the didymium and holmium filters, which in turn are used to calibrate the wavelength mapping of the SLM pixel columns.The spectral matched Fig. 3. Top two plots: White light spectrum with no filter, didymium filter (Di), and holmium filter (Ho), as measured by the commercial USB2000 spectrometer and spectral scans using the MOC.Standard deviations are too small to be discernible.Middle two plots: Transmission spectra of the didymium (Di) and holmium (Ho) filters, computed from the spectrum data from the USB2000 and the MOC.Central lines show averages across multiple recordings, and thin outer lines show averages plus and minus one standard deviation.Bottom plot: Spectral matched filter coefficients, computed using MOC spectral data.
filters computed from the spectral scan data are also shown in Fig. 3.The spectral resolution in this experiment is determined primarily by the entrance slit width and the line spread function of the optical system.The spectral resolution of the MOC (instrument function linewidth) is about 15 nm and is slightly narrower at shorter wavelengths due to the experiment geometry.This is significantly broader than the 1.5 nm resolution quoted for the commercial spectrometer, but it does not hurt the spectrum recognition operation since the spectral matched filters are computed directly from the (broadened) MOC spectral scan data rather than the commercial spectrometer data.To simplify the experiment, the pixel columns of the 1024 × 768 pixel SLM are grouped into 64 wavelength bins of 16 pixel columns each, representing about a 4 nm bandwidth (and therefore a small contribution to the instrument function linewidth).The SLM calibration process produces incorrect results for wavelength bins with very little optical power, so to reduce systematic error in the spectrum recognition operation, some bins are ignored and their spectral matched filter coefficients are set to zero (the cutoff is chosen empirically at 8% of the peak power).

Results
The results of the single-output spectrum recognition experiment are shown in Fig. 4(a).The ideal results for all spectrum recognition experiments are the identity matrix; see Eq. (3).To quantify the spectrum recognition performance, we define a metric called the fidelity, which is one minus the maximum deviation from the ideal correlation value (zero or one) of each correlation.The single-output spectrum recognition method performs adequately, achieving a fidelity of 0.9337.The standard deviation of each value in Fig. 4(a) is less than 0.0025, computed from the optical power measurements using propagation of uncertainty principles and assuming independent and normally distributed measurements; additional error is presumed to be due to SLM calibration errors.The presence of negative values and values greater than one is due to the subtraction of the positive and negative parts of the correlation coefficients, and due to background subtraction; see Eqs. ( 10)- (13).The results of the two-output bipolar spectrum recognition experiment are presented in Fig. 4(b), and the results of the two-output, two-zone experiment are shown in Fig. 4(c).The bipolar method achieves a fidelity of 0.8360, and the multiple-zone approach has a fidelity of 0.8425, both comparable to the single-output method.The slight degradation in performance compared to the single-output method is primarily attributable to residual crosstalk, which is caused partly by SLM calibration errors and partly by imperfect positioning of the pickoff mirrors used to direct light to the two detectors.The standard deviation of each value is less than 0.0047 in Fig. 4(b) and less than 0.0060 in Fig. 4

(c).
A single data point in Fig. 4(a) consists of two measurements (two half-filters) and takes an average of 2.5 seconds to acquire, even though our experiment is not optimized for speed.The data in Figs.4(b) and 4(c) are acquired twice as fast, since the two half-filters are measured simultaneously.Our experiment's speed is primarily limited by the Newport power meter, which acquires measurements at about 1 Hz, independent of the light level or integration time; other power meters are available that can make measurements at over 1 kHz.(The 2.5-second average time to make two measurements includes automatic removal and re-measurement of occasional outliers.)The power meter's integration time and detector sensitivity do not change between the single-output case in Fig. 4(a) and the multiple-output cases in Figs.4(b) and 4(c).To ensure low noise, we repeated each measurement ten times and averaged them, but based on the standard deviations reported above, this is not necessary.

Conclusions and future work
Multivariate optical computation is an experimentally successful approach to molecular identification, and it can enhance the signal-to-noise ratio and shorten integration times.We have demonstrated a multiple-output multivariate optical computer using a spatial light modulator and a unique optical configuration.The SLM implements multiple spectral filters simultaneously, allowing faster processing than other MOC designs when adequate optical power is available.A commercial, off-the-shelf SLM is used, unlike other approaches that require a custom-built SLM [14].Our SLM is able to implement arbitrary coefficients, unlike the binary nature of a DMD, which requires averaging several samples to achieve non-binary reflectances (although some researchers indicate that binary filters may not be a great detriment [15,16]).
The input and output image paths are common in our experimental demonstration, but it might be possible to reduce aberrations and stray light by directing light from the SLM into a second, complementary optical system leading to the detectors.Another interesting possibility is the use of collimated input light, which removes the need for imaging in the horizontal direction; in that case, the optical system need only consist of a grating and a cylindrical lens, and the multiple-output techniques described in this paper may still be used.
We note that compressive sensing of the spectrum is possible using the setup described above.In compressive sensing, a random set of M > N S basis functions is generated to replace the spectral matched filters b ± k , and the measurements are post-processed to reconstruct the spectrum [26][27][28].Current approaches to compressive sensing would require reconstruction of the spectrum followed by traditional computational methods of molecular identification, but an intelligent choice of basis functions or a novel reconstruction algorithm might produce chemical concentration data directly.
Rare-earth-doped glass filters, which often serve as spectroscopic references, provide the absorption spectra used to test the MOC in this experiment.A MOC designed to operate in the near-infrared could distinguish chemicals of practical importance, such as distinguishing between certain toxic and non-toxic gases.

Fig. 1 .
Fig. 1.Multiple-output MOC schematic diagram.Solid lines indicate mirrors; dashed lines indicate pickoff mirrors positioned beneath the transmitted optical path.The central thin line indicates the optical path; outer thin lines represent the marginal ray path schematically.The path length from the SLM to each detector is the same.The polarizer is oriented horizontally.

Fig. 2 .
Fig.2.Multiple-output SLM methods.(a) Incoming and outgoing beams, shown schematically.In the experiment, the SLM is actually overfilled, rather than underfilled as shown here, and the light is imaged rather than collimated.(b) Simplified representation of (a).(c) Bipolar method.The positive half-filter (green) and negative half-filter (red) are directed towards different detectors.(d) Multiple-zone method.The SLM is divided into two vertical zones (yellow and blue); each implements one matched half-filter, and each is directed towards a different detector.

Fig. 4 .
Fig. 4. Spectrum recognition results using (a) a single output (one half-filter), (b) the bipolar (single-zone) method, and (c) the multiple-zone method with two zones.In each chart, the vertical axis denotes correlation value.The lower-left axis indicates the sample spectrum; WL: white light source with no filter; Di: didymium filter; Ho: holmium filter.The lower-right axis gives the spectral matched filter.Ideal correlation values are one along the diagonal and zero elsewhere.The fidelity (one minus the maximum deviation of any value from the ideal) is (a) 0.9337, (b) 0.8360, and (c) 0.8425.