In this paper, for the first time, to model the discharge coefficient of labyrinth weirs, the evolutionary firefly algorithm (FFA) is used for optimizing the membership functions of the adaptive neuro-fuzzy inference system (ANFIS). Also, to enhance the performance of the ANFIS and ANFIS-FFA models, the Monte Carlo simulations (MCs) are employed. Additionally, the k-fold cross-validation is utilized for training and testing the methods. Next, some input dimensionless parameters including the Froude number (Fr), the ratio of the head above the weir to the weir height (H T /P), cycle sidewall angle (α), the ratio of length of the weir crest to the channel width (L c /W), the ratio of length of apex geometry to the width of a single cycle (A/w) and the ratio of the width of a single cycle to the weir height (w/P) are determined. After that, seven different models are developed for ANFIS and ANFIS-FFA. Then, by conducting a sensitivity analysis, the superior models (ANFIS-FFA 5 and ANFIS 5) and the most effective input parameter (Froude number) are identified. Moreover, the error distribution results exhibit that about 70% of the superior model results have errors less than 5%. Subsequently, the discharge coefficient is simulated by means of a computational fluid dynamics (CFD) model. Furthermore, a comparison of the CFD model with the ANFIS and ANFIS-FFA models reveals that the ANFIS-FFA model is significantly more accurate. Also, an uncertainty analysis is performed for the CFD, ANFIS and ANFIS-FFA models. Finally, a very simple code calculating the discharge coefficient of labyrinth wires is presented. This code can be easily employed without any knowledge on ANFIS, FFA and prior information about MATLAB.
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.