Dragonfly Support Vector Machine Modelling of the Adsorption Phenomenon of Certain Phenols by Activated Carbon Fibres

The objective of this research was to build a mathematical model based on a Support Vector Machine (SVM) capable of predicting the amount adsorbed at equilibrium (qe). Activated carbon fibres (ACF) were used for the adsorption of certain phenols (phenol, 2-chlorophenol, 4-chlorophenol, 2,4,6-trichlorophenol, 4-nitrophenol, and 2,4-dinitrophenol). An experimental dataset of 129 points was collected from previously published papers. The inputs considered for modelling were temperature (T), concentration at equilibrium (ce), and two descriptors (boiling point (BP) and density (d)) to differentiate between the pollutants studied. The data used were pre-processed by the statistical analysis to ensure that they were adequate for modelling. The results showed a superiority of the Gaussian kernel function DA-SVM model demonstrated by its determination coefficient (R2 = 0.997) and root mean squared error (RMSE = 0.027 mmol l−1).


Introduction
Water pollution is an alteration in its quality and nature that makes its use dangerous and/or disrupts the aquatic ecosystem. It concerns surface water (rivers, bodies of water) and/or groundwater. Its main origins are human activity, industries, agriculture, and domestic and industrial waste landfills. [1][2][3] Phenol and its derivatives are used in a number of applications such as the chemical, pharmaceutical, petroleum, paper, wood, rubber, dyes, and pesticide industries. Phenols are classified as priority pollutants because of their toxicity to organisms, even at low concentrations. 4,5 Their adverse effects on the environment and public health have been demonstrated by growing evidence, such as the death of aquatic life, inhibition of normal activities of the microbial community, and carcinogenicity in animals. 6 Due to the high toxicity, high prevalence and poor biodegradability of phenols, it is necessary to remove them from wastewater before discharging them into water bodies.
The adsorption treatment process is one of the most important technologies today. It is widely used for pollution control and purification in a wide variety of fields, for example, the petroleum, petrochemical and chemical industries, environmental, and pharmaceutical applications. 7,8 Activated carbon fibres (ACF) are generally microporous, with a large surface area and a narrow pore distribution. The microporous nature gives ACFs adsorption advantages because the adsorption energy is increased in small pores.
In addition, ACFs have a large external surface area and their micropores are directly exposed to the surface, resulting in a rapid rate of adsorption. 9 Machine learning (ML) is a type of artificial intelligence (AI) that allows software applications to be more precise in predicting outcomes without being explicitly programmed to do so. [10][11][12][13][14][15] Support Vector Machine (SVM) is a machine learning or statistical technique defined for the prediction of variables. Generally, this technique is employed to avoid the overfitting and convex optimisation problems (no local minima), and it runs well on smaller databases. This research consists of studying the data of the adsorption of phenols with ACFs, and of modelling by the machine learning technique (DA-SVM).

Support vector machines (SVM) technique
The SVM is based on a statistical learning theory. This method was introduced by Vapnik. [16][17][18] The architecture of SVM model is not determined a priori. The mathematical expression of the output estimation of the SVM is given as follows: where w is a weight vector, b is a bias, denotes the dot product, and ⌀ is the non-linear transfer function that maps Dragonfly Support Vector Machine Modelling of the Adsorption Phenomenon of Certain Phenols by Activated Carbon Fibres the input vectors into a high-dimensional feature space, in which theoretically a simple linear regression can cope with the complex non-linear regression of the input space.
Vapnik introduced the following convex optimisation problem with a ε-insensitivity loss function to obtain the solution to Eqs. (2) and (3): 19 (2) where and are slack variables that penalize training errors by the loss function over the error tolerance ε, and C is a positive trade-off parameter or capacity parameter that determines the degree of the empirical error in the optimisation problem and determines the trade-off between the flatness of the function and the amount to which deviations larger than (ε) are tolerated.
Eqs. (4) and (5) can be solved using the Lagrangian multipliers and the Karush-Kuhn-Tucker (KKT) optimality conditions, as follows: 20 (4) where α i and α i * are the Lagrangian multipliers, K is a kernel function defined by an inner product of the nonlinear transfer functions: 19 (5)

SVM optimisation with Dragonfly algorithm (DA) technique
The chosen methodology can be schematised in accordance with the flowchart in Fig. 1, which includes the following steps: The program shown in Fig. 1 depends on the technical SVM and the method of optimisation by the Dragonfly algorithm (DA) proposed by S. Mirjalili. 21 The DA initially feeds the SVM with a random combination of hyperplane parameters in their previously defined ranges. In five iterations, the steps starting with the data division and up to the development of the SVM model are repeated, and the minimum value of RMSE obtained is saved as the best value. [23][24][25][26] The DA then generates a new population of parameter hyperplanes for the SVM algorithm, and the same set of steps is repeated in order to obtain a new best RMSE, among which the minimum RMSE corresponds to the DA-SVM model optimal result.
Numeric values in the input data matrix have been normalised to improve the optimisation and speed convergence. The normalisation function is expressed by the following Eq. (6) 0.09 n X X = To assess the predictive power of the DA-SVM model, a root mean squared error (RMSE) Eq. (7) and coefficient of determination (R 2 )) Eq. (8) 4 Data collection, pre-treatment, and analysis The modelling data was collected from the literature, 22 the database must be analysed statistically. Table 1 summarises the values of some statistical parameters, such as standard deviation, variance, and KURTOSIS. The database contains 21 adsorption systems (seven phenols multiplied by three temperature changes). The amount adsorbed at equilibrium is predicted by the following variables: temperature Training data Testing data Normalisation of data The database was randomly divided by the Holdout Partitions method into two sets: one for the learning (train), and another for validation, consisting of 80 % and 20 %, respectively.

Gaussian kernel function results
The linear regression curve of the (q e ) calculated by DA-SVM optimised with the (q e ) experimental for the two phases (learning and validation) using the Gaussian kernel function is represented in Fig. 5 with a vector regression [α (slope), β (y-intercept), R (correlation coefficient)] = [1.00, 0.0017, 0.998], and Table 3 summarises the model parameters.

Comparative study of the results of the two approaches
The performances of the models developed in this work were compared to the statistical criterion (Eqs. 7 and 8).
To this end, two approaches, among which a polynomial kernel function DA-SVM model and a Gaussian kernel function DA-SVM model, were evaluated in terms of correlation performance and prediction accuracy (Fig. 5).   For more details, it was noticed that the error of learning Gaussian kernel function DA-SVM model is eight times less than the error of learning polynomial kernel function DA-SVM model, and the Gaussian kernel function DA-SVM model test error three times less than the polynomial kernel function DA-SVM model test error. In general, it can be concluded that the prediction capacity of Gaussian kernel function DA-SVM model is five times better than the prediction capacity of polynomial kernel function DA-SVM model.   The experimental data of 2,4-dichlorophenol adsorbed amount at equilibrium at 25, 40, and 55 °C, and the data calculated by the Gaussian kernel function DA-SVM model are shown in Fig. 9. It can be observed that the model has excellent prediction.

Graphical representation of the Gaussian kernel function DA-SVM model
Projecting experimental values of 2,4,6-trichlorophenol adsorbed at 25, 40, and 55 °C by ACFs over the values predicted by a Gaussian kernel function DA-SVM model demonstrates the model's ability to predict with high accuracy (Fig. 10). The Gaussian kernel function DA-SVM model demonstrated its great ability to predict the amount adsorbed at equilibrium of 4-nitrophenol at 25, 40, and 55 °C, as shown in Fig. 11.
The amount adsorbed at equilibrium (q e ) was studied with a database containing the experimental conditions (temperature (T) and concentration at equilibrium (c e )), and three descriptors to distinguish phenols (molecular weight (M w ), density (d), and boiling point (BP) to differentiate the phenols. The inputs and output were statistically studied, and the analysis results proved their ability to predict with no multicollinearity.   The q e modelled was by the SVM technique, the Dragonfly optimisation algorithm (DA) was used to assist SVM to refine its hyperplane parameters, and Gaussian kernel function and polynomial kernel function were tested. The Gaussian kernel function DA-SVM model showed an advantage by giving more accurate values related to a global determination coefficient (R 2 = 0.997) and a global root mean squared error (RMSE = 0.027 mmol l −1 ).