# Application and Optimization of Algorithms for Pressure Wave Evaluation Based on Measurement Data
## 3 Background and Motivation  
With detection, localization, and separation, Figure 3 shows three very generic but still relevant steps in the case of a large, spontaneous leakage where a network shutdown is imminent. The damaged network part has to be separated as fast as possible to secure network operation. For two of them, there are solutions that have proved themselves in practical operation. Leakage detection has been realized reliably by monitoring the refill mass flow in real time, as described in [7; 24]. As shown in Figure 2, fast separation of the damaged network part is possible due to the installed EAs. Hence, the crucial step is the localization of the leakage to separate the right EA from the rest of the network considered here. Localizing the leakage position in a network is a demanding task. In this paper, the localization was performed by evaluating the negative pressure wave. In the case of a leakage, the pressure drops at the leakage position, and a negative pressure wave propagates through the entire network and reaches each sensor at a different time point. The first step was the detection of a leakage, which was conducted by evaluating the refill mass flow. If the replenishment quantity started to increase, this was the leakage detection time point (LDTP). This process was described in detail in [7]. Then, the localization of the pressure wave consisted of two steps. In the first step, the PDTP for each sensor was estimated with one of the algorithms when the pressure wave was registered by the sensor. In the second step, these PDTPs were used to attribute the leakage location to the EAs. Both steps were already implemented in a prototype application in [7] that ran 24/7 without human interference. The last step was the remote separation of the affected EA. The focus of this paper was on the performance of algorithms to determine the PDTPs. Several events shown in Figure 3 were investigated in order to determine the PDTPs of  
Figure 3: Emergency management steps in the case of a large spontaneous leakage with imminent shutdown of network [10]. each sensor for localizing the leakage. In general, all nine algorithms were applied to the events to determine the PDTPs. Overall, the pressure curves belonging to one event were similar in shape but unique for each event; hence, the preselection of algorithms was difficult, as each of them had its advantages and disadvantages. As described in [11], the shape of the pressure wave, which is influenced by the superpositions of reflected portions of the pressure wave and portions travelling along different ways in a complex network, constituted an additional challenge to find the \"right\" PDTP. Table 1 displays an overview of the real events evaluated in this paper. If a leakage occurs or in the case of a refill process after maintenance work, there is a distinct increase of the refill mass flow at first. Afterwards, the refill mass flow stays approximately constant. The table shows the points in time of the start and end of the distinct increase at the beginning of each event with the respective replenishment quantities before and afterwards. In the case of a refill process, there can be several steps where refill mass flow rises, which correspond to the stepwise opening of a valve. This is performed to prevent a shutdown of network operation due to pressure falling below a minimal value. Furthermore, the differences between the quantities at the beginning and at the end (delta) are presented, as well as the speed of increase (gradient). For an event, the time point of a leakage occurrence is determined by the first increase of smooth replenishment [7]. This works also in the case of stepwise valve opening. Based on Figure 3, the localization step was divided into the determination of the PDTP and the attribution to exclusion area(s). The better the determination of the PDTPs, the better the localization functions [10]. In the scope of the current paper, there was the investigation of the best algorithm to determine the PDTP overall events.