利用油水稳定化和支持向量回归增强近红外光谱测定油中水分的方法
2014-09-26喻其炳苏迪焦昭杰李川
喻其炳 苏迪 焦昭杰 李川
摘要[SS]近红外光谱(NIRS)可以检测溶解于油中的水分含量,但油中水分较多时会散射而非吸收NIRS,从而引起较大误差。为此,筛选非离子型表面活性剂(Span80)将含水油液稳定分散成小颗粒,利用其NIRS数据建立水分含量的支持向量回归模型。实验中油水稳定化将NIRS测定变压器油中水分含量的上限从传统的0.1%提升到1%(V/V),通过应用连续投影算法,在511个NIRS变量中筛选出15个有效变量(占原变量的2.9%),建立的支持向量回归模型对验证集的预测均方根误差为2.93%,相关系数为0.99,相对分析误差为9.732。
关键词[SS]油水稳定化;近红外光谱;连续投影算法;支持向量机,油中水分
1引言
水分严重影响了油液的品质, 例如变压器油中水分会加速油液氧化、降低油液绝缘性能、降低设备运行的可靠性和缩短使用寿命\[1\]。油中水分测定常用Karl ischer(K)法,但该方法具有操作复杂、费时而且试剂不环保、不易保存等缺点\[2\]。随着光谱技术的发展\[3~5\],近红外光谱(NIRS)已经成功应用于测定油品中的微量水分\[6\]。与K法相比,NIRS可以快速测量油中含水量\[7\],但是,当油中含水量较高(例如含水量0.1%以上的变压器油或者0.2%以上的透平油)时,水分在重力作用下析出和聚集,大颗粒的水分散射而非吸收NIRS,从而对NIRS测定造成较大误差,严重时甚至不能获得测定结果。
iggins等\[8\]发现,同一油样通过K法测定含水量时,每2 h约减少100 μg/g。因此,目前NIRS对油中微量水分(一般以溶解状态存在)测定精度较高\[9\],对油包水形式的乳化水也能够检测,但当用于油中含量较大的不稳定水分(例如水包油形式的乳化水或者游离水)的测定时,其局限性就非常明显。
为此,本研究一方面在实验过程提出一种油水稳定化技术,使水分均匀稳定分散到油液中;另一方面在建模算法上采用连续投影算法(SPA)结合支持向量回归(SVR)建模,利用算法的非线性映射能力提升含水量测定的精度。通过实验和建模两个方面的改进,提升近红外光谱方法对更高含水量油品的检测能力。本方法以变压器油中含水量测定为例,将NIRS测定变压器油中水分含量的上限从传统的0.1%提高到1%(V/V, 下同),大幅提升了NIRS的测定范围,提高测量精度和建模效率。
2实验部分
2.1仪器设备
采用NIRQuest512近红外光谱仪(美国Ocean Optics公司)采集油液透射光谱,波长范围900~1722 nm,分辨率3.1nm,LS1溴钨灯光源,载样器光程10 mm,InGaAs检测器,512个点组成光谱数据。油水稳定化性能以及水分含量分别用ZY901型石油和合成液抗乳化自动测试仪、SYD2122B型微量水分测定仪(K法)测定。
2.2油水稳定化实验
筛选油水稳定剂并添加到含水油品中,使水分在油品中均匀分散,实现油水稳定化\[10\]。实验中对阴离子型、阳离子型、两性型和非离子型等稳定剂进行多次筛选,得到一种非离子型油水稳定剂Span80(失水山梨糖醇脂肪酸酯)。
由于没有标准方法确定油水稳定化过程中油水稳定剂的最佳含量,本研究参考国家标准\[11\]自行设计实验,通过测定加入油水稳定剂后的油液的破乳化时间,间接确定表面活性剂的最佳含量,具体为:(1) 室温下向干净的量筒中加入0 mL蒸馏水,0 mL油样,分别加入油样体积(0 mL)的以0.5%为公差的等差数列的油水稳定剂。随后放入(5±1)℃恒温水浴中,将搅拌叶片放入量筒内,静置20 min, 使油水温度与水浴温度一致。(2) 将搅拌叶片垂直插入静置好后的样品中,在(1500±15) r/min转速下搅拌5 min后提起叶片,刮掉叶片上残留的样品至量筒内,从侧面观察并记录量筒内分离的油层、水层和乳化层体积。参考国家标准\[11\],定义量筒底部出现10 mL水层时所用时间为破乳化时间。破乳化时间越长,油液稳定性越好,此时的油水稳定剂含量即为最佳含量。考虑经济性,取增长速度拐点对应的油水稳定剂含量作为最佳添加量。
2.3样品制备及光谱采集
采用#25变压器油作为油液样品。量取200个50 mL新变压器油于100 mL三角烧瓶中,平均分成组A与组B,分别用0.5~100 μL的微量进样器向样品中注射超纯水(I级水),配制成100个不同浓度梯度的含水油样(加水量分布范围为0~500 μL),添加超纯水可减少一般水中微量元素对NIRS的影响。A组加水后不处理,B组加水后再加最佳含量油水稳定剂(3%,具体结果见3.1节),磁力搅拌器搅拌15 min。两组样品均超声振荡10 min,使试样混合均匀后作为实验样品。
2.油中含水量的测定采集完光谱的样品,用SYD2122B型油中水分测定仪(K法)测定样品的含水量作为标准值。
2.5数据建模与处理
考虑到全谱数据不仅变量多建模复杂,而且包含的大量冗余信息会降低分析精度,研究采用SPA从全谱中筛选特征波长变量;对筛选的建模变量采用SVR进行建模。
SPA是一种向前循环变量筛选方法,它从一个波长开始,循环计算其在未选入波长上的投影,使选择的每一个新波长都与之前一个线性关系最小,最后得到投影向量最大的波长组合。目前,已有许多近红外光谱的特征变量选择算法\[12, 13\],其中SPA能在严重重叠的光谱信息中有效剔除冗余信息,削弱非目标因素的影响,减少建模变量、提高建模效率\[1\],在近红外光谱的多元定量和定性分析中应用广泛。
支持向量回归(SVR)是一种机器学习算法\[15\],可以在非线性框架下建立回归模型,研究采用SVR的最小二乘变种,即最小二乘支持向量回归(LSSVR)算法建模。与标准的SVR算法相比,LSSVR降低了训练时间、提高了泛化能力、减少计算复杂程度,常应用于光谱定性或定量分析中。
本实验采用高斯核函数的LSSVR进行建模,对过程涉及的正则化参数γ和内核函数σ2使用10fold Cross Validation将数据集分成10份,轮流选9份训练、1份测试,每次试验都会得出一个正确率。10次正确率的平均值作为对算法精度的估计,选出最优γ和σ2。
3结果与讨论
3.1最优油水稳定剂实验结果
油水稳定剂添加量与破乳化时间的实验结果见图1。油水稳定剂超过3%后,油液破乳化时间延长,速度减小。从经济性角度,取3%作为油水稳定化的最佳添加量,实验中破乳化时间为119.6 min。
3.2样品含水量及其光谱
用SYD2122B型油中水分测定仪测定200个样品(分为A、B两组,每一组取75个为校正集,25个为验证集)的含水量。两组的含水量范围都在0.001%~1%之间。扣除暗光谱后用透射法采集两组样品的近红外光谱,光谱积分时间79ms,主板温度31.51 ℃,平滑度2,空气作参比,平均次数30次。A组100个不同含水量样品(未进行油水稳定化处理)的近红外光谱见图2a,图中部分吸光度紊乱,可能是油中含水量过高使水分在油液中分散不均,此时油样不再是真溶液,形成了非均匀散射体系。取A组中含水量最低的70个样品(全部低于0.1%)的近红外光谱在图2(b)示出,图中吸光度还不至于紊乱,表明即使不添加油水稳定剂,NIRS也可以测量含水量低的样品。
3.SVR建模测定
通过随机抽样,按校正集:验证集=75∶25(3∶1)的数量比,将75个校正集光谱矩阵与含水量向量导入LSSVR中进行训练。再将25个验证集光谱矩阵输入LSSVR回归模型,得出油中含水量结果。将其与K法标准值比较,可以判定模型的精度。A组前70号中也按校正集:验证集=53∶17(约3∶1)采取相同操作。验证集建模精度的评价指标采用预测均方根误差RMSEP、验证集的相关系数Rv(无量纲)、相对分析误差RPD(无量纲)。RMSEP越小越好; Rv越接近1越好;而RPD<2表示预测结果不可接受,RPD>5表示预测结果可以接受,RPD>8表示预测结果很好。图示出了A组100个样品、B组100个样品、A组前70个样品、B组前70个样品的K方法(标准值)与NIRS方法的测定结果对比。
[S(]图K方法和NIRS测定结果比较:(a) A组100个样品;(b) B组100个样品;(c) A组前70个样品;(d) B组前70个样品
对比图c和图d可知,0.1%以下含水油液分散均匀,是否进行油水稳定化处理对建模效果几乎无影响。对比图a和图b可知,当水分高于0.1%后,不加Span80的NIRS建模结果不准确,而且误差主要出现在含水量高于0.1%部分的油样中。当加入Span80后,NIRS建模效果明显变好。除了图形化的直观比较,表2定量比较了不同的实验数据和建模方法的测定精度,结果表明,油水稳定化可以大幅提升NIRS测定油中水分的能力。对于光谱数据直接用SVR建模(表2第行数据),虽然测定精度高,但是全谱数据(511维)建模将会增加计算负担。当采用SPA降维(表2第5行数据)后,建模变量从初始的511维减少到15个特征变量(占原变量的2.9%),但是测定精度与全谱建模精度基本一致,甚至其RESEP误差还减少了0.01%。以上分析表明,本研究从实验和建模两个方面改进油中水分的NIRS测定方法,将含水量的测定上限从0.1%提高到1%,而且对测定下限没有影响,其测定范围提升了10倍。本方法可以用于实际的变压器油中水分快速检测,在保证测量精度的同时,还提高了建模效率。
References
1ofana I, Wasserberg V, Borsi , Gockenbach E, arzaneh M. IEEE Electrical Insulation Magazine, 2002, 8(): 5-16
2LIU WeiYing, YANG Zhiong. Guangxi Journal of Light Industry, 2011, 15(9): 3, 81
刘维英, 阳志红. 广西轻工业, 2011, 15(9): 3, 81
3ZANG Zhen, WANG Zheng, ZOU uiJun, SI Ying. Chinese J. Anal. Chem., 2013, 1(10): 1606-1613
张 真, 汪 正, 邹慧君, 施 鹰. 分析化学, 2013, 1(10): 1606-1613
Mottaleb M A, Yang J S, Kim J. Appli. Spectros. Rev., 2002, 37 (3): 27-273
5Noda I. Appl. Spectrosc, 2000, 5(7): 99-999
6SU Di, LI Chuan, JIAO ZhaoJie. Chinese Journal of Analysis Laboratory, 2013, 32(8): 77-81
苏 迪, 李 川, 焦昭杰. 分析试验室, 2013, 32(8): 77-81
7CEN Bin, LIU Ge, ZANG XianMing. Spectroscopy and Spectral Analysis, 2013, 33(11): 2959-2963
陈 彬, 刘 阁, 张贤明. 光谱学与光谱分析, 2013, 33(11): 2959-2963
8iggins , Seelenbinder J. Analytical Instrumentation, IR spotlight, September 2008
9CU XiaoLi. Molecular Spectroscopy Analytical echnology Combined with Chemometrics and Its Applications, Beijing: Chemical Industrial Press, 2011
褚小立. 化学计量学方法与分子光谱分析技术, 北京: 化学工业出版社, 2011
10YU GuoXian, ZOU XiaoLong, YU LiPing, JIN YaQing. Acta Petrolei Sinca (Petroleum Processing Section), 2006, 22(): 99-103
余国贤, 周晓龙, 余立平, 金亚青. 石油学报(石油加工), 2006, 22(): 99-103
11 Determination of Demulsibility Characteristics of urbine Oils in Service. National Standards of the People′s Republic of China. GB/ 76052008
运行中汽轮机油破乳化度测定法. 中华人民共和国标准. GB/ 76052008
12GUO ZhiMing, UANG WenQian, PENG YanKun, WANG Xiu, ANG XiuYing. Chinese J. Anal. Chem., 201, 2(): 513-518
郭志明, 黄文倩, 彭彦昆, 王 秀, 汤修映. 分析化学, 201, 2(): 513-518
13ranco A, Olivieri A C. Anal. Chim. Acta, 2011, 699(1): 18-25
1ilhoa A D, Galvaob R K , Araujo M C U. Chemometrics and Intelligent Laboratory Systems, 200, 72(1): 83-91
15BAO Xin, DAI LianKui. Chinese J. Anal. Chem., 2008, 36(1): 75-78
包 鑫, 戴连奎. 分析化学, 2008, 36(1): 75-78
16Wu D, e Y, eng S J, Sun D W. Journal of ood Engineering, 2008, 8(1): 12-131
AbstractNear infrared spectroscopy (NIRS) is capable of determining water contents in oils. owever, too much moisture contents in the oils will scatter rather than absorb the NIRS. his may cause greater measurement error. or this reason, a nonionic surfactant (Span80) was screened to make the water in the oils evenly dispersed into small droplets. he NIRS analysis was subsequently employed to build support vector regression (SVR) model of the water content. In this experiments, the upper limit of the water content determination was improved from the conventional 0.1% to 1.0% (V/V) by the oilwater stabilization. Applying successive projection algorithm, 15 valid variables (2.9% of the original ones) from 511 NIRS variables were selected. With the proposed SVR model, the measurement precision criteria for the validation dataset were root mean squares error percentage 2.93%, correlation coefficient 0.99, and relative percent derivation 9.732%.
KeywordsOilwater stabilization; Near infrared spectroscopy; Successive projection algorithm; Support vector regression; Water content in oil
9CU XiaoLi. Molecular Spectroscopy Analytical echnology Combined with Chemometrics and Its Applications, Beijing: Chemical Industrial Press, 2011
褚小立. 化学计量学方法与分子光谱分析技术, 北京: 化学工业出版社, 2011
10YU GuoXian, ZOU XiaoLong, YU LiPing, JIN YaQing. Acta Petrolei Sinca (Petroleum Processing Section), 2006, 22(): 99-103
余国贤, 周晓龙, 余立平, 金亚青. 石油学报(石油加工), 2006, 22(): 99-103
11 Determination of Demulsibility Characteristics of urbine Oils in Service. National Standards of the People′s Republic of China. GB/ 76052008
运行中汽轮机油破乳化度测定法. 中华人民共和国标准. GB/ 76052008
12GUO ZhiMing, UANG WenQian, PENG YanKun, WANG Xiu, ANG XiuYing. Chinese J. Anal. Chem., 201, 2(): 513-518
郭志明, 黄文倩, 彭彦昆, 王 秀, 汤修映. 分析化学, 201, 2(): 513-518
13ranco A, Olivieri A C. Anal. Chim. Acta, 2011, 699(1): 18-25
1ilhoa A D, Galvaob R K , Araujo M C U. Chemometrics and Intelligent Laboratory Systems, 200, 72(1): 83-91
15BAO Xin, DAI LianKui. Chinese J. Anal. Chem., 2008, 36(1): 75-78
包 鑫, 戴连奎. 分析化学, 2008, 36(1): 75-78
16Wu D, e Y, eng S J, Sun D W. Journal of ood Engineering, 2008, 8(1): 12-131
AbstractNear infrared spectroscopy (NIRS) is capable of determining water contents in oils. owever, too much moisture contents in the oils will scatter rather than absorb the NIRS. his may cause greater measurement error. or this reason, a nonionic surfactant (Span80) was screened to make the water in the oils evenly dispersed into small droplets. he NIRS analysis was subsequently employed to build support vector regression (SVR) model of the water content. In this experiments, the upper limit of the water content determination was improved from the conventional 0.1% to 1.0% (V/V) by the oilwater stabilization. Applying successive projection algorithm, 15 valid variables (2.9% of the original ones) from 511 NIRS variables were selected. With the proposed SVR model, the measurement precision criteria for the validation dataset were root mean squares error percentage 2.93%, correlation coefficient 0.99, and relative percent derivation 9.732%.
KeywordsOilwater stabilization; Near infrared spectroscopy; Successive projection algorithm; Support vector regression; Water content in oil
9CU XiaoLi. Molecular Spectroscopy Analytical echnology Combined with Chemometrics and Its Applications, Beijing: Chemical Industrial Press, 2011
褚小立. 化学计量学方法与分子光谱分析技术, 北京: 化学工业出版社, 2011
10YU GuoXian, ZOU XiaoLong, YU LiPing, JIN YaQing. Acta Petrolei Sinca (Petroleum Processing Section), 2006, 22(): 99-103
余国贤, 周晓龙, 余立平, 金亚青. 石油学报(石油加工), 2006, 22(): 99-103
11 Determination of Demulsibility Characteristics of urbine Oils in Service. National Standards of the People′s Republic of China. GB/ 76052008
运行中汽轮机油破乳化度测定法. 中华人民共和国标准. GB/ 76052008
12GUO ZhiMing, UANG WenQian, PENG YanKun, WANG Xiu, ANG XiuYing. Chinese J. Anal. Chem., 201, 2(): 513-518
郭志明, 黄文倩, 彭彦昆, 王 秀, 汤修映. 分析化学, 201, 2(): 513-518
13ranco A, Olivieri A C. Anal. Chim. Acta, 2011, 699(1): 18-25
1ilhoa A D, Galvaob R K , Araujo M C U. Chemometrics and Intelligent Laboratory Systems, 200, 72(1): 83-91
15BAO Xin, DAI LianKui. Chinese J. Anal. Chem., 2008, 36(1): 75-78
包 鑫, 戴连奎. 分析化学, 2008, 36(1): 75-78
16Wu D, e Y, eng S J, Sun D W. Journal of ood Engineering, 2008, 8(1): 12-131
AbstractNear infrared spectroscopy (NIRS) is capable of determining water contents in oils. owever, too much moisture contents in the oils will scatter rather than absorb the NIRS. his may cause greater measurement error. or this reason, a nonionic surfactant (Span80) was screened to make the water in the oils evenly dispersed into small droplets. he NIRS analysis was subsequently employed to build support vector regression (SVR) model of the water content. In this experiments, the upper limit of the water content determination was improved from the conventional 0.1% to 1.0% (V/V) by the oilwater stabilization. Applying successive projection algorithm, 15 valid variables (2.9% of the original ones) from 511 NIRS variables were selected. With the proposed SVR model, the measurement precision criteria for the validation dataset were root mean squares error percentage 2.93%, correlation coefficient 0.99, and relative percent derivation 9.732%.
KeywordsOilwater stabilization; Near infrared spectroscopy; Successive projection algorithm; Support vector regression; Water content in oil