IoT-based Lava Flood Early Warning System with Rainfall Intensity Monitoring and Disaster Communication Technology

A lava flood disaster is a volcanic hazard that often occurs when heavy rains are happening at the top of a volcano. This flood carries volcanic material from upstream to downstream of the river, affecting populous areas located quite far from the volcano peak. Therefore, an advanced early warning system of cold lava floods is inarguably vital. This paper aims to present a reliable, remote, Early Warning System (EWS) specifically designed for lava flood detection, along with its disaster communication system. The proposed system consists of two main subsystems: lava flood detection and disaster communication systems. It utilizes a modified automatic rain gauge; a novel configured vibration sensor; Fuzzy Tree Decision algorithm; ESP microcontrollers that support IoT, and disaster communication tools (WhatsApp, SMS, radio communication). According to the experiment results, the prototype of rainfall detection using the tipping bucket rain gauge sensor can measure heavy and moderate rainfall intensities with 81.5% accuracy. Meanwhile, the prototype of earthquake vibration detection using a geophone sensor can remove noise from car vibrations with a Kalman filter and measure vibrations in high and medium intensity with an accuracy of 89.5%. Measurements from sensors are sent to the webserver. The disaster mitigation team uses data from the webserver to evacuate residents using the disaster communication method. The proposed system was successfully implemented in Mount Merapi, Indonesia, coordinated with the local Disaster Deduction Risk (DDR) forum.

Despite its advantages, disaster management systems that are based on satellite images still have some serious limitations. Like any image-based disaster management system, most satellite images have low-quality pictures or require manual image processing and operations; it still needs advanced image processing. Moreover, satellite-based communication systems sometimes require more complex tools. Some researchers then tried to combine artificial intelligence with satellite systems to solve this issue while detecting or mapping floods, such as in Amitrano et al. (2018) [11]. However, with big data and IoT trending, many IoT-based disaster management systems have emerged since then [12,13]. IoT shares similar remote-sensing ability and data interconnection but offers a simpler design and practical implementation than satellites. Hence, its applications vary widely from large-scale disaster management, such as proposed in Mouradian et al. (2018) [14], to specific localized systems such as radiation localization proposed in Alagha et al. (2019) [15]. Combined with UAV, a robust and power-efficient remote-surveillance system can be made as in   [16][17][18].
However, UAVs are mostly designed for image-based systems; thus, they are unsuitable for lava flood detection. Machine learning and artificial intelligence are more suitable for disaster scenarios [19] or early prediction [20] to create an early warning system for lava floods. Some researchers have combined IoT with various methods in machine learning and artificial intelligence for disaster management systems, such as in Pandey et al. (2020) [21]. The implementations are mostly for detection systems [22][23][24]. Among all machine learning and artificial intelligence methods, fuzzy-based methods are the most suitable for monitoring and early warning systems. Fuzzy-based systems can have similar conceptual knowledge to their designers; multi-input and multi-output decision-making systems are also available. For example, a flood detection system can be made based on fuzzy logic [25]. Moreover, a combination of IoT with a decision tree algorithm was proposed for flood detection and notification, which resulted in good accuracy and performance [26]. Flood monitoring systems usually are correlated to rainfall intensity instrumentation systems since heavy rainfall is usually the primary cause of flood disasters. A water level sensor has been used to measure rainfall intensity, which was connected to a Raspberry PI for a low-cost flood monitoring system using a neural network algorithm studied by Rani et al. (2020) [27].
However, research about cold lava flood detection and warning systems is still profoundly limited to this date. Even though systems designed for floods generally can also be used for lava flood detection systems, some sensors and signal conditioning systems must be adequately modified and chosen to ensure good performance and reliability. Previous research had proposed IoT-based Automatic Rain Gauge (ARG) prototype, which measured and classified rainfall into several categories [28]. However, the possibility of the prototype getting false positive warnings is likely high since the prototype only relied on one primary sensor; there is no redundant transducer or backup communication plan. It is proven that seismic ground vibrations give advanced early warning of subglacial floods [29] and indicators for lahar (cold lava) floods [30]. Thus, vibration sensors can play a role in detecting cold lava flood disasters. Based on study results from the aforementioned references, this research aims to create a reliable, remote, Early Warning System (EWS) specifically designed for lava flood detection, along with its disaster communication system. The paper will be written in structure as follows. The first section is the introduction. Next, the theoretical review will be written in the second section. The third section is the research methods. After that, experiment results and discussions will be written in the following section. The fifth section is the conclusion. The sixth section is the acknowledgments. Then, the last section is the list of references used in the research.

2-1-Kalman Filter
Kalman filter is an algorithm that can be used to estimate a value based on known data. Kalman filter has many applications, i.e., to filter noise. However, the primary function of the Kalman filter is not to filter the incoming signal but to estimate it according to the given input. Several previous researchers have conducted estimation research using the Kalman filter. Diagnosis of Railway Suspension System Disorders using the Cubature Kalman Filter Technique was investigated by Zoljic-Beglerovic et al. (2018) [31]. An adaptive Extended Kalman filter to monitor and estimate key aircraft flight parameters was studied by Alcalay et al. (2018) [32]. The Kalman filter augmented data cleansing to estimate a robust state-space model was investigated [33]. An integrated wind turbine failure prognostic approach that implements Kalman more smoothly with confidence limits was investigated by Saidi et al. (2018) [34]. An iterative cubature unscented Kalman filter for the identification of large DoF systems with noisy data was investigated [35]. The estimation of single plane unbalances parameters of the rotor-bearing system using the Kalman filter-based force estimation technique was investigated by Shrivastava et al. (2018) [36]. An adaptive physics-based reduced-order model of an aged lithium-ion cell, selected using the interacting multi-model Kalman filter, was investigated by Smiley et al. (2018) [37]. Revisited the extended dual Kalman filter for approximate charging state and battery health state was studied [38]. The Kalman cubature filter of the maximum corentropy square root with application to the integrated SINS/GPS system was investigated by Liu et al. (2018) [39]. Noise Reduction Method for MEMS Gyroscope Based on Direct Modeling and Kalman Filter was investigated by Cai et al. (2018) [40].
In this study, the Kalman filter serves to filter angle data from the accelerometer sensor. A microcontroller will then process the data. The Kalman filter equation consists of two parts: the prediction section and the update section.

Prediction:
Update: where ̂ is the state estimate, is the transition matrix, is the control variable, is the control matrix, is the state variation matrix, is the process variation matrix, is the measurement variable, is the calculation matrix, is the kalman reinforcement, is measurement variation matrix.
In the case of filtering sensor data, the Kalman filter equation for the prediction and update section needs to be adjusted and modified. This is because not all variables are needed for a particular case. However, it is possible to use all variables in certain cases. The results of the modification of the Kalman filter equation are as follows.

2-2-Decision Tree
The decision tree is a very popular and practical approach in machine learning to solve classification problems. The decision tree is a predictive model that uses a hierarchical structure, consisting of a set of IF-THEN rules. Each path in the tree is associated with a rule, where the premise consists of a set of nodes encountered, and the conclusion of the rule consists of classes associated with the leaf of the path. In a decision tree, a leaf node is assigned a class label.
Non-terminal nodes, which consist of the root and other internal nodes, contain attribute test conditions to separate records that have different characteristics. Edges can be labeled with numeric-symbolic values. A numeric-symbolic attribute is an attribute that can be either a numeric or a symbolic value associated with a quantitative variable. Previous researchers have widely studied decision tree algorithms. An optimization algorithm for decision trees and prediction of displacement horizons for landslide monitoring was investigated by Zhao et al. (2018) [41]. Intra-Fast Decision Mode Based on Machine Learning for Encoding HEVC Screen Content via Decision Tree researched by Kuang et al. (2020) [42]. POLSAR Image Classification that Can be Interpreted Based on the Adaptive Dimension Feature Spatial Decision Tree was investigated by Yin et al. (2020) [43]. Selection of Data-Based Relays for Physical Layer Security: Decision Tree Approach researched by   [44]. New Splitting Criteria for Decision Trees in Stationary Data Streams were investigated by Jaworski et al. (2018) [45].
The use of fuzzy techniques allows predicting an object that belongs to more than one class. Fuzzy decision trees make it possible to use numeric-symbolic values during construction or when classifying new cases. The benefit of fuzzy set theory in the decision tree is that it increases the ability to understand decision trees when using quantitative attributes.

Calculation of Mean Areal Rainfall/Precipitation
Rainfall required to calculate flood discharge is the maximum daily rainfall data in the entire area concerned, not rainfall at a certain point. This rainfall is called regional/regional rainfall and is expressed in mm. One approach to determine the average maximum daily rainfall in a watershed is to use the Thiessen method with the Equation 11: where is the average rain height, 1 ⋯ is the rain height at each observation point, 1 ⋯ is the area bounded by polygon lines

Flood Discharge Computation with Rational Method
The Rational Method is the most frequently used method for estimating the discharge in a watershed without observation data. Peak discharge is a function of watershed area, rain intensity, and the ground surface conditions, which is expressed in the runoff coefficient and the slope. Flood discharge is generically formulated as follows where is peak discharge ( 3 / ), is coefficient of runoff, is rainfall intensity with duration equal to flood ( /ℎ ), is the watershed area ( 2 ). ( ) Surface Flow Coefficient is a ratio value between runoff and rainfall intensity for a certain catchment area. In fact, this coefficient is calculated from the amount of resistance or loss from rainfall so that it becomes surface runoff. The magnitude of this loss depends on vegetation conditions, infiltration, surface ponds, and evapotranspiration. The runoff coefficient ( ) can be seen in Table 1. Meanwhile, rain intensity is the height of rainfall in a certain period expressed in mm/hour. The Mononobe formula is used to determine the amount of rain intensity, as in Equation 13.
where is rainfall intensity, 24 is maximum daily rainfall, is rainfall time (hours)

3-System Design
The lava flood early warning system proposed in the research was implemented in Mount Merapi, Indonesia. Prior to implementation, the proposed system was tested in lab-scale experiments to evaluate the performance of sensors and interdependent subsystems. The proposed lava flood early warning system has two main subsystems that work interdependently to help stakeholders communicate and evacuate people. The first subsystem is an IoT-supported lava flood detection system, and is placed upstream around Mount Merapi. The second subsystem is a disaster communication method used for stakeholders to alert for emergency evacuation and communicate through the evacuation process of residents around the lava flood area. The second subsystem is located downstream. This research utilizes a modified automatic rain gauge and a proposed low-cost vibration sensor. The automatic rain gauge was designed to measure mean areal rainfall that can indicate lava floods that may happen soon. Meanwhile, the vibration sensor, made from piezoelectric sensors, was designed to detect materials flown by the cold lava floods, which was proposed to be the primary detection tool of lava flood occurrence. The measurement from several automatic rain gauges will serve as inputs to calculate flood discharge. Then, those measurements (mean areal rainfall, flood discharge, measurement read from the vibration sensor) will be input to fuzzy decision tree algorithms. If the output of the decision-making algorithm is classified into a certain category, the system will send a warning message via IoT servers, WhatsApp, and SMS to related stakeholders. The proposed algorithm for lava flood detection is implemented in the first subsystem. The proposed algorithm to detect lava floods for the Early Warning System (EWS) can be seen in Figure 1.  Figure 2 shows the block diagram of the lava flood early warning system. The system consists of an IoT server and two clients located upstream and downstream of the river at the foot of Mount Merapi. Each sensor is connected to an ESP, a microcontroller that is supported with IoT. All microcontrollers then condition the signal and process data from sensors using the fuzzy decision tree algorithm. All data from the microcontroller is then sent to an Internet server with IoT technology. The downstream client takes data from the IoT server using Raspberry Pi, then will send the warning through WhatsApp and SMS to the stakeholders. Meanwhile, the second subsystem, which is the disaster communication method, is shown in Figure 3. The figure shows that the Lava Flood EWS tool issued the lava flood warning status using WhatApp and SMS technology, sent to the Disaster Risk Reduction Forum, or Forum Pengurangan Risiko Bencana in Indonesian (FPRB). After that, FPRB members convey information about the status of the lava flood warning using a handy-talky to the CCR (Community Communication Radio).

3-1-Rainfall Intensity Gauge
The design of the rainfall intensity measuring instrument is shown in Figure 4. The figure shows that the rainfall intensity system consists of a rain gauge sensor, an ESP-integrated microcontroller, and the Internet of Things. The rain gauge sensor consists of a mechanical and electronic system. The mechanical system has the following specifications: 1 mm/tip sensitivity, 100 cm² funnel cross-sectional area, 10 ml water volume per tip, and 42 × 40 cm dimension. The tipping bucket system is built without rainwater reservoirs, and there are no restrictions. The amount of rain that enters the electronic system consists of a reed switch used to count the tips in the tipping bucket system. The rain gauge sensor is connected to the ESP microcontroller, and the resulting tip counts in an hour of counting will be transformed into rainfall intensity measurement in mm/hour unit. A prototype of a tipping bucket rain gauge used in the proposed lava flood early warning system can be seen in Figure 5.

3-2-Fuzzy Decision Tree Algorithm
According to the figure, it can be seen that the fuzzy decision tree algorithm has five output roots: O1, O2, O3, O4, and O5. Meanwhile, it only has one input: the measurement read from the sensor. The categorization of the output, which is rainfall intensity, is based on data results from [49]. O1 is the output of no rain with a range of rainfall intensity every hour or every day without rain. O2 is light rain with an intensity range of 0.1 -4.9 mm/hour or 0.1-199 mm/day. O3 is moderate rain with an intensity range of 5 -9.9 mm/hour or 20 -49.9 mm/day. O4 is heavy rain with rainfall intensity of 10-20 mm/hour or 50-100 mm/day. O5 is very heavy rain with rainfall intensity > 20 mm/hour or 100 mm/day.

3-3-Cold Lava Material Vibration Measuring Instrument
Several parameters can be used as a setpoint or initial input to detect vibration, i.e., the volume of material, satellite imaging, infrared mapping. In this study, the setpoint parameter or initial input to detect cold lava floods is the frequency of vibration. Oscillations occur when material or silt is moving and flowing from the top of the mountain. This vibration can be identified to be used to detect cold lava floods. The instrumentation design of the cold lava material vibration sensor is shown in Figure 7. The figure shows that the system consists of a vibration sensor, signal conditioners, and ESP microcontroller supporting IoT. Three piezoelectric speakers are designed to be used as a vibration sensor in the research. The data from the sensor is then estimated with a Kalman filter to ensure data quality and then transmitted to the IoT server.

Internet of Things
The physical design of the proposed vibration sensor will be specified as follows. The outer case is made of 1.5mm-width aluminum, 24×12×12 cm 3 dimension, consisting of three piezoelectric speakers with a configuration representing the XYZ axis. This configuration is designed to increase sensitivity, enhancing the sensing ability of vibrations that comes from different directions. A physical design view of the vibration sensor used in the research is presented in Figure 8.

4-1-Lab-scale Rainfall Intensity Measurement Test
Instrument testing for the automatic rain gauges was done in sub-tests with specific goals: 1) to determine the value of rainfall volume that triggers trip counter; 2) to determine measurement tolerance. The first sub-test is to fill the rainwater funnel with water. After that, the water that has been collected in the rainwater funnel will drip automatically into the tipping bucket. Rainwater that is accommodated in the rainwater catcher will tip over after reaching a certain volume, which is closely to 10 ml. The amount of water wasted from the tipping bucket will be measured using a measuring glass. The subtest was done in 20 repetitions, and the results can be seen in Table 2. According to the results, the average volume of rainfall that triggers the tipping bucket to tip is 9.805 ml. This means that the tipping bucket has 9.805ml/tip sensitivity. Meanwhile, the average measurement error is 0.195, which means that the error percentage is 19.5%. Therefore, the sensor can be said to have 81.5% accuracy. The next subtest conducted is to fill the rainwater reservoir with 100ml water and let the tipping bucket system tip until the water from the reservoir is completely drained. This resulted in the tipping bucket being tipped 9 times, while the amount of water remaining in the reservoir was 8.7ml. Then, based on these findings, the measurement tolerance can be calculated. The calculation of the tolerance will be calculated as follows: Compared to results from Abimanyu and Darmawan (2021) [28], the proposed tipping bucket has lower sensitivity/resolution than the referenced results. However, according to Lavigne et al. (2000) [49], the minimum threshold of rainfall intensity that triggers a lava flood is 10 mm/hour. This means that the proposed system is still in the sensitivity range to detect early indicators of heavy rainfall that can cause cold lava floods. Moreover, the proposed modified tipping bucket rain gauge will consume less data memory since the tip counter will save fewer data to the interconnected data system.

4-2-Lab-scale Geophone Sensor Instrumentation Test
Instrumentation testing for the proposed vibration sensor will be conducted to answer several test objectives: 1) to determine frequency detection range; 2) to determine accuracy for specified frequency range; 3) to identify frequency range for various material flow.
The first test objective will be found by connecting the vibration sensor to a frequency generator, and then measured frequency by the vibration sensor will be recorded. According to the test results, the sensor gave an excellent performance with 100% accuracy to detect frequency in the range of 1-9000 Hz. However, the accuracy slightly decreased to 99.004% after the frequency reached the 10000-32700 Hz range. Moreover, the vibration sensor cannot detect the frequency range at a frequency equal to or more than 32800Hz. Hence, it can be said that the proposed vibration sensor has a frequency measurement range of 1-9000Hz. The next test is to conduct several subtests. The testing of the cold lava material detection tool is carried out with three subtests. The first subtest used stones with 30-40 grams weight and 20-25 cm 3 volume size. The stones will be flown in a designed landslide, and the vibration sensor is then placed at the end of the landslide. There are 10 sets of stones, and 10 repetitions were made for each set of stones. Thus, the subtest will be done in 100 repetitions. The measured frequencies will then be recorded and analyzed. The lowest measured frequency in this subtest result is 14 Hz, and the highest frequency is 61 Hz.
The second subtest used heavier and larger stones, 60-90 grams, with 35-40 cm 3 volume size. The lowest and highest frequency measured in this subtest is 18 Hz and 87 Hz, respectively. The third test used stones with a size of 100-140 grams and a volume between 50-75 cm 3 . The lowest measured frequency is 25 Hz, and the highest is 113 Hz. These findings are in line with findings from [49], which stated lahars (cold lava flood) with high sediment concentration (debris flows) produce preferentially strong signals in the low-frequency band.
According to these findings, the proposed vibration sensor is proved to successfully detect materials in a cold lava flood simulation in a 14-113 Hz frequency range. This means that the proposed vibration sensor is able to detect material flows accurately without any significant measurement errors. Moreover, the proposed vibration sensor can detect material flows in a wide range of frequencies, but still has a high sensitivity to lower frequencies. This finding is essential to the design of lava flood detection and early warning system, since conventional instruments that utilize frequency and acoustic measurements to detect lava floods had these difficulties. Calibration of conventional geophone instruments was difficult for the high-gain low-frequency channel since the instrument plots and records signals with low and high frequency separately [49].

4-3-Field-scale Mean Areal Rainfall and Peak Discharge Measurement Tests
After the sensors successfully passed the lab-scale instrumentation tests, all sensors were tested in field-scale measurement tests. The field test was carried out in Desa Sumber, Magelang, where the village is located very close to Mount Merapi. Three automatic rain gauges were installed at the upstream of Kali Senowo, and one vibration sensor was planted. Measurements from these sensors were processed and sent to the IoT servers. The system also generated SMS warnings to the FPRB members as an early warning when a very heavy rainfall occurred. However, a warning for evacuation was not transmitted since the frequency detected by the vibration sensor was under 1000 Hz. The fieldscale test results at once flood discharge were as follows:

4-4-Disaster Communication Test: Cold Lava Flood Simulation and Training
The disaster communication test was carried out through UMY community service program, coordinated with FPRB Desa Sumber, Magelang, Indonesia. The community service program is one of UMY's real contributions to help the community, especially the FPRB of Sumber Magelang Village. The simulation program aims to increase resiliency to natural disasters, especially the cold lava flood disasters. In the simulation, a very heavy rainfall was simulated to occur at Kali Senowo, which was detected by the installed automatic rain gauge sensors. The microcontrollers then processed the signals from the sensor, and data was sent to the IoT servers. At the same time, warnings from SMS were sent to the training participants. Figure 9 shows the SMS warning that was sent to an FPRB member at the simulation.

Figure 9. A warning sent via SMS to an FPRB member.
FPRB members then coordinated with other agencies and disaster-related organizations. Situations were then remotely monitored in hourly duration through the IoT blynk.io websites that record rainfall intensity continuously. When the vibration sensor detects heavy material flows with a frequency higher than 1 kHz, another warning was given to FPRB members, which means the emergency evacuation alert. FPRB members then contacted Communication Community Radio (CCR) by using handy-talky instruments at the disaster frequency. Local villagers were then evacuated to a safer place that was already arranged. All participants were instructed to act calmly but vigilant to the given warning.

5-Conclusion
The lava flood early warning system presented in this paper has two subsystems that act interdependently in one unit. The proposed system consists of automatic rain gauges, a novel vibration sensor, and ESP microcontrollers to support IoT function. The system is proved to have excellent performance with 81.5% accuracy of automatic rain gauge sensor; high sensitivity and wide frequency range of vibration sensor. Thus, it makes the proposed system to be reliable. Moreover, the proposed system can be remotely monitored through the IoT platform, which is the blynk.io webpage. Warnings are given primarily through SMS with GSM modules, but the system also has a redundant communication plan through WhatsApp messages. The disaster communication technology was also applied to the system, which is through radio communications. The merging of the two subsystems is considered useful by the local DDR forum (the FPRB members) and can alert the community with less chaos and panic situations.

6-2-Data Availability Statement
The data presented in this study are available in article.

6-3-Funding
The authors received financial support for the research of this article from Universitas Muhammadiyah Yogyakarta.

6-4-Acknowledgements
The authors would like to thank Universitas Muhammadiyah Yogyakarta for supporting this work by providing a research grant for this study.

6-5-Conflicts of Interest
The authors declare that there is no conflict of interests regarding the publication of this manuscript. In addition, the ethical issues, including plagiarism, informed consent, misconduct, data fabrication and/or falsification, double publication and/or submission, and redundancies have been completely observed by the authors.