Journal of Spectroscopy

Journal of Spectroscopy / 2017 / Article

Research Article | Open Access

Volume 2017 |Article ID 1485048 |

Jie Yu, Xiaoyan Zhang, Dibo Hou, Fang Chen, Tingting Mao, Pingjie Huang, Guangxin Zhang, "Detection of Water Contamination Events Using Fluorescence Spectroscopy and Alternating Trilinear Decomposition Algorithm", Journal of Spectroscopy, vol. 2017, Article ID 1485048, 9 pages, 2017.

Detection of Water Contamination Events Using Fluorescence Spectroscopy and Alternating Trilinear Decomposition Algorithm

Academic Editor: Jose M. Pedrosa
Received14 Dec 2016
Revised08 Mar 2017
Accepted19 Mar 2017
Published30 May 2017


The method based on conventional index and UV-vision has been widely applied in the field of water quality abnormality detection. This paper presents a qualitative analysis approach to detect the water contamination events with unknown pollutants. Fluorescence spectra were used as water quality monitoring tools, and the detection method of unknown contaminants in water based on alternating trilinear decomposition (ATLD) is proposed to analyze the excitation and emission spectra of the samples. The Delaunay triangulation interpolation method was used to make the pretreatment of three-dimensional fluorescence spectra data, in order to estimate the effect of Rayleigh and Raman scattering; ATLD model was applied to establish the model of normal water sample, and the residual matrix was obtained by subtracting the measured matrix from the model matrix; the residual sum of squares obtained from the residual matrix and threshold was used to make qualitative discrimination of test samples and distinguish drinking water samples and organic pollutant samples. The results of the study indicate that ATLD modeling with three-dimensional fluorescence spectra can provide a tool for detecting unknown organic pollutants in water qualitatively. The method based on fluorescence spectra can be complementary to the method based on conventional index and UV-vision.

1. Introduction

Water pollution problem is attracting more and more attention, and monitoring of water quality is important in order to avoid health risk to residents. It is necessary to develop a technique for rapid water quality analysis in the case of unknown contaminants because of deterioration of water resources, indiscriminate discharge of wastewater, chemical leakage, and so on.

Currently, water pollution abnormality detection mainly depends on conventional water quality parameters. In the conventional detection, water anomaly detection methods are mainly based on traditional indexes of water quality. For example, Conde [1] developed regression models of artificial neural networks (ANNs) and relevance vector machines (RVMs) according to the normal water quality parameters and generated a discriminant classifier to discriminate the abnormal water from the normal water data online. However, the process of obtaining these water quality parameters has various problems, such as long analysis time, not sensitive enough, requiring reagents, and producing waste [2]. It cannot satisfy the online high-frequency water quality anomaly detection. Compared with the method of conventional detection, the method of water quality analysis based on spectra can measure samples directly by spectra without other operations such as extraction or separation, and its advantages are simple, rapid, and so on [3]. There have been many researches on water quality analysis based on UV-visible spectroscopy. Dürrenmatt and Gujer [4] analyzed the UV/Vis data with a two-staged clustering method consisting of the self-organizing map algorithm and the Ward clustering method to distinguish the industrial sewage and living sewage from the sewage treatment plant. Langergraber et al. [5, 6] continuously monitored the water quality through ultraviolet spectroscopy and judged the anomaly according to the three-dimensional spectrum and the historical spectrum of ultraviolet spectrum and time axis to obtain the good result. There are also some researches about distribution water quality anomaly detection by analyzing the ultraviolet spectroscopy [7, 8]. Hou et al., for example, integrated principal component analysis (PCA) with chi-square distribution to detect distribution water quality anomalies. However, detection limit of some organic matter based on UV-vision spectra is still not low enough to achieve the standard.

Three-dimensional fluorescence spectra have lower detection limit of organic matter than UV-visible spectra [9]; it can provide more complete spectral information; it has characteristics of high selectivity, high sensitivity, good reproducibility, requiring less sample, not damaging the structure of the sample, and so on [10]. So, three-dimensional fluorescence spectroscopy can be considered to be used as a tool of detecting water quality contaminant events and is complementary to conventional index methods and UV-vision spectra methods. It can detect some matters that the conventional index methods and UV-vision spectra methods cannot be used to detect, and the lower detection limit may be lower. Three-dimensional fluorescence spectra can be used to analyze water samples quantitatively. Three-dimensional fluorescence spectra are widely applied to measure the relative concentration of organic matter in water [1113]. Three-dimensional fluorescence spectra are also applied to water qualitative analysis, mainly in the field of classification. The analysis of nature organic matter (NOM) in the sea, rivers, or lakes is used to classify the water samples from different sources. Baker [14] applied three-dimensional fluorescence spectroscopy to the water samples from 10 sample sites in six rivers and demonstrated that tryptophan- and fulvic-like fluorescence intensity is associated with whether the rivers accept the sewage treatment plant effluent or not. Pavelescu et al. [15] applied fluorescence EEM spectroscopy to the samples from 12 groundwater sources (wells) located in different surroundings, and fluorescence indices can be used to discriminate the water samples from different sources. Thus, studies about three-dimensional fluorescence spectra mainly highlight the quantification analysis and classification of specific known organic matter in water. However, there are few researches about unknown pollutant detection in water supply system.

The aim of this paper was to make qualitative detection of unknown pollutants for early warning when sudden pollution event happens in water supply system by using three-dimensional fluorescence spectra to make up for the lack of conventional method and UV-vision method in the water pollution qualitative detection. Fluorescence data were analyzed using matrix feature extraction method based on alternating trilinear decomposition (ATLD) and residual sum of squares, combining the threshold to judge the unknown samples and to detect the aqueous samples of organic contaminants.

2. Methodology

The basic idea of the paper is to establish a model of normal water sample. If a test sample does not conform to the model, it will be determined as an anomaly sample. Before the establishment of the model, the data need to be pretreated. Then, the ATLD algorithm is used to obtain the model. The model is applied to test samples to obtain the model data, and the model matrix is compared to the measured matrix to obtain the residual matrix as a basis of judging whether the water samples are abnormal or not. The main process of the method is shown in Figure 1.

2.1. Pretreatment

Three-dimensional fluorescence spectra could contain not only the fluorescence of the substance to be tested but also Rayleigh and Raman scattering. Since that scattering part does not meet the requirements of trilinear decomposition algorithm theory, it is not appropriate to analyze the scattering part with decomposition model. So it is essential to eliminate the scattering of the three-dimensional fluorescence spectra. Some researches eliminated the scattering by taking out the background of distilled water, which may still remain some scattering [16]. It is more likely to cause some problems when the concentration of the sample is relatively low. This paper adopts the Delaunay triangulation interpolation method [17] to preprocess the raw data in order to eliminate the impact of Rayleigh scattering. In the meanwhile, this paper eliminated the impact of Raman scattering by taking out the background of solvent.

When measuring the Raman spectra of ultrapure water on the excitation wavelength of 350 nm and the emission wavelength of 397 nm before the experiment starts up, it is discovered that there exists difference among the measurements. Consequently, in order to eliminate the difference, this paper did Raman normalization [18] to all of the three-dimensional fluorescence data, which equals to divide excitation-emission matrix (EEM) by the Raman peak value on the excitation/emission wavelength 350/397 nm of the ultrapure water.

2.2. Feature Extracting Based on ATLD and Residual Sum of Squares
2.2.1. ATLD Algorithm

Alternating trilinear decomposition (ATLD) algorithm, put forward by Wu et al. [19] in 1998, is an improvement to the conventional PARAFAC algorithm. Taking advantage of the alternating least squares theory, Moore-Penrose generalized inverse calculation based on singular value decomposition (SVD) as well as alternate iterations which are used to improve the performance of the trilinear decomposition. Compared to PARAFAC, ATLD, making use of generalized inverse and matrix diagonal elements extracting, is not sensitive to the number of components [20]; meanwhile, ATLD makes calculation by slice matrix, which accelerates the calculation speed and therefore improves the calculation efficiency.

Below is the trilinear model of a three-dimensional data matrix , as Figure 2 shows: where ; represents the number of factors and factors are all the measurable components, including components which are useful for fluorescence data and components which are disturbance for fluorescence data; represents the elements () of the three-dimensional data matrix . In this paper, the three-dimensional data matrix is just the three-dimensional fluorescence spectra matrix for k samples after pretreatment. represents the element () of the relative excitation matrix in size ; represents the element () of the relative emission matrix in size ; represents the element () of the relative concentration matrix in size ; represents the element () of the three-dimensional residual matrix E in size .

First, ATLD gives matrices and randomly and alternately updates ABC in the three separate directions of the three-dimensional data matrix, which are as follows: where ; ; ; represents taking the diagonal matrix elements as a column vector; , respectively, represent the Moore-Penrose generalized reverse of matrices ; , respectively, represent the transposition of the row vector of the relative excitation matrix , the row vector of the relative emission matrix , and the row vector of the relative concentration matrix ; matrices and normalized to unit length column by column every iterative loop.

Matrices are solved by the alternative iteration of the iteration formulas (2), (3), and (4) until the objective function is converged. The rule of convergence is as follows:

The residual sum of squares (SSR) is the loss function defined by ATLD, which is

As a result, ATLD could decompose the three-dimension fluorescence spectrum matrix to three low-dimension matrices, which are known as relative excitation matrix , relative emission matrix , and relative concentration matrix .

2.2.2. Feature Extracting Based on Residual Sum of Squares

Model parameters are obtained with ATLD algorithm, which is known as relative excitation matrix , relative emission matrix , and relative concentration matrix of the background sample.

Known by formula (4), if the background sample matrix , the relative excitation matrix , and the relative emission matrix of the background sample are substituted into formula (4), the relative concentration of each component of the sample could be obtained based on the ATLD model. Moreover, if , , and are substituted into formula (1), the modeling value of the sample could be given. As what formula (7) presents, the residual matrix is obtained according to the difference of actual value and the modeling value .

The residual sum of squares is , where is the element () of the matrix and can be obtained by calculating the sum of squares of the residual matrix of all the elements. The residual sum of squares is defined as the basis of the qualitative discrimination.

2.3. Qualitative Discrimination Based on Threshold

The method based on threshold is often used for image segmentation because of its simple calculation. The grayscale of the image is usually divided into several parts through one or several thresholds and pixels belonging to the same part are considered as the same object. This paper separates test samples into two parts. One is normal drinking water samples, and the other is organic pollutant samples.

This paper aims at setting reasonable threshold of the object sequence for qualitative discrimination. In other words, through setting the threshold to the residual sum of squares, the aim that a new unknown sample is qualitatively identified can be reached. The setting of the threshold is a critical problem. If the threshold is too large, the polluted water sample cannot be detected; on the other hand, if the threshold is too small, the drinking water may be detected as the polluted water sample by mistake.

In the math analysis, the mean and standard deviation are often used to indicate the important characteristics of the data set. n times detection values are , then the mean is , and the standard deviation is .

Three times of the standard deviation of qualitative discrimination object sequence is usually used to detect the test sample qualitatively. Byer and Carlson [21] monitored 16,000 drinking water multiparameter samples online, and the data revealed that parameters were changed with the change of time and flow. Suppose that the data follow Gaussian distribution, the samples within the scope of three times of the standard deviation () occupied 99.96%. In the research of Byer and Carlson, three times of the standard deviation () is just the threshold of organic matter sample detection. For test samples, if the detection value is in the scope of , it is determined to be drinking water samples, otherwise determined to be organic pollutant samples.

In this paper, the standard for the setting of threshold is that false positive rate of drinking water samples is under 10%, so two times of the standard deviation of the residual sum of squares of 10 background drinking water samples is used as the threshold for qualitative discrimination. Explanatorily, the residual sums of squares of 10 drinking water samples are used to get the mean first; then, and are put together to get the standard deviation , and is defined as the threshold of qualitative discrimination.

3. Results and Discussion

3.1. Sampling

One group of samples was the three kinds of organic solution with fluorescent characteristics in the concentrations of 2 μ/L, 4 μ/L, 6 μ/L, 8 μ/L, 10 μ/L, 20 μ/L, 30 μ/L, and 40 μ/L, and the experiment was repeated three times. The other group of samples was in the concentrations of 1 μ/L, 3 μ/L, 5 μ/L, 7 μ/L, 15 μ/L, 25 μ/L, 35 μ/L, and 45 μ/L, and the experiment was repeated two times. In each experiment, ten drinking water samples were collected at the interval of half an hour from the laboratory tap as the background samples. Fluorescence spectra, in the form of excitation-emission matrices (EEMs), were recorded in the excitation wavelength range from 200 to 700 nm and emission wavelength range from 200 to 700 nm. Scanning intervals for excitation and emission were both 5 nm.

3.2. Pretreatment of Spectra

Three-dimensional fluorescence spectra measured by the spectrometer contain Rayleigh and Raman scattering, as shown in Figure 3(a). The Delaunay triangulation interpolation method was used to make the scattering pretreatment of the raw data. In order to remove the noise of instrument, EEM was subjected to Raman normalization after removing scattering, that is, divided by Raman scattering value of water at λex = 350 nm, λem = 397 nm. The charts before and after the pretreatment are shown in Figure 3. It is clear that the three-dimensional fluorescence spectra before pretreatment had significant scattering, and spectral pretreatment removed scattering and retained effective fluorescence spectra part.

3.3. Qualitative Determination Based on ATLD and Threshold

ATLD was applied to background drinking water samples to establish the model. Because of the complexity of the composition of water samples, the number of factors in the ATLD model is hard to identify. However, there are two peaks in the spectra of drinking water after pretreatment, as in Figure 3(b); according to the common dissolved organic matter with fluorescent characteristic in the water, the two peaks may correspond to tyrosine-like protein organic matter and tryptophan-like protein organic matter, so it can be seen as a mixture of two kinds of organic matters without other fluorescent organic matters, and the number of factors is identified as . Relative excitation matrix A, relative emission matrix B of water samples (Figure 4), and relative concentration matrix C of each component can be obtained. In Figure 4, factor 1 and factor 2 correspond to the two peaks in original fluorescence spectra of water samples, which may represent tyrosine-like protein organic matter and tryptophan-like protein organic matter.

Relative excitation matrix , relative emission matrix , and the test sample matrix are used to estimate relative concentration matrix of each component of test samples according to formula (4). According to the trilinear decomposition principle, combining relative excitation matrix A and relative emission matrix B with relative concentration matrix can obtain spectra data modeling value of unknown test samples, as is shown in Figure 5(a). Compared with Figures 5(a) and 5(b), it can be found in Figure 5(b) that the spectra of water samples had two fluorescence peaks; the model established by ATLD as Figure 5(a) can characterize the fluorescence signals caused by main organic matters in the drinking water.

The measured value subtracting the modeling value of spectra matrix can obtain residual matrix (Figure 5(c)), which can indicate the fluorescence signal caused by the noise of instrument and the remaining scattering part that cannot be represented by the model. The ATLD model established with the drinking water can be used to explain its main organic matter composition and content.

For organic matter samples, three-dimensional fluorescence spectra can be considered as superposition of drinking water spectra and organic matter spectra. Combined with Figure 5(d), it can be found that the ATLD model based on drinking water background can represent the part of drinking water spectra in the organic matter solution. However, according to Figure 5(f), rhodamine B not belonging to the background water sample cannot be explained by the model. It can be used as the basis of distinguishing the background drinking water samples and organic pollutant samples.

According to the residual matrix, the residual sums of squares of background drinking water samples and test samples are, respectively, calculated, as a detecting target sequence of qualitative determination. The residual sums of squares of one group experiment data are shown in Figure 6.

The mean and standard deviation of residual sums of squares of drinking water sample were calculated, and then the residual sum of squares of each unknown test sample subtracted the mean of background water samples. If the difference is larger than the threshold, the sample is judged to be organic pollutant sample; otherwise, drinking water sample. The result of qualitative discrimination based on the threshold depends largely on the threshold selection. As is mentioned in the second part of this paper, the standard of selecting the threshold is that false-positive rate of background drinking water samples is less than 10%. So two times of standard deviation of drinking water samples is selected as the threshold. The experiment result is shown in Table 1.

GroupMeanStandard deviationTotal number of OM samplesTotal number of detectedDetection rate


It can be seen from the result of qualitative discrimination that the detection rates of organic matter samples are all more than 77.78%. 107 organic matter samples are detected from the total 126, so the detection rate of all five groups of experiments is 84.92%. Some contaminants having similar spectra with drinking water were not detected, because the spectral peaks of contaminants overlap with those of drinking water. The result of detection rate in group 4 is not good. The possible reason is that the scattering part was not removed completely in many water samples of group 4, which resulted in the model established in group 4, and was not accurate enough because the scattering part cannot be explained by the trilinear model.

4. Conclusion

This paper studied a problem of unknown contaminant qualitative detection in water but not a qualitative problem of known contaminant detection. A method based on ATLD and threshold was applied to analyze three-dimensional fluorescence spectra in order to detect the unknown organic pollutants with fluorescent characteristics in the water. ATLD algorithm was used to establish the model of normal water sample, and the residual matrix was obtained through the difference of the model matrix and the measured matrix. The residual sum of squares was calculated according to the residual matrix and compared with the threshold to judge the test sample which was an organic pollutant sample or a normal water sample. In order to verify the theory, the experiments of analyzing the spectra of water samples and organic contaminant samples were launched.

The result shows that ATLD model extracting feature can be used to qualitatively discriminate whether test samples are polluted if the pollutants are with fluorescent characteristics. However, the detection rate of qualitative discrimination method based on the ATLD model fluctuated. This may be related that the method of extracting feature based on ATLD and residual sum of squares is a method depending on the background samples, that is, the result of the method is related to the quality and quantity of the samples.

In general, qualitative discrimination method based on ATLD and residual sum of squares, combining the threshold, can be used to detect the unknown organic pollutants with fluorescent characteristics in drinking water, but the detection rate is low which can be a problem worthy of further study. Besides, the method proposed in the paper does not apply to the situation of overlapped peaks well, and this will also be the work of further research.

Conflicts of Interest

The authors declare that they have no conflicts of interest.


This work was funded by the National Natural Science Foundation of China (no. 61573313) “Online water-quality anomaly detection, classification, and identification based on multi-source information fusion” and (no. U1509208) “Research on big data analysis and cloud service of urban drinking water network safety,” and the Key Technology Research and Development Program of Zhejiang Province (no. 2015C03G2010034) “Research on intelligent management and long-effective mechanism for river regulation and maintenance.”


  1. E. F. Conde, Environmental Sensor Anomaly Detection Using Learning Machines, Dissertations & Theses-Gradworks, Utah State University, 2011.
  2. J. Dahlen, S. Karlsson, M. Backstrom, J. Hagberg, and H. Pettersson, “Determination of nitrate and other water quality parameters in groundwater from UV/Vis spectra employing partial least squares regression,” Chemosphere, vol. 40, no. 1, pp. 71–77, 2000. View at: Google Scholar
  3. W. Bourgeois, J. E. Burgess, and R. M. Stuetz, “On-line monitoring of wastewater quality: a review,” Journal of Chemical Technology & Biotechnology, vol. 76, no. 4, pp. 337–348, 2001. View at: Publisher Site | Google Scholar
  4. D. J. Dürrenmatt and W. Gujer, “Identification of industrial wastewater by clustering wastewater treatment plant influent ultraviolet visible spectra,” Water Science and Technology, vol. 63, no. 6, pp. 1153–1159, 2011. View at: Publisher Site | Google Scholar
  5. G. Langergraber, J. K. Gupta, A. Pressl et al., “On-line monitoring for control of a pilot-scale sequencing batch reactor using a submersible UV/VIS spectrometer,” Water Science and Technology, vol. 50, no. 10, pp. 73–80, 2004. View at: Google Scholar
  6. G. Langergraber, J. V. D. Broeke, W. Lettl, and A. Weingartner, “Real-time detection of possible harmful events using UV/vis spectrometry,” Spectroscopy Europe, vol. 18, no. 4, pp. 19–22, 2006. View at: Google Scholar
  7. D. Hou, S. Liu, J. Zhang, F. Chen, P. Huang, and G. Zhang, “Online monitoring of water-quality anomaly in water distribution systems based on probabilistic principal component analysis by UV-Vis absorption spectroscopy,” Journal of Spectroscopy, vol. 2014, no. 20, pp. 1–9, 2014. View at: Google Scholar
  8. D. Hou, J. Zhang, Z. Yang, S. Liu, P. Huang, and G. Zhang, “Distribution water quality anomaly detection from UV optical sensor monitoring data by integrating principal component analysis with chi-square distribution,” Optics Express, vol. 23, no. 13, pp. 17487–17510, 2015. View at: Publisher Site | Google Scholar
  9. J. G. Xu, Fluorophotometric Analysis, Science Press, Beijing, 2006.
  10. W. Yuanqing, Three-Dimensional Fluorescence Spectrum Detection Method for Measuring the Concentration of Organic Pollutants in Water, Zhejiang University, 2011.
  11. K. M. G. Mostofa, T. Yoshioka, E. Konohira, E. Tanoue, K. Hayakawa, and M. Takahashi, “Three-dimensional fluorescence as a tool for investigating the dynamics of dissolved organic maker in the Lake Biwa watershed,” Limnology, vol. 6, no. 2, pp. 101–115, 2005. View at: Publisher Site | Google Scholar
  12. M. V. Bosco, M. P. Callao, and M. S. Larrechi, “Simultaneous analysis of the photocatalytic degradation of polycyclic aromatic hydrocarbons using three-dimensional excitation–emission matrix fluorescence and parallel factor analysis,” Analytica Chimica Acta, vol. 576, no. 2, pp. 184–191, 2006. View at: Publisher Site | Google Scholar
  13. Y. Shutova, A. Baker, J. Bridgeman, and R. K. Henderson, “Spectroscopic characterisation of dissolved organic matter changes in drinking water treatment: from PARAFAC analysis to online monitoring wavelengths,” Water Research, vol. 54, no. 4, pp. 159–169, 2014. View at: Publisher Site | Google Scholar
  14. A. Baker, “Fluorescence excitation-emission matrix characterization of some sewage-impacted rivers,” Environmental Science & Technology, vol. 35, no. 5, pp. 948–953, 2001. View at: Publisher Site | Google Scholar
  15. G. Pavelescu, L. Ghervase, C. Ioja, S. Dontu, and R. Spiridon, “Spectral fingerprints of groundwater organic matter in rural areas,” Romanian Reports in Physics, vol. 65, no. 3, pp. 1105–1113, 2013. View at: Google Scholar
  16. R. G. Zepp, W. M. Sheldon, and M. A. Moran, “Dissolved organic fluorophores in southeastern US coastal waters: correction method for eliminating Rayleigh and Raman scattering peaks in excitation–emission matrices,” Marine Chemistry, vol. 89, no. 1, pp. 15–36, 2004. View at: Google Scholar
  17. R. F. Chen, P. Bissett, P. Coble et al., “Chromophoric dissolved organic matter (CDOM) source characterization in the Louisiana Bight,” Marine Chemistry, vol. 89, no. 1, pp. 257–272, 2004. View at: Google Scholar
  18. A. J. Lawaetz and C. A. Stedmon, “Fluorescence intensity calibration using the Raman scatter peak of water,” Applied Spectroscopy, vol. 63, no. 8, pp. 936–940, 2009. View at: Publisher Site | Google Scholar
  19. H. L. Wu, M. Shibukawa, and K. Oguma, “An alternating trilinear decomposition algorithm with application to calibration of HPLC–DAD for simultaneous determination of overlapped chlorinated aromatic hydrocarbons,” Journal of Chemometrics, vol. 12, no. 1, pp. 1–26, 1998. View at: Publisher Site | Google Scholar
  20. Y. Yongjie, A Research on Three-Way Second-Order Calibration Algorithms and Its Applications, Hunan University, 2009.
  21. D. E. Byer and K. H. Carlson, “Real-time detection of intentional chemical contamination in the distribution system,” Journal American Water Works Association, vol. 97, no. 7, p. 130, 2005. View at: Google Scholar

Copyright © 2017 Jie Yu et al. This is an open access article distributed under the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.

Related articles

No related content is available yet for this article.
 PDF Download Citation Citation
 Download other formatsMore
 Order printed copiesOrder

Related articles

No related content is available yet for this article.

Article of the Year Award: Outstanding research contributions of 2021, as selected by our Chief Editors. Read the winning articles.