# An Overview of IoT Sensor Data Processing, Fusion, and Analysis Techniques
## 4 Data Fusion
The fusion of two different sensor data measurements \(\alpha\) and \(\beta\), given a non-inform prior such as \(P(\alpha)\), is then given  
\[P(\alpha|\beta_{1},\beta_{2})\propto P(\alpha)L(\alpha;\beta_{1})L(\alpha; \beta_{2}) \tag{11}\]  
\[1\times exp\frac{1}{2}\bigg{(}\frac{\alpha-\beta_{1}}{\delta_{1}}\bigg{)}^{2} \times exp\frac{1}{2}\bigg{(}\frac{\alpha-\beta_{2}}{\delta_{2}}\bigg{)}^{2} \tag{12}\]  
_Kalman Filter Method:_ This is used to estimate the system state when it cannot be measured directly. It is an iterative mathematical process that uses a set of equations and data inputs measured over time, containing noise and inaccuracies. It produces estimates of these unknown parameters that are more accurate than those taken from a single sensor measurement, by using a joint distribution function over each timestep variable. It works as a two-step recursive algorithm, with a prediction and update step. In the prediction step, it estimates the current state of the variables along with the noises. Suppose the outcome of the new measurement is observed with some noise or uncertainty. In that case, the estimates are updated using a weighted average, assigning more weight to the estimates with higher certainty and less to estimates with low uncertainty. The estimated uncertainty of the predicted system's state is represented as a covariance matrix, and the weights are calculated. The new estimate of the weighted average is obtained from the weighted average that lies between the predicted and measured state, giving better-estimated uncertainty. This process is recursive until the filter follows the model predictions more closely. The Kalman filter model assumes the evolution of a state at time k from the state at (k - 1), according to the following equation. \[x_{k}=Fx_{k-1}+Au_{k-1}+w_{k-1} \tag{13}\]  
where \(F\) is the state transition matrix which is applied to previous state \(x_{k-1}\) vectors, and A is the control input matrix which is applied to the control vector \(u_{k-1}\). \(w_{k-1}\) is the noise vector that is assumed to be the multivariate Gaussian distribution drawn from the zero mean with the covariance \(Q_{k}\), where \(w_{k-1}\sim N(0,Q_{k})\). The measurement at time step k is observed as  
\[z_{k}=Hx_{k}+v_{k} \tag{14}\]  
where H is the measurement matrix, \(z_{k}\) is the measurement vector, and \(\
u_{k}\) is the measurement noise vector that is assumed to be a multivariate Gaussian distribution drawn from the zero mean with the covariance R, i.e., \(v_{k}\sim N(0,R)\). The objective of the Kalman filter is to provide an estimate of \(x_{k}\) at time k, given the initial estimate of \(x_{0}\), the series of measurements \(z_{1}\), \(z_{2}\),..., \(z_{k}\) and the information of the system described by F, A, H, Q and R.  
Three basic approaches can be used in multi-sensory data fusion or integration. _Direct fusion_: In this approach, all sensors are associated among themselves for classification. Thereafter, data-level integration or fusion happens. Once the associated data sensor's data are integrated, then data features are extracted. These data features help in the identification of objects with sensors. This direct fusion process is also known as joint identity declaration, where multiple sensors' association identities are declared jointly. The direct fusion process is formally designed as shown in Equations (15)-(18). \[\text{O}:\ S_{i}\to S_{j}\ \forall i\
eq j\ i\in[1,2,3,\ldots,n]\text{ and }j\in \{1,2,3,\ldots,n\} \tag{15}\]  
\[P:\ f_{fe}\left(f_{df}(f_{A}(O))\right) \tag{16}\]  
\[ID_{data\_extraction}(S_{i})=g(P) \tag{17}\]  
\[Q:ID_{declaration}(S_{i}) \tag{18}\]  
Here, \(S_{i}\) represents the \(i\)th sensor considered in the data fusion process, and \(O\) is the outcome of the \(i\)th sensor from \(j\)th sensor mapping. \(f_{A}(. )\), \(f_{df}(. )\) and \(f_{fe}(. )\) are the data association, internal data-level fusion, and feature extraction functions in the complete data fusion process.