CN107229970B - The adaptive dynamic self study on-line monitoring system of shared direct drinking water quality - Google Patents

The adaptive dynamic self study on-line monitoring system of shared direct drinking water quality Download PDF

Info

Publication number
CN107229970B
CN107229970B CN201710501486.0A CN201710501486A CN107229970B CN 107229970 B CN107229970 B CN 107229970B CN 201710501486 A CN201710501486 A CN 201710501486A CN 107229970 B CN107229970 B CN 107229970B
Authority
CN
China
Prior art keywords
state
time
covariance
neural network
state variable
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710501486.0A
Other languages
Chinese (zh)
Other versions
CN107229970A (en
Inventor
李太福
叶仪
李家庆
张堃
段棠少
王甜
唐海红
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Chongqing University of Science and Technology
Original Assignee
Chongqing University of Science and Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Chongqing University of Science and Technology filed Critical Chongqing University of Science and Technology
Priority to CN201710501486.0A priority Critical patent/CN107229970B/en
Publication of CN107229970A publication Critical patent/CN107229970A/en
Application granted granted Critical
Publication of CN107229970B publication Critical patent/CN107229970B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • G06N3/084Backpropagation, e.g. using gradient descent
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N33/00Investigating or analysing materials by specific methods not covered by groups G01N1/00 - G01N31/00
    • G01N33/18Water
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/213Feature extraction, e.g. by transforming the feature space; Summarisation; Mappings, e.g. subspace methods
    • G06F18/2135Feature extraction, e.g. by transforming the feature space; Summarisation; Mappings, e.g. subspace methods based on approximation criteria, e.g. principal component analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/10Interfaces, programming languages or software development kits, e.g. for simulating neural networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
    • G06Q50/06Energy or water supply
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02ATECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
    • Y02A20/00Water conservation; Efficient water supply; Efficient water use
    • Y02A20/152Water filtration

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Software Systems (AREA)
  • Business, Economics & Management (AREA)
  • Computing Systems (AREA)
  • Evolutionary Computation (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Computational Linguistics (AREA)
  • Biomedical Technology (AREA)
  • Molecular Biology (AREA)
  • Chemical & Material Sciences (AREA)
  • Biophysics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • General Business, Economics & Management (AREA)
  • Public Health (AREA)
  • Water Supply & Treatment (AREA)
  • Human Resources & Organizations (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Primary Health Care (AREA)
  • Strategic Management (AREA)
  • Tourism & Hospitality (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Evolutionary Biology (AREA)
  • Food Science & Technology (AREA)
  • Medicinal Chemistry (AREA)
  • Analytical Chemistry (AREA)
  • Biochemistry (AREA)
  • Immunology (AREA)
  • Pathology (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention discloses a kind of shared adaptive dynamic self study on-line monitoring methods of direct drinking water quality, including:S110 establishes neural network input sample collection;S120 establishes neural network output sample set;S130 obtains normalization sample set;S140 builds three layers of BP neural network model according to the normalization sample set;S150 carries out network weight threshold value dynamic according to three layers of BP neural network, with UKF algorithms and adjusts;S160 models the mass data accumulated on cloud server using UKFNN algorithms, obtains neural network parameter;S170 realizes prediction in real time to the influence factor of water quality in the constant water tank of real-time change;It is predicted in real time according to constant roof tank water quality, realizes and share the adaptive dynamic self study on-line monitoring of direct drinking water quality.The present invention provides shared direct drinking water quality dynamic self study on-line monitoring method and system, the technique effect or advantage having:Change traditional water way, provides a kind of quick, healthy, convenient water way to the user, meet people's fast pace life level and high-quality life level requirement.

Description

Shared direct drinking water quality self-adaptive dynamic self-learning online monitoring system
Technical Field
The invention relates to the field of mobile internet service, in particular to a self-adaptive dynamic self-learning online monitoring method and system for the water quality of shared direct drinking water.
Background
With the improvement of living standard, the economy develops rapidly, and the living idea of high quality and health is more and more favored by people. The drinking water mode at present in the market comprises direct drinking water and barreled mineral water, wherein the quality, the capacity and the price of the barreled mineral water are different, the quality of the barreled water cannot be ensured safely and healthily under the existing economic system, a large amount of barreled mineral water is in a 'good order' phenomenon in the market, and the barreled mineral water which is 'riot' and unqualified can bring potential threats to the physical health of people. Meanwhile, in fast-paced urban life, efficient time utilization makes people increasingly demand service products for convenience.
Disclosure of Invention
In view of the above, the present invention aims to provide a shared direct drinking water quality adaptive dynamic self-learning online monitoring method and system. The drinking problem of the direct drinking water is convenient, healthy and fast to solve, the water quality of the drinking water is guaranteed to be healthy, the real-time monitoring and real-time replacement of the water quality of the shared direct drinking water are realized, and the intelligent management of the shared direct drinking water is realized.
One of the purposes of the invention is realized by the following technical scheme, and the shared direct drinking water quality self-adaptive dynamic self-learning online monitoring method comprises the following steps: s110, establishing a neural network input sample set according to control parameters of the influence of the water quality in the constant water tank; s120, establishing a neural network output sample set according to the water quality index in the constant water tank measured in real time; s130, carrying out normalization processing on the input sample set and the output sample set to obtain a normalized sample set; s140, constructing a three-layer BP neural network model according to the normalized sample set; s150, dynamically adjusting a network weight threshold by using a UKF algorithm according to the three-layer BP neural network; s160, modeling mass data accumulated on the cloud server by using a UKFNN algorithm to obtain neural network parameters; s170, real-time prediction is realized on the influence factors of the water quality in the constant water tank which changes in real time; and the self-adaptive dynamic self-learning online monitoring of the water quality of the shared direct drinking water is realized according to the real-time prediction of the water quality of the constant water tank.
Further, after step S120, a preprocessing step is further included, where the preprocessing step specifically includes: and carrying out principal component extraction on the constructed modeling input sample set, and obtaining a new sample set.
Further, the control parameters affecting the water quality in the constant water tank include, determining an influencing factor affecting the water quality in the water tank, the influencing factor including: the filter element performance of the direct water dispenser, the area ID number, the accumulated water consumption of the direct water dispenser, the historical temperature real-time data of the water temperature in the water tank and the opening and closing state of the water outlet of the real-time water tank.
Further, according to the water quality index in the constant water tank measured in real time, a neural network output sample set is established, and the method comprises the following steps: through regular quality inspector patrolling and examining, the drinking water sample in the water tank is extracted to carry out water quality index detection and is transmitted to the cloud server in real time, and a neural network output sample set is obtained.
Further, principal component extraction is carried out on the state variable X by using a principal component analysis algorithm, and a new state variable X' ═ { X ] is constructedz1,xz2,L,xzmAnd X' are m state pivot components, and the dimension of each state pivot component is the same as the number of training samples in the input.
Further, in the step S150, the three-layer BP neural network comprises (M-S)1-l) topology, the hidden layer excitation function being an s-type function, the output layer being a linear function;
the number of input layer neurons is M, and the number of hidden layer nodes is determined by an empirical formulaAnd obtaining m, h and o which respectively represent the number of neurons of an input layer, a hidden layer and an output layer of the table, α is a constant of 1-10, the number of nodes of the output layer is 4, and then establishing an initial model as follows:
wherein, w1ik,w2kj,b1i,b2jRespectively representing the connection weight of the input layer and the hidden layer, the connection weight of the hidden layer and the output layer, the threshold value of the hidden layer and the threshold value of the output layer;indicating normalized samples, i, j are variable indices.
Further, modeling the mass data stored in the cloud server by using the UKFNN algorithm, and acquiring neural network parameters specifically comprises the following substeps:
the first step is as follows: setting BP neural network, recording M as input layer neuron number, s1The number of hidden layer neurons, and l is the number of output layer neurons; connection weights for input layer to hidden layer neuronsThe threshold value isConnection weight from hidden layer to output layerThe threshold value isThen the state matrix I composed of all weights and thresholds in the UKF neural network is:
setting the number of I as n values; setting a nonlinear equation:
Ikdenotes the state variable at time k, Ik+1Represents (k +1)Time of day state variable, ωk,vk,Respectively representing observation noise, a measurement nonlinear equation and measurement noise;
wherein, XkInputting a sample for the neural network at the time K; let omegak=0,vk=0,YkOutputting samples for the neural network; the second step is that: setting a distribution state parameter a and a parameter kappa to be selected of a control sampling point in a UKF calculation process;
the third step: calculating corresponding weights of 2n +1 sigma points and the sigma points, wherein n is the dimension of the state matrix I, and lambda is a2(n + κ) -n; sigma represents a sigma sampling point, and lambda is a scaling parameter;
the fourth step: one-step state prediction to compute sigma pointAnd state variable covariance Pk+1|k
The fifth step: one step prediction and covariance of computational output
And a sixth step: carrying out filtering updating to obtain a new state matrix, a new covariance matrix and a new gain matrix;
the seventh step: the second step to the sixth step are carried out again on the obtained new sample data until all the samples update the state matrix, the covariance matrix and the gain matrix;
eighth step: obtaining a state matrix I for the last group of samples as a weight and a threshold value obtained by the feedforward neural network training;
the ninth step: and according to the obtained weight and threshold of each layer of the network parameter, a function model constructed by the UKF neural network is utilized.
Further, in step S160, the algorithm flow for dynamically adjusting the weight threshold is as follows:
1) sigma sampling is carried out on the state matrix I to obtain 2n +1 sampling points, distribution state parameters α, candidate parameters kappa and non-negative weight coefficients β of the 2n +1 sampling points are initialized and controlled, and the Sigma sampling of the state matrix I is as follows:
wherein,the ith column of the optimal state variable estimate for time (k-1), n being the state matrix dimension, pk-1Covariance of the optimal state variable at time (k-1), Ik-1Is the state variable at the moment (K-1), and lambda is a scaling parameter;
2) calculating the weight of each sampling point, wherein the weight of each sampling point is as follows:
wherein, WcTo calculate the weight of the covariance of the state variables, WmTo compute the weights in the state estimation and observation prediction,is thatThe first column of (a) is,is thatThe first column of (1);
3) transforming the state estimate of the optimal state variable at time (k-1) for each sample point into a state estimate of the state variable at time k by the equation of state for a discrete-time nonlinear systemAnd by combining the state estimates at time kTo obtain a state prior estimate of the state variable at time kSum covariance Pk|k-1(ii) a Wherein,
the state estimationComprises the following steps:
f () represents the equation of state
Wherein, wkOf the covariance matrix QkIs cov (omega)kj)=QkδkjwjRepresenting state noise, cov (ω)kj) Representing state noise covariance;
the state prior estimateComprises the following steps:
covariance P of the state variablek|k-1Comprises the following steps:
4) establishing state estimates of state variables at time k by an observation equation of a discrete-time nonlinear systemAnd estimation of observed predictions at time kTo complete the observation prediction and estimate the covariance of the observation prediction at time k
The observed prediction estimation of the k timeComprises the following steps:
the final state variable is estimated as:
wherein, vkOf the covariance matrix RkIs cov (v)k,vj)=RkδkjvjRepresenting measurement noise; g (), f () respectively represent the excitation function of the output layer of the neural network and the excitation function of the hidden layer;
covariance of observed prediction of the k timeComprises the following steps:
5) calculating the covariance P between the state variable and the observed prediction at time kxy,k
6) By establishing a covariance Pxy,kSum covarianceUpdating the state estimation and covariance of the state variable at the moment k to obtain the optimal state variable at the moment k;
7) substituting the obtained optimal state variable at the moment k into the step 1) to perform sigma sampling again, and circulating the steps 1) -6) to obtain the optimal state variable of the neural network model;
wherein the covariance P is established by the step 6)xy,kSum covarianceUpdating the state estimation and covariance of the state variable at the time k to obtain the optimal state variable at the time k,
wherein, KkFor the gain matrix, thereby realizing the state estimation of the optimal state variable at the time of updating k and the covariance P of the state variable at the time of updating kk
State estimate I of the optimal state variable at the updated time kk|kComprises the following steps:
covariance P of state variable at time k after updatekComprises the following steps:
estimating the state of the state variable I at the updated k timekSum covariance PkAs the optimal state variable at time k.
The invention also aims to realize the following technical scheme that the shared direct drinking water quality self-adaptive dynamic self-learning online monitoring system comprises a control parameter selection unit, a modeling sample principal component extraction unit, a normalized sample acquisition unit, a UKFNN model construction unit and a constant water tank water quality detection unit, wherein the control parameter selection unit is used for selecting the control parameters according to the influence of the water quality in a constant water tank; specifically, according to a control parameter selection unit for controlling the influence of the water quality in the constant water tank, a control parameter for controlling the influence of the water quality in the constant water tank is selected;
a modeling sample principal component extraction unit which uses PCA principal component extraction;
the normalized sample acquisition unit is used for performing normalized processing on the parameters extracted by the Principal Component Analysis (PCA);
the UKFNN model building unit is used for carrying out model modeling by using mass data stored on the cloud server;
and (4) detecting the water quality of the constant water tank, and performing constant water tank water quality index prediction on new data generated on the cloud server by using the established model.
The beneficial technical effects are as follows:
the invention provides a quick, healthy and convenient shared direct drinking water device and system for users, which not only can ensure convenient drinking water, but also really realize healthy, quick and convenient drinking water, and finally realize a self-adaptive dynamic learning online detection system for the shared direct drinking water.
Drawings
FIG. 1 is a schematic flow chart of a shared direct drinking water quality adaptive learning online monitoring method;
FIG. 2 is a schematic diagram of a logic structure of a shared direct drinking water quality adaptive learning online monitoring system.
Detailed Description
The preferred embodiments of the present invention will be described in detail below with reference to the accompanying drawings; it should be understood that the preferred embodiments are illustrative of the invention only and are not limiting upon the scope of the invention.
The invention provides a shared direct drinking water quality dynamic self-learning online monitoring method, which comprises the following steps:
s110: establishing a neural network input sample set according to control parameters of the influence of the water quality in the constant water tank;
s120: establishing a neural network output sample set according to a real-time measured water quality index in the constant water tank;
s130: carrying out principal component extraction on the constructed modeling input sample set, reducing the redundancy of samples and obtaining a new sample set;
s140: carrying out normalization processing on the new sample to obtain a normalized sample set;
s150: constructing a three-layer BP neural network model according to the normalized sample set;
s160: according to the three-layer BP neural network, a UKF algorithm is used for dynamically adjusting the network weight threshold;
modeling mass data accumulated on a cloud server by using a UKFNN algorithm to obtain neural network parameters;
s170: on the basis of a known model, the real-time prediction of the water quality of the constant water tank is realized for the influence factors of the water quality in the constant water tank which changes in real time;
s180: the self-adaptive dynamic self-learning online monitoring of the water quality of the shared direct drinking water is realized according to the real-time prediction of the water quality of the constant water tank;
in step S110 and step S120, the performance of the filter element of the direct drinking machine, the area ID number, the accumulated water consumption of the direct drinking machine, the real-time data of the historical temperature of the water in the water tank, and the on-off state of the outlet of the real-time water tank are obtained, i.e. the model building input sample is obtained; through regular inspection by a quality inspector, a drinking water sample in the water tank is extracted for water quality index detection (microbial index, toxicological index, chemical index and radioactivity index), and is transmitted to a cloud server in real time, so that a model output sample is obtained;
wherein, the control parameters affecting the water quality in the constant water tank are shown in table 1 and table 2:
TABLE 2 parameter and symbol table
TABLE 2 parameter and symbol table
Wherein the accumulated water consumption from the shared direct drinking water filter to the water discharge amount in the constant water tank isCumulative water consumption time
In step S130, PCA principal component extraction; the principal component analysis algorithm extracts the principal component of the state variable X and constructs a new state variable X' ═ { X ═ Xz1,xz2,L,xzmM state pivot components, each having the same number of dimensions as the samples;
in step S140, the data is preprocessed. In the process of modeling by utilizing a neural network, the hidden layer node function is an S-type function, and the value range is [ -1,1 ]; in order to improve the accuracy of the modeling process, all collected samples are subjected to normalization processing. Namely: and mapping the parameter values of the sample set into the range of [ -1,1] by using a linear normalization method to obtain a normalized sample set.
In step S150, a three-layer BP neural network model is constructed according to the normalized sample set;
the three-layer neural network comprises (M-s)1-l) topology, the hidden layer excitation function being an s-type function, the output layer being a linear function;
the number of nodes of the input layer is M, namely the number of input samples, and the number of nodes of the hidden layer is determined by an empirical formulaIf α is a constant of 1-10 and the number of nodes in the output layer is 4, then the initial model is established as follows:
wherein, the function f () is an S-type function and is a hidden layer excitation function; w1ik,w2kj,b1k,b2jRespectively representing the connection weight of the input layer and the hidden layer, the connection weight of the hidden layer and the output layer, the threshold value of the hidden layer and the threshold value of the output layer;representing normalized samples.
In step S160, acquiring neural network parameters for the mass data accumulated on the cloud server by using the UKFNN algorithm; the mass data accumulated on the cloud server comprises the performance of a filter element of the direct water dispenser, an area ID number, the accumulated water consumption of the direct water dispenser, the historical temperature real-time data of the water temperature in the water tank and the on-off state of a water outlet of the real-time water tank, namely a model building input sample is obtained; through regular inspection by a quality inspector, a drinking water sample in the water tank is extracted for water quality index detection (microbial index, toxicological index, chemical index and radioactivity index), and is transmitted to a cloud server in real time, so that a model output sample is obtained;
modeling mass data stored by a cloud server by utilizing a UKFNN algorithm, in the process of acquiring neural network parameters,
the first step is as follows: setting BP neural network, recording M as input layer neuron number, s1The number of hidden layer neurons, l is the number of output layer neurons; connection weights for input layer to hidden layer neuronsThe threshold value isConnection weight from hidden layer to output layerThe threshold value isThen the state matrix I composed of all weights and thresholds in the UKF neural network is:
setting the number of I as n values; setting a nonlinear equation:
Ikdenotes the state variable at time k, Ik+1Represents the state variable, ω, at time (k +1)k,vk,Respectively representing observation noise, a measurement nonlinear equation and measurement noise;
wherein, XkInputting a sample for the neural network at the time K; let omegak=0,vk=0,YkOutputting samples for the neural network;
secondly, setting a distribution state parameter a, a parameter kappa to be selected and a non-negative weight coefficient β of a control sampling point in the UKF calculation process;
the third step: calculating corresponding weights for 2n +1 sigma points and sigma points, where n is the I dimension of the state matrix and λ ═ a2(n + k) -n, wherein k is a parameter to be selected, and a is a distribution state parameter;
the fourth step: one-step state prediction to compute sigma pointAnd state variable covariance Pk+1|k
The fifth step: one step prediction and covariance of computational output
And a sixth step: carrying out filtering updating to obtain a new state matrix, a new covariance matrix and a new gain matrix;
the seventh step: the second step to the sixth step are carried out again on the obtained new sample data until all the samples update the state matrix, the covariance matrix and the gain matrix;
eighth step: obtaining a state matrix X for the last group of samples as a weight and a threshold value obtained by the feedforward neural network training;
the ninth step: and according to the obtained weight and threshold of each layer of the network parameter, a function model constructed by the UKF neural network is utilized.
In step S160, the algorithm flow for dynamically adjusting the weight threshold is as follows:
1) sigma sampling is carried out on the state matrix I to obtain 2n +1 sampling points, distribution state parameters α, candidate parameters kappa and non-negative weight coefficients β of the 2n +1 sampling points are initialized and controlled, and the Sigma sampling of the state matrix I is as follows:
wherein,the ith column of the optimal state variable estimate for time (k-1), n being the state matrix dimension, pk-1Covariance of the optimal state variable at time (k-1), Ik-1Is the state variable at the moment (K-1), and lambda is a scaling parameter;
2) calculating the weight of each sampling point, wherein the weight of each sampling point is as follows:
wherein, WcTo calculate the weight of the covariance of the state variables, WmTo compute the weights in the state estimation and observation prediction,is thatThe first column of (a) is,is thatThe first column of (1);
3) transforming the state estimate of the optimal state variable at time (k-1) for each sample point into a state estimate of the state variable at time k by the equation of state for a discrete-time nonlinear systemAnd by combining the state estimates at time kTo obtain a state prior estimate of the state variable at time kSum covariance Pk|k-1(ii) a Wherein,
the state estimationComprises the following steps:
f () represents the equation of state
Wherein, wkCovariance matrix ofQkIs cov (omega)kj)=QkδkjwjRepresenting state noise, cov (ω)kj) Representing state noise covariance;
the state prior estimateComprises the following steps:
covariance P of the state variablek|k-1Comprises the following steps:
4) establishing state estimates of state variables at time k by an observation equation of a discrete-time nonlinear systemAnd estimation of observed predictions at time kTo complete the observation prediction and estimate the covariance of the observation prediction at time k
The observed prediction estimation of the k timeComprises the following steps:
the final state variable is estimated as:
wherein, vkOf the covariance matrix RkIs cov (v)k,vj)=RkδkjvjRepresenting measurement noise; g (), f () respectively represent the excitation function of the output layer of the neural network and the excitation function of the hidden layer;
covariance of observed prediction of the k timeComprises the following steps:
5) calculating the covariance P between the state variable and the observed prediction at time kxy,k
6) By establishing a covariance Pxy,kSum covarianceUpdating the state estimation and covariance of the state variable at the moment k to obtain the optimal state variable at the moment k;
7) substituting the obtained optimal state variable at the moment k into the step 1) to perform sigma sampling again, and circulating the steps 1) -6) to obtain the optimal state variable of the neural network model;
wherein the covariance P is established by the step 6)xy,kSum covarianceUpdating the state estimation and covariance of the state variable at the time k to obtain the optimal state variable at the time k,
wherein, KkFor the gain matrix, thereby realizing the state estimation of the optimal state variable at the time of updating k and the covariance P of the state variable at the time of updating kk
State estimate I of the optimal state variable at the updated time kk|kComprises the following steps:
covariance P of state variable at time k after updatekComprises the following steps:
estimating the state of the state variable I at the updated k timekSum covariance PkAs the optimal state variable at time k.
In step S170, on the basis of a known model, the real-time prediction of the water quality of the constant water tank is realized for the influence factors of the water quality in the constant water tank which changes in real time;
corresponding to the method, the invention discloses a shared direct drinking water quality dynamic self-learning online monitoring system and a device thereof, and figure 2 shows a logic structure of the shared direct drinking water quality dynamic self-learning online monitoring system and the device thereof according to the embodiment of the invention.
As shown in fig. 2, the shared direct drinking water quality dynamic self-learning online monitoring system and device includes a control parameter selection unit 210 according to the influence of water quality in the constant water tank, a modeling sample principal component extraction unit 220, a normalized sample acquisition unit 230, a UKFNN model construction unit 240, and a constant water tank water quality detection unit 250.
Specifically, according to the control parameter selection unit 210 for controlling the influence of the water quality in the constant water tank, the control parameter for controlling the influence of the water quality in the constant water tank is selected;
the modeling sample principal component extraction unit 220 uses PCA principal component extraction to reduce data redundancy and improve model precision;
the normalized sample acquisition unit 230 is used for performing normalization processing on the parameters extracted from the principal component of the PCA to realize the precision modeling;
the UKFNN model building unit 240 is used for carrying out model modeling by using mass data stored on the cloud server;
the constant water tank water quality detection 250 is used for predicting the constant water tank water quality index of the new data generated on the cloud server by using the established model;
wherein the unit 210 is selected according to the control parameters of the influence of the water quality in the constant water tank, the parameters including: the method comprises the steps of obtaining an input sample of a model building through the performance of a filter element of a direct water dispenser, an area ID number, accumulated water consumption of the direct water dispenser, real-time data of historical temperature of water in a water tank and the on-off state of a water outlet of the real-time water tank; through regular inspection by a quality inspector, a drinking water sample in the water tank is extracted for water quality index detection (microbial index, toxicological index, chemical index and radioactivity index), and is transmitted to a cloud server in real time, so that a model output sample is obtained;
among them, in the embodiment of the present invention, the UKFNN model construction unit 240,
the three-layer neural network comprises (M-s)1-l) topology, the hidden layer excitation function being an s-type function, the output layer being a linear function;
the number of nodes of the input layer is M, namely the number of input samples, and the number of nodes of the hidden layer is determined by an empirical formulaIf α is a constant of 1-10 and the number of nodes in the output layer is 4, then the initial model is established as follows:
wherein, the function F (X) is an S-type function and is a hidden layer excitation function; w1ik,w2kj,b1k,b2jRespectively representing the connection weight of the input layer and the hidden layer, the connection weight of the hidden layer and the output layer, the threshold value of the hidden layer and the threshold value of the output layer;representing normalized samples.
Modeling mass data stored by a cloud server by utilizing a UKFNN algorithm, in the process of acquiring neural network parameters,
the first step is as follows: setting BP neural network, recording M as input layer neuron number, s1The number of hidden layer neurons, l is the number of output layer neurons; connection weights for input layer to hidden layer neuronsThe threshold value isConnection weight from hidden layer to output layerThe threshold value isThen the state variable I composed of all weights and thresholds in the UKF neural network is:
setting the number of I as n values; setting a nonlinear equation:
wherein, XkInputting a sample for the neural network at the time K; let omegak=0,vk=0,YkOutputting samples for the neural network;
secondly, setting a distribution state parameter a, a parameter kappa to be selected and a non-negative weight coefficient β of a control sampling point in the UKF calculation process;
the third step: calculating corresponding weights for 2n +1 sigma points and sigma points, where n is the I dimension of the state matrix and λ ═ a2(n + k) -n, wherein k is a parameter to be selected, and a is a distribution state parameter;
the fourth step: one-step state prediction to compute sigma pointAnd state variable covariance Pk+1|k
The fifth step: one step prediction and covariance of computational output
And a sixth step: carrying out filtering updating to obtain a new state matrix, a new covariance matrix and a new gain matrix;
the seventh step: the second step to the sixth step are carried out again on the obtained new sample data until all the samples update the state matrix, the covariance matrix and the gain matrix;
eighth step: obtaining a state matrix X for the last group of samples as a weight and a threshold value obtained by the feedforward neural network training;
the ninth step: and according to the obtained weight and threshold of each layer of the network parameter, a function model constructed by the UKF neural network is utilized.
The UKF dynamic adjustment weight threshold algorithm flow is as follows:
1) sigma sampling is carried out on the initial state variable X to obtain 2n +1 sampling points, a distribution state parameter α, a candidate parameter k and a non-negative weight coefficient β of the 2n +1 sampling points are initialized and controlled, and the Sigma sampling of the initial state variable X is as follows:
wherein,the ith column of the optimal state variable estimate for time (k-1), n being the state matrix dimension, pk-1Covariance of the optimal state variable at time (k-1);
2) calculating the weight of each sampling point, wherein the weight of each sampling point is as follows:
wherein, WcTo calculate the weight of the covariance of the state variables, WmTo compute the weights in the state estimation and observation prediction,is thatThe first column of (a) is,is thatThe first column of (1);
3) transforming the state estimate of the optimal state variable at time (k-1) for each sample point into a state estimate of the state variable at time k by the equation of state for a discrete-time nonlinear systemAnd by combining the state estimates at time kTo obtain a state prior estimate of the state variable at time kSum covariance Pk|k-1(ii) a Wherein,
the state estimationComprises the following steps:
wherein, wkAs process noise, its covariance matrix QkIs cov (w)k,wj)=Qkδkj
The state prior estimateComprises the following steps:
covariance P of the state variablek|k-1Comprises the following steps:
4) establishing state estimates of state variables at time k by an observation equation of a discrete-time nonlinear systemAnd estimation of observed predictions at time kTo complete the observation prediction and estimate the covariance of the observation prediction at time k
Mean of the observed predictions at time kComprises the following steps:
wherein, vkTo observe noise, its covariance matrix RkIs cov (v)k,vj)=Rkδkj
Covariance of observed prediction of the k timeComprises the following steps:
5) calculating the covariance P between the state variable and the observed prediction at time kxy,k
6) By establishing a covariance Pxy,kSum covarianceUpdating the state estimation and covariance of the state variable at the moment k to obtain the optimal state variable at the moment k;
7) and substituting the obtained optimal state variable at the moment k into the step 1) to perform sigma sampling again, and circulating the steps 1) -6) to obtain the optimal state variable of the neural network model.
Wherein the covariance P is established by the step 6)xy,kSum covarianceUpdating the state estimation and covariance of the state variable at the time k to obtain the optimal state variable at the time k,
wherein, KkFor the gain matrix, thereby realizing the state estimation of the optimal state variable at the time of updating k and the covariance P of the state variable at the time of updating kk(ii) a And the number of the first and second groups,
state estimation X of the optimal state variable at the updated k timek|kComprises the following steps:
covariance P of state variable at time k after updatekComprises the following steps:
estimating the state of the state variable X at the updated k timekSum covariance PkAs the optimal state variable at time k.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and it is apparent that those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (4)

1. The shared direct drinking water quality self-adaptive dynamic self-learning online monitoring method is characterized by comprising the following steps of: the method comprises the following steps:
s110, establishing a neural network input sample set according to control parameters of the influence of the water quality in the constant water tank;
s120, establishing a neural network output sample set according to the water quality index in the constant water tank measured in real time;
s130, carrying out normalization processing on the input sample set and the output sample set to obtain a normalized sample set;
s140, constructing a three-layer BP neural network model according to the normalized sample set;
s150, dynamically adjusting a network weight threshold by using a UKF algorithm according to the three-layer BP neural network;
s160, modeling mass data accumulated on the cloud server by using a UKFNN algorithm to obtain neural network parameters;
s170, real-time prediction is realized on the influence factors of the water quality in the constant water tank which changes in real time; the self-adaptive dynamic self-learning online monitoring of the water quality of the shared direct drinking water is realized according to the real-time prediction of the water quality of the constant water tank; the control parameters influencing the water quality in the constant water tank comprise the influence factors influencing the water quality in the water tank, and the influence factors comprise: the filter element performance of the direct drinking machine, the area ID number, the accumulated water consumption of the direct drinking machine, the historical temperature real-time data of the water temperature in the water tank and the opening and closing state of the water outlet of the real-time water tank;
according to the water quality index in the constant water tank measured in real time, a neural network output sample set is established, and the method comprises the following steps: through regular inspection by a quality inspector, a drinking water sample in a water tank is extracted to carry out water quality index detection and is transmitted to a cloud server in real time, and a neural network output sample set is obtained;
in the step S150, the process is repeated,
the three-layer BP neural network comprises (M-s)1-l) topology, the hidden layer excitation function being an s-type function, the output layer being a linear function; the number of input layer neurons is M, and the number of hidden layer nodes is determined by an empirical formulaObtained of, M, s1And l respectively represents the number of neurons of the input layer, the hidden layer and the output layer of the table, α is a constant of 1-10, the number of nodes of the output layer is 4, and then the initial model is established as follows:
wherein,respectively representing the connection weight of the input layer and the hidden layer, the connection weight of the hidden layer and the output layer, the threshold value of the hidden layer and the threshold value of the output layer;representing normalized samples, i, j are both variable indices; the function f () is an S-type function;
the modeling of mass data stored in a cloud server by using a UKFNN algorithm and the acquisition of neural network parameters specifically comprise the following substeps:
the first step is as follows: setting BP neural network, input layer to hidden layer neuron connection weightThe threshold value isConnection weight from hidden layer to output layerThe threshold value isThen the state matrix I composed of all weights and thresholds in the UKF neural network is:
setting the number of I as n values; setting a nonlinear equation:
Ikdenotes the state variable at time k, Ik+1Represents the state variable, ω, at time (k +1)kk,Individual watchDisplaying observation noise, measuring a nonlinear equation, and measuring noise;
wherein, XkInputting a sample for the neural network at time k; let omegak=0,vk=0,YkOutputting samples for the neural network;
the second step is that: setting a distribution state parameter a and a parameter kappa to be selected of a control sampling point in a UKF calculation process;
the third step: calculating corresponding weights of 2n +1 sigma points and the sigma points, wherein n is the dimension of the state matrix I, and lambda is a2(n + κ) -n; sigma represents a sigma sampling point, and lambda is a scaling parameter;
the fourth step: one-step state prediction to compute sigma pointAnd state variable covariance Pk+1|k
The fifth step: one step prediction and covariance of computational output
And a sixth step: carrying out filtering updating to obtain a new state matrix, a new covariance matrix and a new gain matrix;
the seventh step: the second step to the sixth step are carried out again on the obtained new sample data until all the samples update the state matrix, the covariance matrix and the gain matrix;
eighth step: obtaining a state matrix I for the last group of samples as a weight and a threshold value obtained by the feedforward neural network training;
the ninth step: and according to the obtained weight and threshold of each layer of the network parameter, a function model constructed by the UKF neural network is utilized.
2. The self-adaptive dynamic self-learning online monitoring method for the quality of the shared direct drinking water as claimed in claim 1, is characterized in that: the step S120 is followed by a preprocessing step, wherein the preprocessing step specifically comprises: and carrying out principal component extraction on the constructed modeling input sample set, and obtaining a new sample set.
3. The self-adaptive dynamic self-learning online monitoring method for the quality of the shared direct drinking water as claimed in claim 2, characterized in that: extracting the principal component of the state variable X by using a principal component analysis algorithm to construct a new state variable X' ═ { X }z1,xz2,…,xzmAnd X' are m state pivot components, and the dimension of each state pivot component is the same as the number of training samples in the input.
4. The self-adaptive dynamic self-learning online monitoring method for the quality of the shared direct drinking water as claimed in claim 1, is characterized in that: in step S150, the algorithm flow for dynamically adjusting the weight threshold is as follows:
1) sigma sampling is carried out on the state matrix I to obtain 2n +1 sampling points, distribution state parameters α, candidate parameters kappa and non-negative weight coefficients β of the 2n +1 sampling points are initialized and controlled, and the Sigma sampling of the state matrix I is as follows:
wherein,the ith column of the optimal state variable estimate for time (k-1), n being the state matrix dimension, pk-1Covariance of the optimal state variable at time (k-1), Ik-1Is the state variable at the moment (K-1), and lambda is a scaling parameter;
2) calculating the weight of each sampling point, wherein the weight of each sampling point is as follows:
wherein, WcTo calculate the weight of the covariance of the state variables, WmTo compute the weights in the state estimation and observation prediction,is thatThe first column of (a) is,is thatThe first column of (1);
3) transforming the state estimate of the optimal state variable at time (k-1) for each sample point into a state estimate of the state variable at time k by the equation of state for a discrete-time nonlinear systemAnd by combining the state estimates at time kTo obtain a state prior estimate of the state variable at time kSum covariance Pk|k-1(ii) a Wherein,
the state estimationComprises the following steps:
f () represents the equation of state
Wherein, wkOf the covariance matrix QkIs cov (omega)kj)=QkδkjwjRepresenting state noise, cov (ω)kj) Representing state noise covariance;
the state prior estimateComprises the following steps:
covariance P of the state variablek|k-1Comprises the following steps:
4) establishing state estimates of state variables at time k by an observation equation of a discrete-time nonlinear systemAnd estimation of observed predictions at time kTo complete the observation prediction and estimate the covariance of the observation prediction at time k
The observed prediction estimation of the k timeComprises the following steps:
the final state variable is estimated as:
wherein, vkOf the covariance matrix RkIs cov (v)k,vj)=RkδkjvjRepresenting measurement noise; g (), f () respectively represent the excitation function of the output layer of the neural network and the excitation function of the hidden layer;
covariance of observed prediction of the k timeComprises the following steps:
5) calculating the covariance P between the state variable and the observed prediction at time kxy,k
6) By establishing a covariance Pxy,kSum covarianceUpdating the state estimation and covariance of the state variable at the moment k to obtain the optimal state variable at the moment k;
7) substituting the obtained optimal state variable at the moment k into the step 1) to perform sigma sampling again, and circulating the steps 1) -6) to obtain the optimal state variable of the neural network model;
wherein the covariance P is established by the step 6)xy,kSum covarianceUpdating the state estimation and covariance of the state variable at the time k to obtain the optimal state variable at the time k,
wherein, KkFor the gain matrix, thereby realizing the state estimation of the optimal state variable at the time of updating k and the covariance P of the state variable at the time of updating kk
State estimate I of the optimal state variable at the updated time kk|kComprises the following steps:
covariance P of state variable at time k after updatekComprises the following steps:
estimating the state of the state variable I at the updated k timekSum covariance PkAs the optimal state variable at time k.
CN201710501486.0A 2017-06-27 2017-06-27 The adaptive dynamic self study on-line monitoring system of shared direct drinking water quality Active CN107229970B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710501486.0A CN107229970B (en) 2017-06-27 2017-06-27 The adaptive dynamic self study on-line monitoring system of shared direct drinking water quality

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710501486.0A CN107229970B (en) 2017-06-27 2017-06-27 The adaptive dynamic self study on-line monitoring system of shared direct drinking water quality

Publications (2)

Publication Number Publication Date
CN107229970A CN107229970A (en) 2017-10-03
CN107229970B true CN107229970B (en) 2018-08-17

Family

ID=59935690

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710501486.0A Active CN107229970B (en) 2017-06-27 2017-06-27 The adaptive dynamic self study on-line monitoring system of shared direct drinking water quality

Country Status (1)

Country Link
CN (1) CN107229970B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110794689A (en) * 2018-08-01 2020-02-14 珠海格力电器股份有限公司 Configuration parameter determination method and device for water purifier
CN111210128B (en) * 2019-12-27 2023-04-11 广东工业大学 Wetland early warning method based on artificial intelligence and random self-adaptive threshold
CN111487386A (en) * 2020-03-30 2020-08-04 江苏大学 Automatic detection method for water quality parameters of large-area river crab culture pond
CN113505649B (en) * 2021-06-10 2023-11-17 广州杰赛科技股份有限公司 Tap water chlorination control method and device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102737288A (en) * 2012-06-20 2012-10-17 浙江大学 Radial basis function (RBF) neural network parameter self-optimizing-based multi-step prediction method for water quality
CN105021790A (en) * 2015-08-13 2015-11-04 丘璇 Water quality monitoring system and method
CN105046326A (en) * 2015-03-13 2015-11-11 重庆科技学院 Oil pumping unit parameter optimization method based on indicator diagram principal component analysis
CN106773667A (en) * 2016-11-14 2017-05-31 重庆科技学院 Based on the oil field production parameterses modeling method without mark particle filter neutral net

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102737288A (en) * 2012-06-20 2012-10-17 浙江大学 Radial basis function (RBF) neural network parameter self-optimizing-based multi-step prediction method for water quality
CN105046326A (en) * 2015-03-13 2015-11-11 重庆科技学院 Oil pumping unit parameter optimization method based on indicator diagram principal component analysis
CN105021790A (en) * 2015-08-13 2015-11-04 丘璇 Water quality monitoring system and method
CN106773667A (en) * 2016-11-14 2017-05-31 重庆科技学院 Based on the oil field production parameterses modeling method without mark particle filter neutral net

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于GIS和WSN的滇池水质实时监测与预测系统的开发与实现;彭彬;《中国优秀硕士学位论文全文数据库工程科技Ⅰ辑》;20160215;第2016年卷(第02期);全文 *

Also Published As

Publication number Publication date
CN107229970A (en) 2017-10-03

Similar Documents

Publication Publication Date Title
CN107229970B (en) The adaptive dynamic self study on-line monitoring system of shared direct drinking water quality
CN111222698B (en) Internet of things-oriented ponding water level prediction method based on long-time and short-time memory network
Sudheer et al. Estimating actual evapotranspiration from limited climatic data using neural computing technique
Kalogirou Long-term performance prediction of forced circulation solar domestic water heating systems using artificial neural networks
Bardossy et al. Fuzzy rule-based downscaling of precipitation
CN103730006A (en) Short-time traffic flow combined forecasting method
CN108874959A (en) A kind of user's dynamic interest model method for building up based on big data technology
CN108280552A (en) Methods of electric load forecasting and system, storage medium based on deep learning
CN110991690A (en) Multi-time wind speed prediction method based on deep convolutional neural network
CN103942461A (en) Water quality parameter prediction method based on online sequential extreme learning machine
CN110414088B (en) Space fuzzy evaluation method for suitability of birds-involved habitat by combining hydrodynamic model
Li et al. Real-time flood forecast using the coupling support vector machine and data assimilation method
Ni et al. Evolutionary modeling for streamflow forecasting with minimal datasets: a case study in the West Malian River, China
Abudu et al. Modeling of daily pan evaporation using partial least squares regression
CN107192802B (en) Shared direct drinking on-line water quality monitoring method and system
Mediero et al. Probabilistic calibration of a distributed hydrological model for flood forecasting
Sanikhani et al. Comparison of different data-driven approaches for modeling lake level fluctuations: the case of Manyas and Tuz Lakes (Turkey)
CN113393057A (en) Wheat yield integrated prediction method based on deep fusion machine learning model
CN107945534A (en) A kind of special bus method for predicting based on GMDH neutral nets
CN116364203A (en) Water quality prediction method, system and device based on deep learning
Kurt Determination of the most appropriate statistical method for estimating the production values of medium density fiberboard
CN108877224A (en) A kind of Short-time Traffic Flow Forecasting Methods carrying out Estimating Confidence Interval
CN115618720A (en) Soil salinization prediction method and system based on altitude
CN105568732A (en) Disc mill control method
CN117408171A (en) Hydrologic set forecasting method of Copula multi-model condition processor

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant