Abstract
A combination of artificial intelligence (AI) and computational fluid dynamics was carried out to advance the modeling of adsorption separation processes. A comparative examination of three AI-based regression models including Gaussian Process Regression (GPR), Multi-layer Perceptron (MLP), and Polynomial Regression (PR) was carried out to predict chemical concentrations of solute in a dataset with two input variables (x and y) and one output feature (C in mol/m3). Employing gradient-based hyperparameter optimization, the results reveal that MLP outperforms GPR and PR with a significantly higher R2 score (MLP: 0.999, GPR: 0.966, PR: 0.980) and lower RMSE (MLP: 0.583, GPR: 3.022, PR: 2.370). Moreover, MLP demonstrates the lowest Average Absolute Relative Deviation (AARD%) at 2.564%, compared to GPR’s 18.733% and PR’s 11.327%. Five-fold cross-validation confirms MLP’s reliability (R² = 0.998 ± 0.001, RMSE = 0.590 ± 0.015). These findings underscore the practical utility of machine learning models, especially MLP, for accurate chemical concentration in environmental monitoring and process optimization with particular application for adsorption process.
Similar content being viewed by others
Introduction
For efficient separation of water pollutants in liquid phase, membrane and adsorption are the common separation processes which offer superior properties and low energy demand. These separation processes can be considered as green processing as no chemical solvent is used for molecular separation and the processes possess higher separation yield compared to other conventional molecular separation processes. Among these processes, adsorption is one of the useful and common methods for removing water impurities in water treatment where the separation takes place in liquid phase between feed solution and solid phase. Highly porous materials are great choices for adsorption due to the large surface area which would enhance the separation efficiency. Also, nanosized solid materials can provide higher external surface which is favorable for adsorption1,2.
Recent development of advanced materials has progressed the application of nanomaterials for adsorption which is a robust process for molecular separation in liquid phase. The process of adsorption is suitable for molecular separation provided that the content of target molecules (pollutants) in the solution is low and then the separation method would be efficient. Some novel materials such as mesoporous silica have been synthesized for application in adsorptive molecular separation, and the separation efficiency is high due to the large pore volume of these materials which can accommodate more guest molecules in their structures3,4,5.
Despite the synthesis and development of novel materials, the mechanism of molecular separation through these materials is still ambiguous and novel computational techniques such as molecular modeling, computational fluid dynamics (CFD), and thermodynamics can be developed6,7,8,9. For adsorption, molecular modeling is useful to understand the intermolecular forces between the components in the solution and find the separation mechanisms. Molecular modeling can be integrated to other computational techniques like artificial intelligence (AI) and numerical simulation to obtain multi-scale modeling7. Also, the method of CFD has been utilized for description of adsorption by solution of differential equations and finding concentration distribution in the process10. Despite the predictive robustness of molecular modeling and CFD, these methods have been recognized as challenging and computationally expensive models for simulating adsorption and cannot be generalized for a wide range of adsorbents and solutes in water treatment11. Therefore, other facile computational strategies should be developed for analysis and optizmaition of adsorption process in water treatment.
The method of AI has recently attracted much attention for modeling separation process. Under this category is Machine Learning (ML) which has become a versatile tool extensively applied across diverse domains for predictive modeling and aiding in decision-making processes. ML algorithms possess the capability to glean insights from data, extract valuable characteristics, and execute precise regression or categorization tasks12,13,14. To address the research gap in comprehensive modeling of adsorption process, we proposed a methodology utilizing Multi-layer Perceptron (MLP), Gaussian Process Regression (GPR), and Polynomial Regression (PR) as regression models, with gradient-based optimization utilized for finding the best hyper-parameters to predict concentration distribution of solute from CFD dataset. Recently, a number of ML-based algorithms have been linked to CFD concentration data for prediction of adsorption and concentration data15,16,17,18, however a larger number of algorithms need to be evaluated for better analysis of the water treatment.
GPR was utilized in this study as it is a flexible and probabilistic approach to regression modeling that allows for powerful and interpretable predictions. It has discovered utility in multiple domains, including machine learning, geostatistics, and Bayesian optimization, making it a valuable tool for data analysis and prediction tasks19. MLP Regression is a powerful and flexible ML method used for modeling complex relationships in regression tasks. Its capacity to handle nonlinear patterns makes it a valuable tool in various domains. Careful architecture design and training are critical for obtaining accurate and robust regression models using MLPs20. PR is a fundamental regression technique used in machine learning and statistics to model relationships between variables when the relationship is believed to be polynomial in nature21.
This paper presents substantial contributions to the field of adsorption by introducing innovative approaches and methodologies that advance our comprehension of intricate phenomena. Moreover, it enhances the scholarly dialogue by creating opportunities for investigation and examination within the field, thus facilitating future progress and revelations. The objective of this work is to develop data-driven models for accurately predicting solute concentration distributions within a spatially complex dataset generated from CFD model. Specifically, the work aims to assess the performance of three regression models (MLP, GPR, and PR), and to determine the most suitable approach for this type of prediction task. The novelty of this research is its integration of mass transfer insights, artificial intelligence techniques, and computational modeling tools, aligning them within the broader framework of separation science. This multidisciplinary approach aims to enhance prediction accuracy and modeling efficiency, offering a practical pathway to optimize separation processes.
Data of adsorption
The data set utilized in this study possesses a significant number of points, exceeding 19,000 in total. Consequently, it serves as a substantial resource that can be effectively employed for statistical analysis and machine learning endeavors to analyze adsorption process. The input parameters for this study consist of the coordinates (x and y), while the output variable of interest is the concentration (C) measured in units of mol/m³. Data is the concentration distribution of an organic compound adsorbed onto the surface of mesoporous silica. The adsorption was considered at the ambient pressure and temperature. CFD was carried out to find the concentration distribution (C), and then the obtained C versus x and y were used for ML fitting and optimization. The procedure was followed as reported in11,15,17,22 to build ML models.
In the pre-processing phase, an outlier detection and removal technique known as Local Outlier Factor (LOF) was employed, as detailed in the methodology section. The input parameters were normalized using the Min-Max scaler, and subsequently, the data was partitioned into test (20%) and train (80%) subsets. Figures 1 and 2 show the correlation heatmap, and variable boxplots as exploratory data analysis. Figure 2 presents the boxplots of the input and output variables, serving as a key part of the exploratory data analysis. This visualization highlights the central tendency, spread, and potential outliers in each variable, which is essential for understanding data distribution prior to ML modeling. Boxplots are especially useful when assessing the need for normalization or outlier treatment, and are commonly used when datasets may contain extreme values or imbalanced distributions22.
Methodology
Local outlier factor (LOF)
LOF is a robust and effective algorithm for identifying outliers within a dataset. It operates under the assumption that outliers are data points that significantly deviate from their local neighborhood. By using LOF, one can uncover and subsequently remove outliers from a dataset, enhancing the overall data quality. The local density of a data point \(\:{x}_{i}\) is defined by LOF in the following manner23:
Here, \(\:N\left({x}_{i}\right)\) represents the neighborhood of data point \(\:{x}_{i}\), and \(\:\text{density}\left({x}_{i}\right)\) denotes the density of \(\:{x}_{i}\). The LOF for a data point quantifies how its density compares to the densities of its neighbors. A LOF value significantly greater than 1 suggests that the data point is an outlier24.
GPR (Gaussian process regression)
GPR stands as a resilient and adaptable non-parametric Bayesian technique employed in the realm of regression analysis. Unlike traditional parametric regression methods, GPR does not make explicit assumptions about the functional form of the underlying data distribution. Instead, it models the data as a distribution over functions, allowing for uncertainty quantification and robust predictions19.
The predictive distribution of GPR is derived through Bayesian inference. Given a set of observed data points (X, y), where X shows the input data and y stands for the corresponding output data, the goal is to make predictions for new input points \(\:{X}^{*}\), yielding predictions \(\:{y}^{*}\). The forecasted or estimated distribution for the variable \(\:{y}^{\text{*}}\) is expressed as follows25:
where \(\:{{\upmu\:}}^{*}\) denotes the mean of the predictive distribution, and \(\:{{\upsigma\:}}^{*}\) stands for its standard deviation. These quantities can be computed as follows25:
In the equations above, K(X, X) indicates the covariance matrix associated with the training inputs, K(X*, X) denotes the covariance between the test and training inputs, \(\:{\sigma\:}_{n}^{2}\) represents the variance of noise, and I stands as the identity matrix.
MLP regression (Multi-layer perceptron regression)
MLP Regression is a variant of artificial neural networks characterized by its multi-layered architecture, where nodes (neurons) are interconnected across these layers. It is a versatile and powerful regression technique capable of modeling complex, nonlinear relationships between inputs and outputs26.
The key equation for MLP Regression includes the forward propagation equation for a single neuron26:
In this context, \(\:{z}_{j}\) signifies the weighted summation of inputs corresponding to neuron j, where \(\:{w}_{ij}\) represents the weight associated with the connection linking neuron i to neuron j.
PR (Polynomial regression)
PR is commonly employed in statistics and ML to model relationships between variables when a polynomial relationship is suspected. Unlike the assumption of linearity in Linear Regression, Polynomial Regression allows for the modeling of more complex, nonlinear relationships27. In PR, the correlation between the dependent variable (typically represented as y) and the independent variable (typically represented as x) is expressed as a polynomial function of a chosen degree, often denoted as n. The general form of a polynomial regression equation is as follows21:
In this context, y denotes the dependent variable, which serves as the target variable we seek to predict or elucidate, while x signifies the independent variable or predictor, representing the variable upon which y relies. Also, \(\:{\beta\:}_{0}\), \(\:{\beta\:}_{1}\), and so on are coefficients that need to be estimated from the data.
Gradient-based optimization
Gradient-based optimization is an effective method for fine-tuning regression model hyperparameters. It uses gradients to determine the direction and rate of the steepest decrease in the objective function. By calculating the gradients based on the hyperparameters, the optimization process can iteratively adjust the values of the hyperparameters to optimize the objective function and identify the most optimal set of hyperparameters28,29.
In the context of gradient-based optimization, the beginning step involves the establishment of an objective function that serves to quantify the performance of the predictive model in relation to the hyperparameters. In this work the objective function is the mean R2 score obtained by cross-validation. The objective is to minimize the previously mentioned function through the manipulation of the hyperparameters.
Next, the derivatives of the objective function based on the hyperparameters are computed using techniques such as automatic differentiation and backpropagation. The resulting gradients guide the adjustments needed to minimize the objective function.
Subsequently, an optimization algorithm (e.g. Adam or Gradient Descent) uses the calculated gradients to iteratively update the hyperparameters. This update process involves scaling the gradients by a learning rate, which controls the step size, and subtracting the scaled gradients from the current values of hyperparameters. The procedure mentioned above is executed iteratively until either convergence is attained or a stopping condition is satisfied30.
Results and discussion
All models described and optimized in this work have been fitted to the CFD data to compare their fitting accuracy and the results are listed in Table 1 where R2, RMSE, and error values have been measured and compared for all models. Machine learning and all models fitting and optimization were performed by using Python 3.8 package which is freely accessible from: https://www.python.org.
The R2 score assesses the degree of accuracy of fitness, with higher values indicating a better fit of the concentration dataset. The RMSE measures the model’s prediction accuracy, with lower values being preferable. Average Absolute Relative Deviation (AARD%) represents the average relative difference between fitted and expected points, with lower percentages indicating better accuracy. Finally, the Max Error indicates the largest discrepancy between fitted and expected points within the C dataset. Also, Figs. 3, 4 and 5 show the comparison of predicted and observed values using all three models. We can observe the visual deviation of predicated values by ML models from the CFD concentration values. At first glance, MLP (Fig. 4) shows the greatest performance as most data points accommodate close to the diagonal line. The results of MLP are promising and more accurate compared to the previous studies on ML modeling of adsorption15,16,17.
Also, we conducted 5-fold cross-validation to ensure robust performance evaluation for the model. The MLP model, which achieved an R² of 0.999 and RMSE of 0.583 on the test set, was validated using 5-fold cross-validation on the training data (80% of the 19,000 + point dataset). The cross-validation results yielded consistent performance, with R² values of 0.9974 ± 0.00192 (mean ± standard deviation) and RMSE values of 0.590 ± 0.01617 across the folds, indicating minimal variability and high reliability of this model in fitting the adsorption data. These metrics, alongside the test set performance, suggest that the MLP model generalizes well and is not significantly overfitted, supported by the use of gradient-based hyperparameter optimization and preprocessing techniques like LOF for outlier removal.
These results and figures showcase the superior performance of the MLP model in terms of R2 score and RMSE, highlighting its outstanding predictive accuracy in comparison to GPR and PR models. As a result, we can introduce the MLP as the best model for this research and base the rest of the analysis on it. Figures 6 depicts the influence of coordinate (x) on the resultant concentration output utilizing the present model, which turns out similar pattern with the results reported by Yang et al.17 for ML modeling C values in adsorption by mesoporous silica. Also, Fig. 7 represents the ultimate three-dimensional prediction surface depicted by MLP model22. The sensitivity analysis of the permutation-based feature importance using MLP model is illustrated in Fig. 8. The achieved ML outcomes for concentration variations as well as sensitivity evaluation show agreement and similarity with the reported results for adsorption of solute using porous materials15,16,17,18,22,31.
The variations of solute concentration revealed considerable changes in x direction due to the effects of solute diffusion from the bulk to the solid phase surface. In fact, the mass transfer driving force in this process is concentration gradient between the feed bulk and surface of adsorbent which causes concentration difference as evidenced in the results, and it has been captured by MLP model properly which proves that the model is physically valid15,17,18.
Our MLP model outperforms Yang et al.17 best model, ADA-SVR (CV R² = 0.966), with a higher CV R² and comparable error metrics for MLP optimized in this study. The MLP’s superior performance, validated through 5-fold cross-validation (R² = 0.998, RMSE = 0.590), likely stems from gradient-based hyperparameter optimization, enhancing its ability to capture complex spatial patterns in separation processes.
3D surface of the concentration as a function of coordinates, (MLP model). Created by Python 3.8 package which is freely accessible from: https://www.python.org.
Conclusion
This study evaluated three regression models for predicting solute concentrations generated from CFD simulation of adsorption process for water treatment. The results of this analysis, driven by gradient-based hyperparameter optimization, demonstrated that MLP model exhibited remarkable predictive capabilities, with an exceptionally high calculated R2 of 0.999 and the lowest Root Mean Square Error (RMSE) at 0.583. This superiority in predictive accuracy, along with the lowest Average Absolute Relative Deviation (AARD%) at 2.564%, highlights MLP’s potential for practical applications in fields such as environmental engineering and process optimization. While both GPR and PR showcased commendable performance, MLP’s outstanding results underscore its suitability for accurate chemical concentration predictions in adsorption process. Future research avenues may involve further fine-tuning of hyperparameters and exploration of advanced regression techniques to continue enhancing predictive precision in similar complex datasets.
Future work can evaluate the integration of ensemble learning methods or hybrid models to further enhance predictive performance. Additionally, applying the proposed models to time-dependent or multivariate concentration datasets could expand their utility in dynamic environmental systems. Investigating the interpretability of neural models and incorporating domain-specific physical constraints into machine learning frameworks may also provide more reliable and explainable predictions. Moreover, expanding the dataset to include more input features or real-time sensor data could help develop more robust and adaptive prediction systems.
Data availability
The datasets used and analysed during the current study are available from the corresponding author on reasonable request.
References
Abdulhameed, A. S. et al. Production of sustainable adsorbent of crosslinked chitosan-oxalate and modified Mango (Mangifera indica L.) seed for highly efficient adsorption of crystal Violet dye: water treatment and biomass valorization. Biomass Bioenerg. 199, 107889 (2025).
Zakir, O. et al. Recent progress in nanomaterials for water treatment: A comprehensive review of adsorption, photocatalytic, and antibacterial applications. J. Water Process. Eng. 72, 107566 (2025).
de Souza, R. M., Magalhães-Ghiotto, G. A. V. & Bergamasco, R. Enhanced chloroquine adsorption using cobalt-modified mesoporous silicas for water treatment. Chem. Eng. Process. - Process. Intensif. 210, 110224 (2025).
Qiu, R. et al. Efficient adsorption of sodium p-perfluorous nonenoxybenzenesulfonate by environmentally friendly self-floating amino ordered mesoporous silica: Energy-efficient solid–liquid separation and enhanced adsorption performance. Sep. Purif. Technol. 371, 133406 (2025).
Wang, B. et al. Adsorption of PFCs and antibiotics from water using mesoporous silica and amino-functionalized mesoporous silicon materials: A review. Chem. Eng. J. 505, 159642 (2025).
Corrente, N. J. & Neimark, A. V. From Slit pores to 3D frameworks: advances in molecular modeling of adsorption in nanoporous carbons. Adv. Colloid Interface Sci. 342, 103502 (2025).
Hira, N. et al. Molecular simulation and ANN modelling for cadmium (Cd) and lead (Pb) adsorption from water using zeolites. Results Eng. 25, 104517 (2025).
Gjennestad, M. A. & Wilhelmsen, Ø. Thermodynamically consistent modeling of gas flow and adsorption in porous media. Int. J. Heat Mass Transf. 226, 125462 (2024).
Saren, S. et al. Evaluation and development of improved thermodynamic models for adsorbed phase properties in adsorption cycles. Int. J. Heat Mass Transf. 229, 125579 (2024).
Fabian Ramos, H. S. et al. CFD-based Model. Adsorpt. Columns: Validation Chem. Eng. Sci., 285: 119606. (2024).
Alali, A. F. Heavy metals removal from wastewater using nanoporous adsorbent: separation analysis via machine learning model. Case Stud. Therm. Eng. 59, 104501 (2024).
de Araújo, L. J. P. et al. Machine learning-based algorithm selection for irregular three-dimensional packing in additive manufacturing. Expert Syst. Appl. 287, 127661 (2025).
Alardhi, S. M. et al. Artificial neural network and response surface methodology for modeling reverse osmosis process in wastewater treatment. J. Ind. Eng. Chem. 133, 599–613 (2024).
Graish, M. S. et al. Prediction of the viscosity of iron-CuO/water-ethylene glycol non-Newtonian hybrid nanofluids using different machine learning algorithms. Case Stud. Chem. Environ. Eng. 11, 101180 (2025).
Sun, Y., Xia, L. & Zhang, Y. Mesosilicate materials for environmental applications: adsorption separation analysis via hybrid computational and machine learning tools. Case Stud. Therm. Eng. 56, 104285 (2024).
Tasqeeruddin, S., Sultana, S. & Alsayari, A. Development of hybrid robust model based on computational modeling and machine learning for analysis of drug sorption onto porous adsorbents. Sci. Rep. 15 (1), 8453 (2025).
Yang, M., Yue, Q. & He, J. Evaluation of mesoporous silica synthesized for green adsorption by modeling via machine learning and mass transfer. Sci. Rep. 15 (1), 19477 (2025).
Li, G. et al. Theoretical investigations on the purification of petroleum using desulfurization process: analysis and optimization of process. Case Stud. Therm. Eng. 63, 105297 (2024).
Deringer, V. L. et al. Gaussian process regression for materials and molecules. Chem. Rev. 121 (16), 10073–10141 (2021).
Riedmiller, M. & Lernen, A. Multi layer perceptron. Machine Learning Lab Special Lecture, University of Freiburg, : pp. 7–24. (2014).
Cheng, X. et al. Polynomial regression as an alternative to neural nets. arXiv preprint arXiv:1806.06850, (2018).
Lv, J. & Wang, L. Hybrid modeling of adsorption process using mass transfer and machine learning techniques for concentration prediction. J. Saudi Chem. Soc. 29(4), 12. https://doi.org/10.1007/s44442-025-00016-y (2025).
Breunig, M. M. et al. LOF: identifying density-based local outliers. in Proceedings of the 2000 ACM SIGMOD international conference on Management of data. (2000).
Hodge, V. & Austin, J. A survey of outlier detection methodologies. Artif. Intell. Rev. 22, 85–126 (2004).
Williams, C. K. & Rasmussen, C. E. Gaussian processes for regression. (1996).
Murtagh, F. Multilayer perceptrons for classification and regression. Neurocomputing 2 (5), 183–197 (1991).
Chatterjee, S. & Hadi, A. S. Regression Analysis by Example (Wiley, 2013).
Bengio, Y. Gradient-based optimization of hyperparameters. Neural Comput. 12 (8), 1889–1900 (2000).
Ruder, S. An overview of gradient descent optimization algorithms. arXiv preprint arXiv:1609.04747, (2016).
Li, M. et al. Employment of artificial intelligence approach for optimizing the solubility of drug in the supercritical CO2 system. Case Stud. Therm. Eng. 57, 104326 (2024).
Gao, H. et al. Computational modeling of petroleum purification for removal of sulfur compounds: process analysis for reduction of environmental impacts and material costs. Ain Shams Eng. J. 15 (11), 102986 (2024).
Acknowledgements
The authors extend their appreciation to the Deanship of Research and Graduate Studies at King Khalid University for funding this work through Large Research Project under grant number RGP2/464/46.
Funding
No funding.
Author information
Authors and Affiliations
Contributions
Heyder Mhohamdi: Model design, Verification, Evaluation, Validation, Writing, Supervision.Usama S. Altimari: Model design, Evaluation, Validation, Software.Krunal Vaghela: Model design, Resources, Evaluation, Writing.Vivek V.: Model design, Verification, Writing, Validation.Sarbeswara Hota: Data analytics, Verification, Evaluation, Writing.Devendra Singh: Verification, Evaluation, Conceptualization, Writing.Mahesh Manchanda: Data analytics, Verification, Validation, Writing.Shirin Shomurotova: Resources, Verification, Writing.Prakhar Tomar: Model design, Data analytics, Evaluation, Validation, Writing.Mohammad Mahtab Alam: Conceptualization, Verification, Evaluation, Validation, Writing.All authors reviewed the manuscript.
Corresponding author
Ethics declarations
Competing interests
The authors declare no competing interests.
Additional information
Publisher’s note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
Open Access This article is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License, which permits any non-commercial use, sharing, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if you modified the licensed material. You do not have permission under this licence to share adapted material derived from this article or parts of it. The images or other third party material in this article are included in the article’s Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article’s Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
About this article
Cite this article
Mhohamdi, H., Altimari, U.S., Vaghela, K. et al. Advancing computational evaluation of adsorption via porous materials by artificial intelligence and computational fluid dynamics. Sci Rep 15, 29691 (2025). https://doi.org/10.1038/s41598-025-15538-z
Received:
Accepted:
Published:
DOI: https://doi.org/10.1038/s41598-025-15538-z