Use of Regression Analysis to Determine the Model of Lighting Control in Smart Home with Implementation of KNX Technology Use of Regression Analysis to Determine the Model of Lighting Control in Smart Home with Implementation of KNX Technology

To optimize the management of operational and technical functions in the smart home (SH) and for use of effective methods of energy management in SH, it is generally nec essary to provide statistics and process relevant data from operational measurement devices. This chapter describes the use of modern methods for statistical data processing using regression analysis techniques. The aim of the analysis is to describe the depen - dence of single measured values using an appropriate mathematical model that can be efficiently implemented in the control system of SH. This model can be used for the func - tions of supervision and diagnostics of optimum comfort setting inside the indoor envi ronment of SH. Real experimental measurements of objective parameters of the indoor environment were realized in the selected rooms of unique wooden building in the pas sive standard. The researched methods were experimentally verified by classifying the behavior of lighting in the SH-selected rooms under specified conditions. The achieved experimental results will be used for the operating and technical functions control in SH for reducing the building operating costs.


Introduction
For monitoring, detection, and recognition of operating and technical conditions in SH, it is possible to use information from the measured data using operational sensors. Regression analysis can be used for the measured data processing and mathematical description of dependence between the measured quantities. Results from regression analysis can be used in SH concept [1], SH care concept [2] (for quantify the activity for a complex set of SH activities and predict cognitive health of participants [3]), smart metering concepts [4][5][6], for example in a new method for estimating the demand response potential of residential air conditioning (A/C), using hourly electricity consumption data ("smart meter" data) from customer accounts in Northern California [7], and smart grid concepts [8,9]. To visualize [10][11][12][13] and monitoring [14] of operational and technical functions in SH [15,16], it is necessary to use a robust visualization tool with reliable storage of measured data with respect to the needs of the SH inhabitants [17]. In our case, the measured data are read from the individual KNX technology and BACnet technology sensors by means of the Desigo Insight visualization tool. The individual KNX and BACnet technology components are used for the blinds, lighting, cooling, heating, and ventilation control in SH (Figures 1 and 2).  For analysis of the measured data to determine the model of lighting control in SH (Figures  1 and 2) built-in within the Moravian-Silesian Wood Cluster (MSDK), we used the regression analysis methods. The measured values of nonelectrical quantities (e.g., illuminance, CO 2 , temperature, humidity, etc.) in different rooms (e.g., rooms 202, 203, 204) of the building offer more information about the behavior of the operational and technical system in SH. Figure 3 shows the measured values of illuminance E 202 (lx), E 203 (lx), and E 204 (lx) in rooms 202, 203, and 204, respectively, and outdoor illuminance E out (lx).

Lighting control in SH using KNX technology
The actual lighting system for every room in SH is examined by using the DALI technology for dimming control and the KNX system for control by a closed-loop technology. The testing was performed on small lighting systems, the closed loop approach, which is adequate for illumination control to a constant illuminance E level, was used for the control.

Description of the KNX/DALI gateway system
The control options of the KNX/DALI gateway system (Figure 4) are not so extensive.
The sensor is connected directly to the KNX bus, whereby programming is facilitated. It should be noted that a bus-bar sensor must be selected in settings where information from the sensor needs to be transmitted to a large distance and hence, the hazard of data loss due to voltage decrease or interferences exists. The DALI ballasts are controlled by the KNX actuator (KNX/DALI Gateway N 141) and by one bus-bar sensor. The sensor at the ceiling sends information to the actuator, which evaluates light flux requirements in the master line.

Proposed experiment
The aim of the experiment was to explore the dependence of the measured waveforms of On the basis of the above-described conditions, a method for determining the optimal regression model to find the suitable mathematical description of states of operating and technical functions in SH was designed, in this case for lighting monitoring and control: Step 1: calculating the correlation coefficients to determine the strength of dependence between the measured values of illuminance E (lx) in each room and outdoors.
Step 2: using linear regression to determine the regression line.
Step 3: selecting the best regression model describing the mathematical relationships between the measured quantities based on the calculated coefficient of determination R 2 (R-squared) value.

Correlation analysis: description
The measured data processing and obtaining the information about the strength of statistical dependence between the measured values of illuminance E (lx) in SH (202, 203, and 204 rooms) can be carried out by means of the method of correlation analysis. The force of (linear) dependence between two measured nonelectrical quantities has been evaluated by means of the value of Pearson's correlation coefficient The correlation coefficient R x,y can take values from the closed interval <−1, +1>. The more the absolute value of the correlation coefficient approaches 1, the stronger the dependence of the random quantities.

Regression analysis: description
In terms of a mathematical description, this is a research of the relationship between two quantities, in which one of them, the so-called independent variable X (outdoor illuminance E (lx)), is to influence the other, the so-called dependent variable Y (measured illuminance E (lx) in each of the rooms 202, 203, and 204). Windows in rooms 203 and 204 are directed to the south and windows in room 202 are directed to the west (Figure 1). The results of selected individual measurements were processed into a plot of the fitted model with SW tool Statgraphics, which was used for a statistical analysis (Figures 5-8). The expected dependence between the studied variables, the so-called regression, was verified using this comprehensive statistical tool. The so-called linear regression was used which assumes a linear relationship between two quantities. Regression line equation can be written as: The estimate of the regression line is written in one of the following ways: where e i denotes a residue, error.
Using the SW tool Statgraphics, linear regression model (ANOVA) conditions were verified. Each figure (Figures 5-8) shows prediction models (green lines) and single 95% confidence intervals in each plot of fitted models. It is possible to define the interval estimation in regression for the expected value (green lines-confidence limits). The confidence interval for each measurement is identified as the prediction interval. Each of the charts show the equation of the regression line and coefficient of determination R 2 indicating the quality of regression model.
where SS R is the model sum of squares and SS E is the error sum of squares.

Measured values
Based on the above-described conditions, the following values were measured and calculated.
In terms of evaluating the correlation analysis, it is to confirm the assumption that the measured waveforms of illuminance E (lx) in rooms 203 and 204 have the greatest degree of similarity because the rooms are oriented to the south ( Table 1). Comparing the correlation coefficients ( Table 1) calculated from the measured illuminance E (lx) values in 202 to the remaining rooms 203 and 204, the rotation of the room 202 to the other side of cardinal points (west) is apparent (Figure 1). Figure 5 shows the plot of the fitted model for room 202, representing the linear regression model with R 2 = 0.527, it means that the model as fitted explains 52.7% of the variability of the illuminance in room 202. Figure 6 shows the plot of the fitted model for room 202, representing the logarithmic-Y square root-X regression model with R 2 = 0.804.
Based on the calculated value of the coefficient of determination R 2 ( Table 2), the logarithmic-Y square root-X model (Eq. (7)) ( Figure 6) was design as the optimal model for individual rooms.  The outdoor illuminance E out > 10,000 (lx) (weather is clear).
Based on the calculated value of the coefficient of determination R 2 ( Table 4), the logarithmic-Y square root-X model was design as the optimal model for rooms 203 and 204. However, the reciprocal-Y model was calculated as the optimal model for room 202 ( Table 4).
The plot of the fitted model for room 202 with linear regression model is shown in Figure 7.
The plot of the fitted model for room 202 with the reciprocal-Y regression model is shown in Figure 8.

Conclusion
This chapter described use of the regression analysis method to determine the regression model (linear regression model, reciprocal-Y regression model and logarithmic-Y square root-X regression model) of lighting control in SH with a potential use for the function of diagnosing the optimal settings for the corresponding comfort of interior lighting control

Regression Models R-Squared
Room 202 Logarithmic-Y square root-X 80.4% Room 203 Logarithmic-Y square root-X 68.0% Room 204 Logarithmic-Y square root-X 67.1% in SH rooms 202, 203, and 204 via the KNX technology. Based on the measured values, it was demonstrated that it is possible to determine a corresponding regression model of mathematical description of operational and technical function behaviors in SH under the specific conditions for the lighting control in this case. Since the P-value in the ANOVA table is less than 0.01, there is a statistically significant relationship between illuminance of the room and illuminance of outdoors at the 99% confidence level in each of cases. Since the P-value in the t-tests for both of parameters intercepts and slope is less than 0.01, there is not a reason to extract these parameters from models. Based on the experiments, the described regression models can be used to further classify and describe the behavior of operational and technical conditions in SH. A database for each of the measured quantities with a precise description of baseline conditions of the SH behavior will be presented with the next chapter. More modern methods for classification and identification [18][19][20][21][22][23] will be used for compare and optimization of the operational and technical functions control in SH.