Abstract
Floods are a climatic phenomena that affect different regions worldwide and that produces both human and material losses; for example in 2017, six of the worst floods were the cause of 3.273 deaths worldwide. In Colombia, the strong winter wave presented between 2010 and 2011, caused 1,374 deaths and 1,016 missing persons. The main river in Colombia is the Magdalena, which provides great benefits to the country but is also susceptible to flooding. This article presents a proposal to optimize a fuzzy system to prevent flooding in homes adjacent to areas of risk to the Magdalena River. The method used is based on evolutionary algorithms to perform a global search, including a gradient-based algorithm to improve the solution obtained. The best result achieved was the Mean Square Error (MSE) of 7, 83E - 05. As a conclusion, it is needed to employ optimization methods for the adjustment of parameters of the fuzzy system when considering that the sets and the rules are systematically obtained.
Keywords
Introduction
By 2017, six of the worst floods were the cause of 3.273 deaths worldwide [1]. As an example, Sierra Leona had a flood in which there were 1.141 deaths and 30 million dollars in economic losses.
In Colombia there are multiple populations with a high risk of flooding in their places of residence. One of the causes is the absence of a Land Management Plan (LMP) that allows the knowledge of the land and the regulation of construction of buildings [2]. It is common to find makeshift houses along the banks, without any previous control or study, risking that the flow of the river increases and causes a disaster. For example, the strong winter wave presented between 2010 and 2011, caused 1,374 deaths and 1,016 missing persons in Colombia [3]. Despite this, this phenomenon has not been monitored in order to predict its behavior, so neither the community nor the authorities are certain when a catastrophe may occur, even though they are aware of the threat posed by rivers, in the rainy season.
For these reasons, the development of tools to predict floods is mandatory as such early alerts in populations located aside the riversides may save numerous human lives as well as reduce the negative impacts that these natural disasters generate. A successful case is in Nepal, where more than 4,700 people evacuated a high-risk area thanks to the sending of preventive text messages by the country’s government, after its early warning system predicted a severe flood in the town of Taduwa [4]. On the other hand, the European Union finances the RAMWASS project that also seeks to implement a system to predict floods, this system has already been successfully tested in Spain, Italy and Germany [5].
The literature review of the works related to the application of Artificial Intelligence (AI) techniques used for modeling and predicting floods and climatic phenomena has the following order. First, a general context of application review of artificial intelligence, then a review of the neural network technique followed by the linear and non-linear autoregressive moving average models; afterwards, the topic of fuzzy logic and later of neuro-fuzzy systems is presented, finally, a review of the topic of optimization of fuzzy systems, which is the object of study of this document. In this regard, it is common to find studies using Artificial Neuronal Networks (ANN) and Adaptive Neuro-Fuzzy Inference Systems (ANFIS) to determine the risks of floods.
Artificial intelligence
Typically, the artificial intelligence has been widely used to predict all types of information in different areas of knowledge, including administrative [6]; for example, in a company in Catalonia (Spain) was developed an information system with artificial intelligence for executives [7]. In the marketing area, it has been applied as showed in [8]. This application allowed to generate digital marketing plans oriented to advertising campaigns based on a range of dates and budget, which allowed to optimize the Return On Investment (ROI). In finance, some researchers developed a decision support system which generates Purchase Orders based on Artificial Intelligence and Theory of Knowledge [9]; another investigation developed artificial intelligence-based systems to classify credit risk in a Cuban bank [10]; finally, an investigation in Japan developed an artificial intelligence system for credit approval, based on the opinion of experts [11]. In operational research it has been used to solve optimization problems, through genetic algorithms [12]. Artificial intelligence has also been used as human resource management systems [13]. In environmental science it has been used for the management and quality of water in rivers [14]; it has also been used to forecast daily precipitation [15] and levels of water in a region [16]. In the area of health, it has been used, for example, in medical history analysis using data mining [17]. In education for allocation of academic spaces [18]. There are many other areas in which artificial intelligence has been employed.
Neural networks
Numerous investigations and articles have been undertaken using ANN as this technique has advantages in managing a series of time as its usage can predict the levels of water. In this respect, [19] makes a special review of the training algorithm finding that the Bayesian Regularization has the best performance. Besides, in reference to the number of stations included in the study, [20] presents experimentations using three stations obtaining positive results. Concerning the decision of using Close Loop Prediction (CLP) or the Open Loop Prediction (OLP), [21] found that CLP displayed better results for this type of forecast. Meanwhile [22] designed a hybrid model based on the Singular Spectrum Analysis (SSA) method, the neural network of the Group Data Management Method (GMDH), the weighted Integration based on precision and diversity (WIAD) and the algorithm Kernel Extreme Learning Machine (KELM), to forecast the water level of the Xiangjiang and Yuanjiang rivers in China. Finally, [23] designed a water level prediction model for the China’s South-to-North Water Diversion Project, this model is made up of a Multilayer Perceptron (MLP) and a Recurrent Neural Network (RNN).
Autoregressive models
According to [24], Auto-Regressive (AR) models have been widely used in various geophysical applications since they are a simple and practical option to model stochastic time series in a way that can be used for the planning, management of hydric reservoirs and floods, among others. In this regard, [24] explains that AR models can be adapted and are useful to describe the skew-surge events. The authors in this work develop seasonal AR models of skew-surge series that are constructed considering data from 35 sites located along the coasts of the European Atlantic Ocean, the English Channel and the southern part of the North Sea. Although AR models are a suitable alternative, Soft Computing (SC) techniques have been used to build hydrological forecast models, this is because SC techniques has adaptability and structure that allow the modeling of systems with non-linear behaviors. In this regard, [25] carried out a study to observe the advantages of computational intelligence techniques to predict the time series associated with the flow of the Sutlej river in the Bhakra Dam, India. In this work, the authors test several ANN and ANFIS models which are compared with traditional autoregressive models. A related work is seen in [26] where ANN technique is used to perform the runoff forecast, using rain and flow data from ten storm events for an asphalt plane location. The implemented models consider different configurations for the collected data. The results of the ANN model were evaluated through comparisons with the results of the Kinematic Wave (KW) and Autoregressive Moving Average (ARMA) models, thus the authors observe that some configurations of the ANN model present better predictions than the KW and ARMA models. Meanwhile, the Neural Network Autoregressive with Exogenous Input (NNARX) are dynamic recurring networks that base the current value of the series on the past values of the same variable, [27] employed this model to flood prediction in Terengganu (Malaysia). An additional work to consider is show in reference [28] where is perform a comparison using NN, SVM (Support Vector Machines), ANFIS, NNARX, and Particle Swarm Optimization (PSO), applied to short-term water level prediction. The results showed that PSO, NNARX, and ANFIS presented a better performance in that order.
Fuzzy logic
Different investigations have been carried out for flood prediction and control. For example, in China, a research was conducted using the Variable Fuzzy Method (VFM) to assess the risk of flash floods, which are very common in mountain areas [29]. Another example is the one implemented for the city of Sary in Iran, where a flood risk map was made with limited hydrological and hydraulic data using two machine learning models, Production of Genetic Algorithm Rule Sets (GARP) and Impartial Fast Efficient Statistical Tree (QUEST) [30]. Meanwhile, [31] developed a fuzzy logic system for real-time flood forecasting using the minimum implication function type Mamdani fuzzy inference system applied to the Kelantan River basin in Malaysia. Likewise, [32] compared different prediction models based on fuzzy logic; the first model was applied to two tropical rivers in Sri Lanka using daily upstream rainfall, and discharge data to predict downstream discharge with the minimum implication function type Mamdani fuzzy inference system; the second was applied in a tropical river in Fiji using a similar type of data with daily time scales, using both the Mamdani type fuzzy inference system with minimum and product implication functions as well as Larsen type inference systems; the third was applied to a temperate-climate river in China using the TSK fuzzy inference system with clustering. It was designed a system has flood status forecast based on water level by fuzzy logic. Finally [33], designed a system with flood status forecast based on water level by fuzzy logic in Palembang (Indonesia), this system has the ability to send a short message of flood status to the community.
Neuro-Fuzzy systems
Neuro-Fuzzy systems ANFIS based on the Takagi-Sugeno model are an alternative for obtaining fuzzy models starting from the training data. For example, [34] presented a general online Takagi-Sugeno (TS) fuzzy modeling methodology based on the extended Kalman filter. The model can be obtained recursively only based on input-output data. Also, [35] proposed two novel Kalman-based learning algorithms for an online Takagi-Sugeno (TS) fuzzy model identification. Another example is proposed by [36] which suggests a new method to identify an adaptive Takagi–Sugeno (TS) fuzzy PDE (Partial Differential Equation) model for nonlinear Multi-Input Multi-Output (MIMO) first-order PDE systems. However, these do not provide the same interpretability achieved with a fuzzy logic Mamdani type as this model uses fuzzy sets for the antecedent and the consequent [37]. One alternative to performing the optimization of a Mamdani type fuzzy logic system is through the use of evolutionary algorithms to optimize the search space which is given by the parameters of the fuzzy sets. Through a gradient-based optimization algorithm it is possible to improve the results obtained using an evolutionary algorithm. In addition [38], designed a hydrodynamic emulation model using ANFIS which used simplified equations and data-based techniques; the model was tested in four floodplains along the Dender river in Belgium, obtained suitable results with low computational cost.
Optimization of fuzzy logic systems
Considering the uncertainty associated with the climate, particularly in rainfall, fuzzy logic is a suitable tool to model floods and other phenomena associated with climate. To increase the adaptability of this systems different optimization strategies can be used to establish better configurations of the fuzzy systems. In this regard, an approach that can allow flood management and flood forecasting consists of the estimation of spatially distributed precipitation grids which may present uncertainty in their variables, to address this [39] proposes a model to merge certain variables with rain grids in order to establish a weather radar. For this, variables such as elevation, slope, and distance from the coast can be considered. In this work, optimization algorithms adjust the parameters of the fuzzy inference system so that its output is close to the measured data. Another related work can be seen in [40] where it is proposed to use a neuro-fuzzy system and metaheuristic optimization for modeling the flood susceptibility. This model was optimized using two metaheuristic algorithms, such as Genetic Evolution and Particle Swarm Optimization. A high frequency tropical cyclone area of the Tuong Duong district in central Vietnam was used as a case study. Moreover, in [41] several optimization approaches (ANFIS, GA, and PSO) are used to establish a fuzzy inference system for flood control in the sector of Diez Lagos (DL) in southern New Mexico. The authors conclude that, in general, the use of evolutionary algorithms are a convenient alternative for optimization of the flood control system allowing the development of a feedback monitoring system with reliable operating rules. Regarding an application in an urban environment in [42], it is exposed that by intensifying the frequency of rain and given the urbanization of certain areas, strong requirements are presented for Urban Drainage Systems (UDS), which are storm water infrastructures that can be controlled in real time to mitigate urban floods downstream. With this approach in [42] a data-based real-time control optimization and simulation tool, based on the FLC (fuzzy logic control) and GA (genetic algorithm), is proposed for intelligent decision-making mitigation system to reduce flood volume in the UDS. In addition, to predict floods, there are fuzzy optimization approaches for the sustainable management of water resources in most river basins in order to manage surface and groundwater resources considering uncertainty. In this regard, in [43] a linear model of fuzzy optimization was used to find the optimal extraction of ground and surface water. Using the results of the fuzzy optimization, a Fuzzy Inference System (FIS) was developed to determine the extraction of groundwater. Water extraction from the Astaneh-Kouchesfahan Plain in northern Iran is considered as a case study. With this approach, the results of the optimization model were used to predict the optimal extraction of water from the aquifer using the FIS obtained.
Document organization
This article consists of the design, simulation and validation of a predictive model based on fuzzy logic (Mamdani model), whose purpose aims to predict the level of water of the river Magdalena, using real data to fit the sets of fuzzy model. It is noteworthy that the purpose of this work is to determine a fuzzy model that allows the desired prediction, namely, establishing whether the variables considered and their encoding and interaction allow the prediction in the form of fuzzy rules. The performance of the system is validated by tests using different numbers of stations and inputs. The model took as input variables the presence or absence of the El Niño and La Niña phenomena, the current season in Colombia and the location of the place where the data is taken. The model had at its best a mean squared error (MSE) of 7, 83E - 05. This provides the model with an adequate ability to predict the volume of water and the anticipation of possible flooding. Yet it is necessary in future research to identify new rules in the fuzzy model, which allows us to improve our understanding of how floods are generated in the Magdalena River.
Thus, the article is divided as follows: the first sections presents the theoretical framework of the techniques under consideration; next, a detailed explanation of the methodology is given; later, the presentation of the results obtained is displayed. Finally, the conclusions of the investigation are put under the discussion and conclusions section.
Theoretical framework
This section explains the relevance of flooding on the Magdalena River. Also, the theoretical concepts of the fuzzy system and the optimization algorithms used.
Floods in the river magdalena
Seasonal rains in Colombia have been always especially alarming for the communities in the riversides. The 125 municipalities surrounding this river (Fig. 1) have been historically affected by flooding and mudflows. Only in 2010 and 2011 its floods affected 2.2 million people [45]. Here, it is relevant to note that this is the Colombian largest river whose water flow is widely affected by climatic phenomena like El Niño and La Niña [46]. Currently, more than 6.3 million people living near the river banks are at a high risk of potential flooding [47].

Magdalena River. Source: [48]
The possibility of flooding on the banks of the Magdalena river can be interpreted through rules, so a fuzzy logic system would be useful in this regard. For this reason, the following subsection will review aspects of fuzzy systems.
Fuzzy systems allow treating the information with uncertainty to modeling complex systems using antecedent and consequent rules [49]. Nowadays, several fields of knowledge apply such rules thus obtaining benefits like automatic control, data classification, decision analysis, expert systems, time series prediction, robotics, and pattern recognition [50].
Mamdani fuzzy model
Initially proposed by Mamdani in 1975, as an effort to controlling a combination of a steam machine with a heater using the synthesis in a set of linguistic rules obtained by human operators [51], this model is frequently used given its simple structure. Fig. 2 displays an example of a Mamdani Model.

Example of a Mamdani fuzzy system.
The implementation of a fuzzy-inference system requires the establishment of a set of fuzzy rules. This is achieved by the definition of fuzzy sets associated with linguistic labels for both the antecedent and the consequent, thus, FIS permits the decision-making process. Besides, the involved operations to process a fuzzy Mamdani type inference system are the following: Fuzzification: this is the process to convert a real-world data into a fuzzy linguistic variable, such belonging function is evaluated from the input value which produces a numerical value between 0 and 1. Fuzzy combination: Here, AND and OR operators are applied as connectors for the fuzzy rules. Consequence: the previously obtained values are projected on the fuzzy sets of the consequent and an implication operator is also used to obtain an alteration of the fuzzy sets of the consequent to obtain the result. Output aggregations: this consists of the process of unification of the outputs for all the rules where the trimmed or scaled belonging functions (modified) are combined in one single fuzzy set. Defuzzification: this step provides a concrete value for the output, which is achieved by taking the output of the previous step to define a representative value of the fuzzy set. There are several methods, being the centroid the most commonly used.
This section examines the optimization algorithms utilized to adjust the parameters in a fuzzy-predictive system. Initially, there is a revision of the genetic algorithms, then the optimization by particle swarm takes place; and finally the Quasi-Newton method.
Both the Genetic Algorithms (GA) and the Particle Swarm Optimization (PSO) are stochastic algorithms that concede a suitable exploration in the search space, however, given the stochastic behavior, they require to be executed several times to determine an optimal solution. Meanwhile, the Quasi-Newton method is based on the calculation of gradients requires one single execution even though the convergence toward the optimum value is attached to the initial search point. As a consequence, the parameter optimization of the predictive fuzzy system is firstly used with GA and PSO to achieve a suitable exploration in the search space to later implement the Quasi-Newton algorithm to refine the best solution provided by the GA and PSO.
As previously mentioned the purpose of this work is to build a fuzzy model that allows the desired prediction, namely, establishing whether the variables considered and their encoding and interaction with fuzzy rules allow the prediction of the level of water. Therefore, algorithms such GA and PSO, which are widely known, are employed for the optimization of the fuzzy system. For a future work, more optimization algorithms can be used and also make a comparison among them considering the reported in [52]. Other techniques such as autoregressive moving average models, neural network or also support vector regression can also be considered to extend this work. In addition, to improve the prediction system, alternatives such as type-2 fuzzy logic described in [53] can also be used as well as a structure of prediction system based on emotional learning process [54]. Additionally, multi-objective optimizations can be employed to tuning the prediction system according to [55].
Genetic algorithms
The functioning of the GAs is inspired in the genetic process of living beings as the populations evolve according to the principles of natural selection, producing the survival of the strongest one [56]. Such principles were proposed by Charles Darwin in 1859 [57]. On the other hand, the principles of the GAs were proposed by Holland in 1975 [58] and later deepened by [59], Davis [60], Michalewicz [61] and Reeves [62].
Nature allows observing the way individuals of a population compete searching for resources and how those individuals with the highest success have more probabilities of producing a large number of descendants; in contrast, the opposite occurs with the weakest members. That is to say, the best-adapted individuals reproduce in higher proportion thus increasing the probabilities of passing its genetic information to the next generation.
As observable in Algorithm 1, the GAs work within a population of individuals representing a possible solution to a specific problem. Each individual has an assigned value related to the performance in solving the problem, this value is directly proportional to the probability of being selected for reproduction and cross its genetic material with another individual previously selected under the same rules. This cross generates new individuals that share some relevant characteristics from the predecessors. Here, it is also applicable to a mutation operator in its stochastic form which allows the exploration of alternative solutions that may remain out of the population. Thus, new individuals that may replace the previous ones are generated for the cases where there is a better performance. Such iterative process allows the transmission of the best features that along with the new generations raise the probabilities of finding an optimal solution of the problem [56].
Particle swarm optimization
PSO is a technique of search and optimization whose methods are mainly conferred to James Kennedy and Russell Eberhart for the work presented in [63]. The method was inspired in the movement described by living organisms such as a flock of birds or a school of fish. This technique consists of a number of particles or prospect solutions in a search space where each one evaluates the objective function from its current location. Each particle determines its movement through the space, combining its best location with the best position of the swarm. Eventually, the swarm will meet as a whole toward the best solutions just like a flock of birds collectively searching for food [64]. This idea was taken to the computing field in the form of an algorithm and is currently used in the optimization of different types of systems.
As observed in Algorithm 2, the first iterative step evaluates the performance of each individual. Later, the best individual and collective performances are evaluated. These values are taken to calculate the velocity and position of each particle. This process is repeated from the first step of the iterative process until some finalization criterion is accomplished (iterations, the value of the objective function, minor change of particles, etc.). In a swarm algorithm, the equations governing the movement of the particles are:
Different from GA and PSO, this method needs to be executed only once to find the solution; however, this depends on the initial search point, whereby it is used to find the best solutions found by the GA and PSO algorithms previously executed. To minimize a function including several variables, the method of Newton takes the form:
In equation 3, it is observable that this method requires calculating the inverse of the Hessian matrix; from a numerical calculation viewpoint, this involves a relevant computational cost by which it is common the usage of these methods where successive approaches are performed for the Hessian matrix and those of its inverse. This set of methods is called Quasi-Newton, which includes the method of DFP (Davidon-Fletcher-Powell) and the method BFGS (Broyden-Fletcher-Goldfarb-Shanno) [65].
This section presents the design and implementation of the fuzzy model for predicting the water level of the Magdalena River and then the optimization process implemented.
Fuzzy model for the prediction of the flow level of the Magdalena river
The implementation of the predictive system is made with a fuzzy-system of Mamdani type due to its interpretability of the prediction system when using fuzzy sets in both the antecedent and the consequent. The making process considered variables related to the levels of the river in a specific season of the year and with the presence or absence of the phenomena of El Niño or La Niña. The model consists of six inputs and one output as follows: Signal with delays: Delays in a series of time of the river level (for the respective station). Station: Location from where the data are taken, these can seize values according to the location of the station. Quarter of the year, there is one single value assigned for each season: Strong summer: December, January, February. Weak summer: June, July, August. Weak winter: September, October, November. Strong winter: March, April and May. Presence or absence of the phenomena El Niño and La Niña: indicating if that day any of those phenomena were manifested; thus, the possible values are: Presence of El Niño. No meteorological phenomenon report. Presence of La Niña.
When considering such variables, Fig. 3 displays the model where the inputs and outputs are observed.

Model of the system.
The construction of the model starts from an encoding of two fuzzy sets for each input as shown in Fig. 4, and Gaussian output fuzzy sets as displayed in Fig. 5.

Fuzzy sets for each input.

Gaussian fuzzy sets for the output.
Since there is a lack of previous knowledge that allows defining the rules of the fuzzy system, a systematic method is used to obtain the set of rules shown in Table 1 which is consists of 64 rules. Since the assignment was systematic, a method is required to achieve the parameter adjustments for the fuzzy sets in the inputs and the output; this is present in the subsequent sections. This method grants the adjustment of the form of the sets for a defined set of data; besides, there is a possibility of establishing rules of higher relevance after optimizing the system when observing the modification developed in the fuzzy sets.
List of rules of the fuzzy inference system.
The performance rate considered to develop the optimization corresponds to Mean Square Error (MSE) which is the result of the average in the addition of the quadratic differences between the series and the expected measured values. The lower the value of the MSE the more precise the model [66]. The performance function is calculated as:
Considering that a Sigmoidal and Gaussian membership function are described respectively as:
This section shows the optimization results of the fuzzy system employing genetic algorithms and particle swarm as well as the refinement of the Quasi-Newton algorithm; besides, the numeric values in the MSE display Gaussian sets of the output allowing the location and opening of each value which is in direct association with the interpretability of each rule.
The data used were requested from IDEAM [67], which is the institution in charge of managing the hydrological and meteorological information in Colombia. Daily, the river level data of all the considered stations in the years 1997 and 2015 are used to perform the optimization processes.
Genetic algorithms
The three configurations described in Table 2 were employed using this technique. Each configuration takes 30 executions of the optimization process aiming to obtain the respective statistical results.
Configurations for genetic algorithms.
Configurations for genetic algorithms.
From the three configurations, the second one presented a better result displaying a minimum error of 4, 82E - 04 as shown in Table 3. This configuration has the largest amount of population with 30 individuals; moreover, it also has the highest crossover fraction with a value of 0.9. Similarly, the worst result (configuration 3) was the one associated with the smallest number of population with five individuals and 0.5 as defined crossover value.
MSE employing GA.
Figure 6 shows a positive behavior in the prediction; however, it is also observable that the estimated values are slightly higher than the actual ones. Therefore, a Quasi-Newton method is employed trying to improve the precision in the prediction.

Prediction results using GA.
There was an improving of 61% when employing the Quasi-Newton algorithm taking the best result of the GA as a start point in the MSE: Best result obtained with GA: 4, 82E - 04. Improvement of the GA result using the Quasi-Newton: 2, 61E - 04.
Figure 7 shows the improvement in the precision of the prediction. If compared to the results obtained using GA, the estimated values are better approximated to the actual ones except in the extreme data (maximum and minimum).

Results of the prediction using GA and Quasi-Newton.
For this case, this is used for optimizing the fuzzy logic system, the algorithm parameter values are shown in Table 4. Each configuration was run 30 times to obtain the respective results.
Configurations of PSO.
Configurations of PSO.
The results obtained with the implementation of PSO are shown in Table 5. Here, the configuration of the slightest MSE was the number 1 with a minimum error of 7, 83E - 05; this configuration also had the minor rate of inertia with a value of 0, 6.
MSE employing PSO.
Figure 8 shows a suitable behavior in the precision of the prediction under the PSO technique. In this way, the extreme values were predicted with accuracy, which makes this result a suitable option to predict floods.

Results of the prediction using PSO.
A Quasi-Newton optimization is executed to improve the accuracy in the estimation obtained, which gives a slight improvement of 1% in the MSE: Better result obtained with the PSO: 7, 8341E - 05. Improvement of the result with the GA using Quasi-Newton: 7, 8320E - 05.
Figure 9 shows that in spite of having a general outstanding behavior the prediction had no a remarkable change when considering the technique employing PSO.

Results of the prediction using and Quasi-Newton.
As previously presented to achieve interpreatibility and precision in the prediction model, an exploration of the search space of the parameters of the fuzzy system is first performed using GA and PSO, then using the Quasi-Newton algorithm this solution is refined, in this way Table 6 presents the summary of the results obtained.
Summary of the improvement process.
Summary of the improvement process.
As observed in Table 6, a good result was obtained with a low MSE, with a better result in PSO with respect to GA. After applying the improvement process with the Quasi-Newton algorithm, in this way, the MSE in the GA model is improved but the PSO is still the one that obtained the best results. This indicates that it is a suitable model that can help predict floods and generate early alerts to local governments of the municipalities and cities located on the banks of the Magdalena River. In order to avoid or reduce the number of human losses and reduce the negative impact on local and national economies.
Aiming to have an approach toward the interpretability achieved with the fuzzy system to be optimized, the following are the output membership functions obtained with GA (Fig. 10). The solution with PSO (Fig. 11) obtained is remarkable as this technique includes belonging functions that segment a greater interval in the output domain. This might mean better exploration of the conditions that could make possible to determine the generation of a flood; that is, the definition of a useful model to define the conditions when having a flood. In addition, regarding the adjustments applied to the fuzzy sets obtained with the PSO, it is observable an overlapping among the belonging functions in the interval (-2, 2), which might also be unified if they have the same consequent. Likewise, there is evidence of a segmentation of the output range, which may result in a characterization of the whole phenomenon.

Fuzzy sets of the outputs of the inference fuzzy system employing GA.

Fuzzy sets of the outputs of the inference fuzzy system employing PSO.
This result can be taken as reference in further works to improve the proposed fuzzy system establishing a set of rules more relevant to obtain a reduced model that allows the representation of the phenomenon under study. Moreover, the model can be improved to analyze the changes achieved in the input fuzzy sets.
Floods produced in the Magdalena River have a relevant impact in most of the Colombian territory, affecting the economy and the lives of the inhabitants living in the riverbanks. For this reason, it is important to establish a method to anticipate the levels of the river with the smallest possible error, in a way this information can be used by the leaders to make the most suitable decisions to mitigate at its most the negative effects that floods carry.
On the other hand, computational intelligence includes several techniques allowing the prediction in a series of time from existing data; in this regard, a suitable model includes fuzzy systems like Mamdani type where fuzzy sets are employed in both the antecedent and the consequent allowing a suitable interpretability of the phenomenon. Considering that the sets and the rules for the fuzzy system are systematically established, to achieve a suitable accuracy is necessary to employ optimization methods for the adjustment of the parameters of the fuzzy system.
The considered inputs take into account the presence or absence of the phenomena of El Niño and La Niña, the current season in Colombia, and the location of the place where the data is taken; this provides the model with a suitable capacity to predict the volume of water and the anticipation of possible floods.
In future works, in order to establish a more compact model it is recommended the identification of the most relevant rules, for which, the changes generated in the fuzzy sets may be analyzed to obtain suitable interpretability of the fuzzy model. Thus, the analysis of the rules would allow improving the understanding of how the floods in the river Magdalena are generated.
