The calibration process of water distribution system models allows for accurate and reliable hydraulic analysis results. Thus, calibration is of utmost importance if adequate operation and maintenance model-based procedures are sought. However, in emerging economies, there is a series of factors that make it more difficult to construct accurate models, including very poor information management, unusually high leakages and the presence of a large number of illegal connections. While some of the model variables are assumed to be known under normal circumstances, these factors make it necessary to consider them for calibration as well. This paper presents a calibration methodology flexible enough to address such problems allowing the calibration of pipe diameter, roughness and minor losses, and nodal demands and leakages. A genetic algorithm was implemented as well as a constraint programming algorithm that makes direct use of hydraulic criteria to advance in the solution space. The methodology was tested on a real system in Colombia with a satisfactory outcome. The use of these techniques results in major reduction of calculation time and similar or superior results in comparison to manual methods.
Clone detection provides insight about replicated fragments in a code base. With the rise of multi-language code bases, new techniques addressing cross-language code clone detection enable the analysis of polyglot systems. Such techniques have not yet been applied to the mobile apps’ domain, which are naturally polyglot. Native mobile app developers must synchronize their code base in at least two different programming languages. App synchronization is a difficult and time-consuming maintenance task, as features can rapidly diverge between platforms, and feature identification must be performed manually. Our goal is to provide an analysis framework to reduce the impact of app synchronization. A first step in this direction consists on a structural algorithm for cross-language clone detection exploiting the idea behind enriched concrete syntax trees. Such trees are used as a common intermediate representation built from programming languages’ grammars, to detect similarities between app code bases. Our technique finds code similarities with 79% precision for controlled tests where Type 1-3 clones are manually injected for the analysis of both single- and cross-language cases for Kotlin and Dart. We evaluate our tool on a corpus of 52 mobile apps identifying code similarities with a precision of 65% to 84% for the full application logic.
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.