# Residual Analysis of Predictive Modelling Data for Automated Fault Detection in Building’s Heating, Ventilation and Air Conditioning Systems

^{*}

## Abstract

**:**

## 1. Introduction

## 2. Description of Simulated Data and System Faults

## 3. Statistical Tests

#### 3.1. Moving p-Value

#### 3.2. Mean p-Value (MPV)

#### 3.3. Parameter Optimization in the Case of Observed Faults

#### 3.4. Parameter Optimization in the Case of Unobserved Faults

#### 3.4.1. Rate of Estimated Faults

#### 3.4.2. Restricting Areas

## 4. Results

#### 4.1. The Case of Observed Faults

#### 4.2. The Case of Unobserved Faults

#### 4.3. Comparison Prediction Models

## 5. Conclusions

## 6. Outlook

## Author Contributions

## Funding

## Conflicts of Interest

## Abbreviations

AFDD | Automated fault detection and diagnostics |

ARX | Autoregressive with exogenous variables |

C | Choice set |

FD | Fault detection |

FDD | Fault detection and diagnostics |

${R}^{2}$ | Coefficient of determination |

$(L,\alpha ,H)$ | Decision rule |

ECB | Energy in Buildings and Communities Programm |

${\widehat{y}}_{t}$ | Estimated total heating power |

$\mathsf{\Phi}(L,\alpha ,H)$ | Fault function |

H | Minimum number of MPV that have to assume a fault before in total a fault is assumed |

HVAC | Heating, Ventilation and Air Conditioning |

${I}_{A}(.)$ | Indicator function |

IEA | International Energy Agency |

MPV, ${\mathsf{\Gamma}}_{T,L}\left({\widehat{\u03f5}}_{t}\right)$ | Mean p-value |

MSE | Mean squared error |

${L}_{m}$, ${\alpha}_{m}$ and ${H}_{m}$ | Mode of L, $\alpha $, H |

${M}_{\tilde{\u03f5}}(s,L)$ | Moving residuals |

n | Number of observations |

${y}_{t}$ | Observed total heating power |

${p}_{T}(.)$ | p-value of the statistical test T |

${\widehat{\u03f5}}_{t}$ | Residual at time t |

G | Set of decision rules |

$\alpha $ | Significance level |

t | Time |

L | Time window length |

$\widehat{\u03f5}$ | Vector of residuals |

$\tilde{\u03f5}$ | $({\widehat{\u03f5}}_{1},\cdots ,{\widehat{\u03f5}}_{n},{\widehat{\u03f5}}_{1},\cdots {\widehat{\u03f5}}_{L-1})$ |

## References

- BMWi. Energieeffizienzstrategie Gebäude. Wege zu Einem Nahezu Klimaneutralen Gebäudebestand; Bundesministerium für Wirtschaft und Energie (BMWi) Öffentlichkeitsarbeit. Available online: www.bmwi.de (accessed on 11 August 2019).
- Mills, E. Building commissioning: A golden opportunity for reducing energy costs and greenhouse gas emissions in the United States. Energy Effic.
**2011**, 4, 145–173. [Google Scholar] [CrossRef][Green Version] - Dexter, A.; Pakanen, J. Conservation in Buildings and Community Systems—Technical Synthesis Report Annex 34; Technical Report; International Energy Agency: Paris, France, 2006. [Google Scholar]
- Lin, G.; Kramer, H.; Granderson, J. Building fault detection and diagnostics: Achieved savings, and methods to evaluate algorithm performance. Build. Environ.
**2020**, 168, 106505. [Google Scholar] [CrossRef][Green Version] - Mondal, B. Artificial Intelligence: State of the Art. In Recent Trends and Advances in Artificial Intelligence and Internet of Things; Balas, V.E., Kumar, R., Srivastava, R., Eds.; Springer: Cham, Switzerland, 2020; Volume 172, pp. 389–425. [Google Scholar] [CrossRef]
- Yan, K.; Shen, W.; Mulumba, T.; Afshari, A. ARX model based fault detection and diagnosis for chillers using support vector machines. Energy Build.
**2014**, 81, 287–295. [Google Scholar] [CrossRef] - Luo, B.; Wang, H.; Liu, H.; Li, B.; Peng, F. Early Fault Detection of Machine Tools Based on Deep Learning and Dynamic Identification. IEEE Trans. Ind. Electron.
**2019**, 66, 509–518. [Google Scholar] [CrossRef] - Kim, W.; Katipamula, S. A review of fault detection and diagnostics methods for building systems. Sci. Technol. Built Environ.
**2018**, 24, 3–21. [Google Scholar] [CrossRef] - Lo, N.G.; Flaus, J.M.; Adrot, O. Review of Machine Learning Approaches In Fault Diagnosis applied to IoT System. In Proceedings of the International Conference on Control, Automation and Diagnosis (ICCAD’19), Grenoble, France, 2–4 July 2019. [Google Scholar]
- Ge, Z.; Song, Z.; Ding, S.X.; Huang, B. Data Mining and Analytics in the Process Industry: The Role of Machine Learning. IEEE Access
**2017**, 5, 20590–20616. [Google Scholar] [CrossRef] - Mattera, C.; Quevedo, J.; Escobet, T.; Shaker, H.R.; Jradi, M. A Method for Fault Detection and Diagnostics in Ventilation Units Using Virtual Sensors. Sensors
**2018**, 18, 3931. [Google Scholar] [CrossRef] [PubMed][Green Version] - IEA ECB Annex 71. Building Energy Performance Assessment Based on In-Situ Measurements. 2016–2021. Available online: https://www.ecbcs.org/projects/project?AnnexID=71 (accessed on 15 November 2019).
- IEA ECB Annex 58. Reliable Building Energy Performance Characterisation Based on Full Scale Dynamic Measurements. 2011–2016. Available online: https://www.iea-ebc.org/projects/project?AnnexID=58 (accessed on 15 November 2019).
- Parzinger, M.; Hanfstaengl, L.; Sigg, F.; Wirnsberger, M.; Wellisch, U.; Spindler, U. Identifying faults in the building system based on model prediction and residuum analysis. E3S Web Conf.
**2020**, 172, 22001. [Google Scholar] [CrossRef] - Breiman, L. Random Forests. Mach. Learn.
**2001**, 45, 5–32. [Google Scholar] [CrossRef][Green Version] - Madsen, H. Time Series Analysis; Texts in Statistical Science, 72; Chapman and Hall/CRC: Boca Raton, FL, USA, 2008. [Google Scholar]
- Pruscha, H. Statistisches Methodenbuch: Verfahren, Fallstudien, Programmcodes; Springer: Berlin/Heidelberg, Germany, 2006. [Google Scholar]
- Box, G.E.P.; Jenkins, G.M.; Reinsel, G.C. Time Series Analysis; Forecasting and Control, 3rd ed.; Prentice Hall: Englewood Cliff, NJ, USA, 1994. [Google Scholar]
- Fassois, S.D.; Sakellariou, J.S. Time-series methods for fault detection and identification in vibrating structures. Philos. Trans. Ser. A Math. Phys. Eng. Sci.
**2007**, 365, 411–448. [Google Scholar] [CrossRef] [PubMed] - Strachan, P.; Svehla, K.; Heusler, I.; Kersken, M. Whole model empirical validation on a full-scale building. J. Build. Perform. Simul.
**2015**, 9, 331–350. [Google Scholar] [CrossRef][Green Version] - Kersken, M.; Heusler, I.; Strachan, P. Erstellung eines neuen, messdatengestützten Validierungsszenarios für Gebäudesimulationsprogramme. In Proceedings of the Fifth German-Austrian IBPSA Conference, RWTH Aachen University, Aachen, Germany, 22–24 September 2014; pp. 144–151. [Google Scholar]
- Strachan, P. Twin Houses Empirical Dataset: Experiment 1; University of Strathclyde: Glasgow, UK, 2015. [Google Scholar] [CrossRef]
- Strachan, P. Twin Houses Empirical Validation Dataset: Experiment 2; University of Strathclyde: Glasgow, UK, 29 February 2016. [Google Scholar] [CrossRef]
- Kersken, M.; Strachan, P. Twin House Experiment IEA EBC Annex 71 Validation of Building Energy Simulation Tools—Specifications and Dataset, Version: 2020-05-20 11:00:07.0; IBP Fraunhofer-Institut für Bauphysik: Holzkirchen, Germany, 2020. [Google Scholar] [CrossRef]
- IDA Indoor Climate and Energy (IDA ICE), Simulation Tool. 2019. Available online: https://www.equa.se/en/ida-ice (accessed on 29 April 2020).
- Fraunhofer Institute for Building Physics IBP. 2019. Available online: https://www.ibp.fraunhofer.de/en.html (accessed on 29 April 2020).
- R Version 3.6.1 (Action of the Toes). Available online: https://www.r-project.org/ (accessed on 29 April 2020).
- RStudio Team. RStudio: Integrated Development Environment for R; RStudio, Inc.: Boston, MA, USA, 2019. [Google Scholar]
- Wickham, H. ggplot2: Elegant Graphics for Data Analysis; Springer: New York, NY, USA, 2016. [Google Scholar]
- Wright, M.N.; Ziegler, A. ranger: A Fast Implementation of Random Forests for High Dimensional Data in C++ and R. J. Stat. Softw.
**2017**, 77, 1–17. [Google Scholar] [CrossRef][Green Version] - Ohtsu, K.; Peng, H.; Kitagawa, G. Time Series Modeling for Analysis and Control; Springer: Berlin/Heidelberg, Germany, 2015. [Google Scholar]
- Arnholt, A.T.; Evans, B. BSDA: Basic Statistics and Data Analysis. 2017. Available online: http://CRAN.R-project.org/package=BSDA (accessed on 15 November 2019).
- Wilcoxon Rank Sum and Signed Rank Tests. Available online: https://stat.ethz.ch/R-manual/R-devel/library/stats/html/wilcox.test.html (accessed on 15 November 2019).
- Hart, A.; Martínez, S. spgs: Statistical Patterns in Genomic Sequences. 2018. Available online: http://CRAN.R-project.org/package=spgs (accessed on 15 November 2019).
- Box Pierce and Ljung Box Tests. Available online: https://stat.ethz.ch/R-manual/R-patched/library/stats/html/box.test.html (accessed on 15 November 2019).
- Caeiro, F.; Mateus, A. Randtests: Testing Randomness in R. 2014. Available online: http://CRAN.R-project.org/package=randtests (accessed on 15 November 2019).

**Figure 1.**Summary of FD procedure. The focus of this study is on the fault detection area highlighted in light red.

**Figure 3.**Example for restricting C using adjacency, simplified for $H=7$. In green are the combinations of C, which are adjacent to a combination which assumes exactly one fault.

**Figure 4.**Fault estimate with decision rule $(106,11.2\%,8)$ for the ARX model and $(397,6.2\%,7)$ for the random forest model. The periods with faults in the data are marked in red. The y-axis indicates if the decision rule decided on faults.

**Figure 5.**Fault estimation with decision rule $(119,11.8\%,7)$ for the ARX model and $(101,20\%,8)$ for the random forest model. The periods with faults in the data are marked in red. The y-axis indicates if the decision rule decided on faults.

**Figure 6.**Fault estimation with decision rule $(84,10.4\%,8)$ for the ARX model and $(97,9.6\%,7)$ for the random forest model. The periods with faults in the data are marked in red. The y-axis indicates whether the decision rule decided on faults.

**Figure 7.**Fault estimate with decision rule $(392,3\%,7)$ for the ARX model and $(545,10.6\%,7)$ for the random forest model. The periods with faults in the data are marked in red. The y-axis indicates whether the decision rule decided on faults.

**Figure 8.**Rate of estimated faults for the first fault. In red, the period with fault, in green the period without fault, in blue is the median, and the mean of the estimated rates is in orange.

**Figure 9.**Rate of estimated faults for the second fault. In red, the period with fault, in green the period without fault, in blue is the median, and the mean of the estimated rates is in orange.

**Figure 10.**Rate of estimated faults for the third fault. In red, the period with fault, in green the period without fault, in blue is the median, and the mean of the estimated rates is in orange.

**Figure 11.**Rate of estimated faults with all faults. In red, the period with fault, in green the period without fault, in blue is the median, and the mean of the estimated rates is in orange.

**Figure 12.**Rate of estimated faults for the faultless data. In red, the period with fault, in green the period without fault, in blue is the median, and the mean of the estimated rates is in orange.

Room | Supply Air [m${}^{3}$/h] | Return Air [m${}^{3}$/h] |
---|---|---|

Living | 50 | 0 |

Sleeping | 50 | 0 |

Child 1 | 25 | 0 |

Child 2 | 25 | 0 |

Dining | 0 | 50 |

Bath | 0 | 50 |

Kitchen (open to Living) | 0 | 50 |

Room | Occupancy | Time Slots |
---|---|---|

Living and Kitchen | 3 Persons | 6:30–7:30 and 17:00–23:00 |

Sleeping | 2 Persons | 23:00–6:30 |

Child 1 | 1 Person | 23:00–6:30 |

Child 2 | 1 Person | 23:00–6:30 |

Dining | 3 Persons | 6:30–7:30 and 17:00–23:00 |

Bath | 1 Person | 6:30–7:30 and 17:00–23:00 |

Fault | Start | End | |
---|---|---|---|

F1 | Circuit breaker failure of the electrical heating in the upper floor | 2 February 0:00 | 4 February 23:59 |

F2 | MHVR summer bypass switch off the heat recovery during fault duration | 10 February 0:00 | 15 February 23:59 |

F3 | Living room thermostat to set temperature 28 ${}^{\circ}\mathrm{C}$ | 20 February 0:00 | 23 February 23:59 |

Indoor Properties | - air temperatures for each room |

- total heating power supplied by all electrical radiators | |

Outdoor Properties | - air temperature |

- relative humidity | |

- diffuse and direct solar irradiation on horizontal surfaces | |

- wind speed and wind direction |

**Table 5.**Example for the calculation of the rate of estimated faults. The number of decision rules that assume a fault is marked in blue.

Nr. Decision Rule | t = 1 | t = 2 | t = 3 | t = 4 | $\mathsf{\Sigma}>0$ |
---|---|---|---|---|---|

1 | 0 | 1 | 1 | 0 | True |

2 | 0 | 0 | 0 | 0 | False |

3 | 0 | 0 | 0 | 0 | False |

4 | 0 | 1 | 0 | 1 | True |

5 | 1 | 1 | 1 | 0 | True |

$\mathsf{\Sigma}$ | 1 | 3 | 2 | 1 | 3 |

$\mathsf{\Sigma}/{3}$ | 1/3 | 1 | 2/3 | 1/3 | |

$\mathsf{\Sigma}/{3}>1/2$ | False | True | True | False |

© 2020 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Parzinger, M.; Hanfstaengl, L.; Sigg, F.; Spindler, U.; Wellisch, U.; Wirnsberger, M.
Residual Analysis of Predictive Modelling Data for Automated Fault Detection in Building’s Heating, Ventilation and Air Conditioning Systems. *Sustainability* **2020**, *12*, 6758.
https://doi.org/10.3390/su12176758

**AMA Style**

Parzinger M, Hanfstaengl L, Sigg F, Spindler U, Wellisch U, Wirnsberger M.
Residual Analysis of Predictive Modelling Data for Automated Fault Detection in Building’s Heating, Ventilation and Air Conditioning Systems. *Sustainability*. 2020; 12(17):6758.
https://doi.org/10.3390/su12176758

**Chicago/Turabian Style**

Parzinger, Michael, Lucia Hanfstaengl, Ferdinand Sigg, Uli Spindler, Ulrich Wellisch, and Markus Wirnsberger.
2020. "Residual Analysis of Predictive Modelling Data for Automated Fault Detection in Building’s Heating, Ventilation and Air Conditioning Systems" *Sustainability* 12, no. 17: 6758.
https://doi.org/10.3390/su12176758