Experimental and Theoretical Studies on Extract of Date Palm Seed as a Green Anti-Corrosion Agent in Hydrochloric Acid Solution

Extracts from plant materials have great potential as alternatives to inorganic corrosion inhibitors, which typically have harmful consequences. Experimental and theoretical methodologies studied the effectiveness of agricultural waste, namely, date palm seed extract as a green anti-corrosive agent in 0.5 M hydrochloric acid. Experimental results showed that immersion time and temperature are closely related to the effectivity of date palm seed as a corrosion inhibitor. The inhibition efficiency reduced from 95% to 91% at 1400 ppm when the immersion time was increased from 72 h to 168 h. The experimental results also indicated that the inhibition efficiency decreased as the temperature increased. The presence of a protective layer of organic matter was corroborated by scanning electron microscopy. The adsorption studies indicated that date palm seed obeyed Langmuir adsorption isotherm on the carbon steel surface, and Gibbs free energy values were in the range of −33.45 to −38.41 kJ·mol−1. These results suggested that the date palm seed molecules interacted with the carbon steel surface through mixture adsorption. Theoretical calculations using density functional theory showed that the capability to donate and accept electrons between the alloy surface and the date palm seed inhibitor molecules is critical for adsorption effectiveness. The HOMO and LUMO result indicated that the carboxyl (COOH) group and C=C bond were the most active sites for the electron donation-acceptance type of interaction and most auxiliary to the adsorption process over the Fe surface.


Introduction
Recently, carbon steel corrosion study has attracted the attention of researchers in the corrosion field. Since carbon steel is applied widely in oil and gas applications, it is usually placed under the sea, which contains corrosive agents, including water, acids, salts, humidity, and oxygen. These agents increase the corrosion reactions on carbon steel surfaces [1]. Many methods have been proposed to overcome these corrosion problems, such as coating, cathodic protection, anodic protection, and corrosion inhibitors. Corrosion inhibition is one of the common effective ways to overcome corrosion reactions, especially in acidic media. The corrosion rate is reduced when molecules are adsorbed onto the metal surface, thereby decreasing anodic or cathodic reactions [2].
Commonly used corrosion inhibitors are synthetic chemicals, including chromates, lead oxide, zinc phosphates, polyphosphates and orthophosphates. These inhibitors, potentiodynamic polarization measurments, respectively [16]. Fatty acids are attractive candidates as corrosion inhibitors because they contain absorbable carboxyl functional groups for attachment to metal surfaces. Besides, they are readily available and more environmentally friendly. Gas chromatography-mass spectrometry (GC-MS) results reportted by our research group show that DPS contains high levels of different acids, which formulas are indicated in Table 1 [16]. The importance of this class of acids is due to their molecular features. Conceptually, the carboxylic acid functional group in fatty acids enhances the surface chemistry toward interaction with metal-vacant orbitals and plays a crucial role in improving the adsorption characteristics. The active group of fatty acid molecules may interact with the metal protecting it from corrosion. potentiodynamic polarization measurments, respectively [16]. Fatty acids are attractive candidates as corrosion inhibitors because they contain absorbable carboxyl functional groups for attachment to metal surfaces. Besides, they are readily available and more environmentally friendly. Gas chromatography-mass spectrometry (GC-MS) results reportted by our research group show that DPS contains high levels of different acids, which formulas are indicated in Table 1 [16]. The importance of this class of acids is due to their molecular features. Conceptually, the carboxylic acid functional group in fatty acids enhances the surface chemistry toward interaction with metal-vacant orbitals and plays a crucial role in improving the adsorption characteristics. The active group of fatty acid molecules may interact with the metal protecting it from corrosion. There have been no previous reports on the use of DPS as a green anti-corrosion agent on carbon steel in HCl solution using theoretical studies. Theoretical studies are a powerful tool for corrosion inhibition research to measure and analyse the electronic properties of the molecules involved and examine the reaction mechanism(s) involved [17]. Studies describing the electronic properties of corrosion inhibitors are limited. Computational techniques can effectively propose the best compound in corrosion inhibitors and overcome any experimental disadvantages. Therefore, the application of computational methods is an economical, fast, and eco-friendly way to complement experimental investigations.
The main purpose of this article was to evaluate DPS as a carbon steel corrosion inhibitor in 0.5 M HCl solution, using weight loss at various temperatures and immersion time to measure the protective effect. The kinetics and thermodynamics parameters were calculated and discussed. Scanning electron microscopy (SEM) was used to analyse the inhibited and uninhibited carbon steel surface in HCl solutions. DFT methods were used to study the relationship between the inhibitory properties of DPS and the structure of its components. DFT methods were also used to compute the Fukui indices, Highest Occupied Molecular Orbital (EHOMO) and Lowest Unoccupied Molecular Orbital (ELUMO) energies.

Carbon Steel Preparation
The chemical composition of the tested carbon steel (wt. %) was 99.3 Fe; 0.5 Mn; 0.04 P; 0.12 C; 0.045 S. The carbon steel was mechanically cut into pieces measuring 2 × 2 cm. The samples were polished using silicon-carbide paper with #320-#2000 grades. The samples were finally washed with acetone and then distilled water before use [18].

Extraction Process
The date seeds were washed with water and sun-dried for a few days before further drying in an oven at 40-50 °C for 20-30 min. The dried date seeds were ground mechanically into powder. In a typical DPS extraction, 10 g of dried date seed powder was diluted There have been no previous reports on the use of DPS as a green anti-corrosion agent on carbon steel in HCl solution using theoretical studies. Theoretical studies are a powerful tool for corrosion inhibition research to measure and analyse the electronic properties of the molecules involved and examine the reaction mechanism(s) involved [17]. Studies describing the electronic properties of corrosion inhibitors are limited. Computational techniques can effectively propose the best compound in corrosion inhibitors and overcome any experimental disadvantages. Therefore, the application of computational methods is an economical, fast, and eco-friendly way to complement experimental investigations.
The main purpose of this article was to evaluate DPS as a carbon steel corrosion inhibitor in 0.5 M HCl solution, using weight loss at various temperatures and immersion time to measure the protective effect. The kinetics and thermodynamics parameters were calculated and discussed. Scanning electron microscopy (SEM) was used to analyse the inhibited and uninhibited carbon steel surface in HCl solutions. DFT methods were used to study the relationship between the inhibitory properties of DPS and the structure of its components. DFT methods were also used to compute the Fukui indices, Highest Occupied Molecular Orbital (EHOMO) and Lowest Unoccupied Molecular Orbital (ELUMO) energies.

Carbon Steel Preparation
The chemical composition of the tested carbon steel (wt. %) was 99.3 Fe; 0.5 Mn; 0.04 P; 0.12 C; 0.045 S. The carbon steel was mechanically cut into pieces measuring 2 × 2 cm. The samples were polished using silicon-carbide paper with #320-#2000 grades. The samples were finally washed with acetone and then distilled water before use [18].

Extraction Process
The date seeds were washed with water and sun-dried for a few days before further drying in an oven at 40-50 °C for 20-30 min. The dried date seeds were ground mechanically into powder. In a typical DPS extraction, 10 g of dried date seed powder was diluted There have been no previous reports on the use of DPS as a green anti-corrosion agent on carbon steel in HCl solution using theoretical studies. Theoretical studies are a powerful tool for corrosion inhibition research to measure and analyse the electronic properties of the molecules involved and examine the reaction mechanism(s) involved [17]. Studies describing the electronic properties of corrosion inhibitors are limited. Computational techniques can effectively propose the best compound in corrosion inhibitors and overcome any experimental disadvantages. Therefore, the application of computational methods is an economical, fast, and eco-friendly way to complement experimental investigations.
The main purpose of this article was to evaluate DPS as a carbon steel corrosion inhibitor in 0.5 M HCl solution, using weight loss at various temperatures and immersion time to measure the protective effect. The kinetics and thermodynamics parameters were calculated and discussed. Scanning electron microscopy (SEM) was used to analyse the inhibited and uninhibited carbon steel surface in HCl solutions. DFT methods were used to study the relationship between the inhibitory properties of DPS and the structure of its components. DFT methods were also used to compute the Fukui indices, Highest Occupied Molecular Orbital (EHOMO) and Lowest Unoccupied Molecular Orbital (ELUMO) energies.

Carbon Steel Preparation
The chemical composition of the tested carbon steel (wt. %) was 99.3 Fe; 0.5 Mn; 0.04 P; 0.12 C; 0.045 S. The carbon steel was mechanically cut into pieces measuring 2 × 2 cm. The samples were polished using silicon-carbide paper with #320-#2000 grades. The samples were finally washed with acetone and then distilled water before use [18].

Extraction Process
The date seeds were washed with water and sun-dried for a few days before further drying in an oven at 40-50 °C for 20-30 min. The dried date seeds were ground mechanically into powder. In a typical DPS extraction, 10 g of dried date seed powder was diluted  There have been no previous reports on the use of DPS as a green anti-corrosion agent on carbon steel in HCl solution using theoretical studies. Theoretical studies are a powerful tool for corrosion inhibition research to measure and analyse the electronic properties of the molecules involved and examine the reaction mechanism(s) involved [17]. Studies describing the electronic properties of corrosion inhibitors are limited. Computational techniques can effectively propose the best compound in corrosion inhibitors and overcome any experimental disadvantages. Therefore, the application of computational methods is an economical, fast, and eco-friendly way to complement experimental investigations.
The main purpose of this article was to evaluate DPS as a carbon steel corrosion inhibitor in 0.5 M HCl solution, using weight loss at various temperatures and immersion time to measure the protective effect. The kinetics and thermodynamics parameters were calculated and discussed. Scanning electron microscopy (SEM) was used to analyse the inhibited and uninhibited carbon steel surface in HCl solutions. DFT methods were used to study the relationship between the inhibitory properties of DPS and the structure of its components. DFT methods were also used to compute the Fukui indices, Highest Occupied Molecular Orbital (EHOMO) and Lowest Unoccupied Molecular Orbital (ELUMO) energies.

Carbon Steel Preparation
The chemical composition of the tested carbon steel (wt. %) was 99.3 Fe; 0.5 Mn; 0.04 P; 0.12 C; 0.045 S. The carbon steel was mechanically cut into pieces measuring 2 × 2 cm. The samples were polished using silicon-carbide paper with #320-#2000 grades. The samples were finally washed with acetone and then distilled water before use [18].

Extraction Process
The date seeds were washed with water and sun-dried for a few days before further drying in an oven at 40-50 °C for 20-30 min. The dried date seeds were ground mechanically into powder. In a typical DPS extraction, 10 g of dried date seed powder was diluted

Carbon Steel Preparation
The chemical composition of the tested carbon steel (wt. %) was 99.3 Fe; 0.5 Mn; 0.04 P; 0.12 C; 0.045 S. The carbon steel was mechanically cut into pieces measuring 2 × 2 cm. The samples were polished using silicon-carbide paper with #320-#2000 grades. The samples were finally washed with acetone and then distilled water before use [18].

Extraction Process
The date seeds were washed with water and sun-dried for a few days before further drying in an oven at 40-50 • C for 20-30 min. The dried date seeds were ground mechanically into powder. In a typical DPS extraction, 10 g of dried date seed powder was diluted with 1 L of 0.5 M HCl solution and heated to 50 • C using a hot plate under continuous magnetic stirring for 15 h [19]. The solution was then filtered to eliminate any suspended solid particles. Finally, the extract was diluted with 0.5 M HCl to prepare a series of inhibitor stock solutions with different DPS concentrations (800, 900, 1200, 1400, and 2000 ppm).

Weight Loss Test
Weight loss was measured, firstly, at different immersion times (72-168 h) at room temperature and secondly, at various other temperatures (25,35,45,55 and 65 • C) to determine the kinetic parameters of the corrosion process and elucidate the inhibition mechanism. The carbon steel samples were prepared as explained in Section 2.1. The samples were weighed before and after immersion in a corrosive medium. The data gathered from the weight loss test was applied to determine the corrosion rate (C r ) in millimetres penetration per year (mm/y −1 ) and inhibition efficiency (IE%) utilised by the equations below [20]: where ∆W is the difference between initial and final weights of carbon steel (mg), while ρ is the density of carbon steel (g cm −3 ), parameter A is the surface area of carbon steel (cm 2 ). The immersion time per hour (h) denoted as T, and 87,600 is a constant for C r determination [21].
where C r blank and C r inh are the corrosion rates values without and with DPS, respectively.

Scanning Electron Microscopy (SEM)
Carbon steel samples 25 × 25 cm size were exposed to 0.5 M HCl solutions in the absence and presence of 1400 ppm DPS for 24 h at 25 • C. SEM and EDX images were recorded using a MERLIN model scanning electron microscope (SEM; ZEISS, Oberkochen, Germany) located at the Universiti Kebangsaan Malaysia (UKM) CRIM lab. The SEM experiments was conducted at a voltage of 15 kV, 500× magnification and the size of each image was 10 µm. The EDX detector was used to examine the chemical compounds on the carbon steel surface.

Quantum Chemical Calculation
The geometrical optimisation of the inhibitor molecules was performed using the DMol3 software with the generalised gradient approximation of the Perdew-Burke-Ernzerhof (GGA-PBE) functional within the DFT framework. The double numerical with polarisation (DNP) function was used as a basis set. In all geometric optimisations, the convergence energy tolerance of 1.0 × 10 −5 Ha, the maximum force of 0.002 Ha/Å, and the maximum displacement of 0.005 Å were used. Each of the following quantum parameters, such as energy gap (∆E) eV, electron affinity (EA) eV, ionisation potential (IP) eV, electronegativity (χ) eV, global hardness (η) eV, global softness (σ), and (∆N) the fraction of electrons transferred from inhibitor to Fe (110) surface was determined using the following Equations [22]: where φ equal 4.82 eV, which represents the work function of the Fe (110) surface [23].

Weight Loss Test
Weight-loss tests are straightforward since they don't need specialised equipment and can be performed on several samples simultaneously. This approach aimed to investigate the impact of immersion time and temperature on Cr and IE%. and the details are as follows: The immersion periods were varied from 72 h to 168 h in this study, and the resulting influence is shown in Figure 1. It is clear that the IE% was reduced after the longest period of immersion. The data obtained for the weight loss of carbon steel in 0.5 M HCl in the absence and presence of DPS inhibitor concentrations are displayed in Table 2. A review investigation of these data shows that the weight loss increases and IE% decreases as immersion time increases. A maximum value of IE reached 95% and reduced to 91% after immersion for 72 h and 168 h, respectively. This can be attributed to DPS being desorbed from the carbon steel surface and increasing contact between the bare metal and corrosive media would lead to the metal dissolving. The decrease in IE% after a long period of immersion can also be due to a lower number of inhibitor molecules available in HCl solution to avoid or minimise metal dissolution. After the inhibitor molecules had been desorbed from the carbon steel surface, they become inactive and do not participate in the inhibition process [24,25]. These molecules will not be toxic to the environment after disposal due to their biodegradability.

Weight Loss Test
Weight-loss tests are straightforward since they don't need specialised equipment and can be performed on several samples simultaneously. This approach aimed to investigate the impact of immersion time and temperature on Cr and IE%. and the details are as follows:

The Influence of Immersion Time
The immersion periods were varied from 72 h to 168 h in this study, and the resulting influence is shown in Figure 1. It is clear that the IE% was reduced after the longest period of immersion. The data obtained for the weight loss of carbon steel in 0.5 MHCl in the absence and presence of DPS inhibitor concentrations are displayed in Table 2. A review investigation of these data shows that the weight loss increases and IE% decreases as immersion time increases. A maximum value of IE reached 95% and reduced to 91% after immersion for 72 h and 168 h, respectively. This can be attributed to DPS being desorbed from the carbon steel surface and increasing contact between the bare metal and corrosive media would lead to the metal dissolving. The decrease in IE% after a long period of immersion can also be due to a lower number of inhibitor molecules available in HCl solution to avoid or minimise metal dissolution. After the inhibitor molecules had been desorbed from the carbon steel surface, they become inactive and do not participate in the inhibition process [24,25]. These molecules will not be toxic to the environment after disposal due to their biodegradability.   In this work, the effect of temperature on the inhibition of carbon steel has been studied in the range of 25 • C to 65 • C. The results illustrated in Figure 2 show the values of corrosion rate (Cr) and inhibition efficiency (IE%) obtained by the weight loss method. It can be seen from Table 3 that an increase in temperature will increase the Cr and decrease IE%. Meanwhile, with the participation of inhibitor, the Cr was reduced, and IE% increased as the concentration of inhibitor increases. At higher temperatures, the time difference between the adsorption and desorption of inhibitor molecules on the carbon steel surface becomes shorter [26]. Corrosion in an acidic medium is commonly accompanied by the release of H 2 . The adsorption process is affected by the irritation resulting from accelerated development rates of H 2 at a high temperature, which drives a reduction in the IE% of corrosion inhibitor [27].
In this work, the effect of temperature on the inhibition of carbon steel has been studied in the range of 25 °C to 65 °C. The results illustrated in Figure 2 show the values of corrosion rate (Cr) and inhibition efficiency (IE%) obtained by the weight loss method. It can be seen from Table 3 that an increase in temperature will increase the Cr and decrease IE%. Meanwhile, with the participation of inhibitor, the Cr was reduced, and IE% increased as the concentration of inhibitor increases. At higher temperatures, the time difference between the adsorption and desorption of inhibitor molecules on the carbon steel surface becomes shorter [26]. Corrosion in an acidic medium is commonly accompanied by the release of H2. The adsorption process is affected by the irritation resulting from accelerated development rates of H2 at a high temperature, which drives a reduction in the IE% of corrosion inhibitor [27].      Figure 3a shows a smooth surface with no visible signs of corrosion. After retrieving the sample from the uninhibited 0.5 M HCl medium, it was found to have deteriorated severely, as seen in Figure 3b. When the immersion test was repeated with the acid solution containing 1400 ppm of DPS corrosion inhibitor, the surface was observed to be relatively smooth, indicating significant corrosion suppression, as presented in Figure 3c. These outcomes suggested that the presence of DPS inhibited the corrosion of carbon steel. EDX was conducted to examine the elemental composition of the samples in the absence and presence of 1400 ppm of DPS corrosion inhibitor at 25 • C. The results of the EDX analyses are summarised in Figure 4 and show that the presence of DPS suppressed the corrosive effects on carbon steel surfaces immersed in HCl medium to a greater extent than if the carbon steel surfaces were uninhibited [28]. riorated severely, as seen in Figure 3b. When the immersion test was repeated with the acid solution containing 1400 ppm of DPS corrosion inhibitor, the surface was observed to be relatively smooth, indicating significant corrosion suppression, as presented in Figure 3c. These outcomes suggested that the presence of DPS inhibited the corrosion of carbon steel. EDX was conducted to examine the elemental composition of the samples in the absence and presence of 1400 ppm of DPS corrosion inhibitor at 25 °C. The results of the EDX analyses are summarised in Figure 4 and show that the presence of DPS suppressed the corrosive effects on carbon steel surfaces immersed in HCl medium to a greater extent than if the carbon steel surfaces were uninhibited [28].

Thermodynamics of Corrosion in HCl Solution
Temperature plays an essential role in understanding the inhibitive mechanism of the corrosion process and study the impact on corrosion rate. Therefore, the activation

Thermodynamics of Corrosion in HCl Solution
Temperature plays an essential role in understanding the inhibitive mechanism of the corrosion process and study the impact on corrosion rate. Therefore, the activation energy (E a ), activation enthalpy (∆H a ), and activation entropy (∆S a ) were determined at different temperature and different concentrations of DPS. The relationship between the Cr and temperature (T) follows the Arrhenius equation: where A is a pre-exponential factor, Ea is the smallest energy for a reaction that needed to occur (activation energy), R represents the universal gas constant (8.314 J mol −1 K −1 ), and T represents the absolute temperature in Kelvin (K). The values of activation energy were calculated by plotting LnCr against 1/T, as shown in Figure 5. This plot provides straight lines wherever the intercept is lnA, and the slope is −Ea/R; the values obtained are listed in Table 4. The E a values of DPS corrosion inhibitor were in the range of 23.62 to 83.43 kJ·mol −1 . Therefore, it is suggested that DPS corrosion inhibitor can perform dual adsorption reactions, namely, both chemical and physical adsorption [29]. In corrosion inhibition studies, the E a values of 80 kJ·mol −1 and above indicate a chemical adsorption reaction process. On the contrary, E a values of less than 80 kJ·mol −1 represent physical adsorption [30].      Meanwhile, the values of ∆H a , and ∆S a were determined by using the transition state, which is an alternative formula for the Arrhenius equation: N is the Avogadro number (6.022 × 10 23 mol −1 ), and h is the Planck constant (6.63 × 10 −34 Js).
The plot in Figure 6 shows the transition state equation of ln(Cr/T) as a function of 1/T, with and without DPS concentrations. The straight lines were performed with a slope (−∆H a /R), while the intercept (Ln R/Nh + ∆S a /R) [30], and the values are tabulated in Table 4. The positive values of ∆H indicated the endothermic properties of the carbon steel dissolution process [31]. It is evident that the ∆H were shifted in the same way as the E values, confirming the purposed inhibition mechanism [32]. The large and negative values of ∆S indicating that a reduction in disordering takes place on going from reactants to the active complex. This investigation is in harmony with the other authors' findings [33,34].

Adsorption Isotherm
Adsorption isotherms can be used to investigate the interactions of DPS inhibitor molecules with the carbon steel surface [35]. To identify the adsorption type, various isotherms were considered, including Temkin and Langmuir isotherms. The Langmuir adsorption isotherm model was discovered to be the most suitable model. The linear relationships of C/θ versus C for DPS inhibitor on carbon at different temperatures are shown in Figure 7. The positive values of ∆H a indicated the endothermic properties of the carbon steel dissolution process [31]. It is evident that the ∆H a were shifted in the same way as the E a values, confirming the purposed inhibition mechanism [32]. The large and negative values of ∆S a indicating that a reduction in disordering takes place on going from reactants to the active complex. This investigation is in harmony with the other authors' findings [33,34].

Adsorption Isotherm
Adsorption isotherms can be used to investigate the interactions of DPS inhibitor molecules with the carbon steel surface [35]. To identify the adsorption type, various isotherms were considered, including Temkin and Langmuir isotherms. The Langmuir adsorption isotherm model was discovered to be the most suitable model. The linear relationships of C/θ versus C for DPS inhibitor on carbon at different temperatures are shown in Figure 7.
Adsorption isotherms can be used to investigate the interactions of DPS inhibitor molecules with the carbon steel surface [35]. To identify the adsorption type, various isotherms were considered, including Temkin and Langmuir isotherms. The Langmuir adsorption isotherm model was discovered to be the most suitable model. The linear relationships of C/θ versus C for DPS inhibitor on carbon at different temperatures are shown in Figure 7. The linear regression coefficients (R 2 ) values were almost equal to 1, as shown in Table 5. This indicated that DPS adsorption on the carbon steel surface adhered to the Langmuir adsorption isotherm, which can be expressed as follows [36]: where K ads is a constant balance of absorption, C is the concentration of inhibitor (ppm) and the degree of surface coverage determined from weight loss data [37]: wherever ∆G o ads is the Gibbs energy adsorption, and the absolute temperature defined as T in Kelvin. The 55.5 is water concentration in the solution.  Table 5 shows the negative values of ∆G o ads , this indicates that DPS inhibitor molecules are adsorbed spontaneously on a carbon steel surface to form a stable layer [38]. In general, the ∆G o ads values greater than −40 kJ·mol −1 indicate that the adsorption could be as chemisorption. In contrast, a negative value from −20 kJ·mol −1 or lower shows physisorption [39,40]. In the present study, the obtained values of ∆G o ads are located in the range of −33.45 to −38.41 kJ·mol −1 . Therefore, this indicated that the DPS could protect the carbon steel corrosion by performing mixture adsorption (physical absorption and chemical adsorption). Meantime, at the temperatures of 318 to 338 K, the process was close to chemisorption as described in Figure 8.  The values of enthalpy of adsorption (∆H ) and entropy of adsorption (∆S ) were obtained by plotting ∆G against T, as shown in Figure 9. In this study, the values of ∆H and ∆S was found to be 27.36 kJ·mol −1 and −40.68 Jk −1 ·mol −1 respectively. Meanwhile, the positive value of ∆H indicates that the adsorption phenomenon is endothermic. The negative value of ∆S suggests that the adsorption involves an associative mechanism. Additionally, a negative value of S shows that no major changes in the adsorbent's internal structures occur throughout the adsorption process [41]. ads suggests that the adsorption involves an associative mechanism. Additionally, a negative value of S shows that no major changes in the adsorbent's internal structures occur throughout the adsorption process [41].   Figure 10 shows the proposed corrosion inhibition mechanism by DPS inhib rosion inhibitors will generally be ionised in acidic solutions and acquire a positiv due to the ionisation process. The ionisation reaction of the DSE inhibitor solutio where the water molecule (H2O) is separated into a hydrogen cation (H + ) and the anion (OH − ) [40].

Corrosion Inhibitor in HCl Solution Operational Mechanism
In this study, date seed extract with various functional groups, such as OH, C OCH3, which are nucleophilic, will be protonated or bonded to H + in an acidic solution (Figure 10a). Cl − and OH − anions tend to move to more electrophilic catio Thus, the steel surface will be negatively charged by the anions CI − and OH − and corrosion reactions and oxide formation. Next, the proton corrosion inhibitor with the negatively charged steel surface (Figure 10b). The positive charge on t site of the DPS corrosion inhibitor ties to the negative charge on the steel. These  Figure 10 shows the proposed corrosion inhibition mechanism by DPS inhibitor. Corrosion inhibitors will generally be ionised in acidic solutions and acquire a positive charge due to the ionisation process. The ionisation reaction of the DSE inhibitor solution occurs where the water molecule (H 2 O) is separated into a hydrogen cation (H + ) and the hydroxyl anion (OH − ) [40].

Corrosion Inhibitor in HCl Solution Operational Mechanism
site of the DPS corrosion inhibitor ties to the negative charge on the steel. These interactions cause the inhibition of the corrosion process. Anion Cl − was found adsorbed by coupling with the inhibitor molecule, where it lies between the steel surface (Fe 2+ ) and the corrosion inhibitor (H + inhibitor) through the interaction of ionic bonds and Van der Waals forces. Coupling adsorption usually involves interactions between anions and active sites of the corrosion inhibitor [42].

Quantum Chemical Calculation
The quantum parameters of chemicals listed in Table 6 were calculated to understand the mechanism of inhibition offered by lauric, myristic, oleic, phthalic, caprylic, and palmitic acids on the Fe surface. The performance of an inhibitor can be predicted using its EHOMO, ELUMO, and ΔE values. The tendency of the inhibitor molecule to contribute electrons to the metal surface is correlated with EHOMO, while ELUMO is used to explain the abil-(b) In this study, date seed extract with various functional groups, such as OH, C=O, and OCH 3 , which are nucleophilic, will be protonated or bonded to H + in an acidic aqueous solution (Figure 10a). Cl − and OH − anions tend to move to more electrophilic cations (Fe +2 ). Thus, the steel surface will be negatively charged by the anions CI − and OH − and undergo corrosion reactions and oxide formation. Next, the proton corrosion inhibitor interacts with the negatively charged steel surface (Figure 10b). The positive charge on the active site of the DPS corrosion inhibitor ties to the negative charge on the steel. These interactions cause the inhibition of the corrosion process. Anion Cl − was found adsorbed by coupling with the inhibitor molecule, where it lies between the steel surface (Fe 2+ ) and the corrosion inhibitor (H + inhibitor) through the interaction of ionic bonds and Van der Waals forces. Coupling adsorption usually involves interactions between anions and active sites of the corrosion inhibitor [42].

Quantum Chemical Calculation
The quantum parameters of chemicals listed in Table 6 were calculated to understand the mechanism of inhibition offered by lauric, myristic, oleic, phthalic, caprylic, and palmitic acids on the Fe surface. The performance of an inhibitor can be predicted using its E HOMO , E LUMO , and ∆E values. The tendency of the inhibitor molecule to contribute electrons to the metal surface is correlated with E HOMO , while E LUMO is used to explain the ability of inhibitor molecules to obtain electrons from the metal surface [43]. Inhibitors with higher E HOMO values show a high propensity to donate electrons to the metal surface of the unoccupied d-orbital [44]. The E HOMO increasing values facilitate adsorption on the metal surface, thereby improving the effectiveness of inhibition.
On the other hand, the inhibitors with lower E LUMO values show a high capability to accept electrons. In this research, oleic acid has a high E HOMO value, as shown in Table 6, which indicates a greater tendency to give electrons to the Fe surface. In comparison, the lower E LUMO value of phthalic acid exhibits a higher tendency to allow electrons, followed by the Fe surface. The energy gap (∆E), which is defined as the difference between E LUMO and E HOMO , is another quantum chemical parameter that can be correlated with inhibition efficiency. The ∆E can elucidate the adsorption reactiveness of the inhibitor molecules with the Fe surface. A lower ∆E value of an inhibitor molecule shows that the molecule has higher reactivity and can have better IE compared to the molecules with higher ∆E. Phthalic acid possesses a low ∆E value, which suggests greater reactivity and strong inhibition performance on the Fe surface. The ∆E of oleic acid is lower than lauric acid, as also found by [44]. Other work reports by [45] on lauric, myristic, oleic and caprylic acid show the ∆E of 7.60 eV for lauric and myristic while oleic, caprylic acid have ∆E of 6.16 eV and 7.62 eV, respectively. The deviation between the HOMO-LUMO energy gap value obtained in this work and the other work is due to the difference in the software used and other calculations parameters such as basis sets and exchange-correlation functional. Due to the lower inhibitor electronegativity (χ) values as compared to the work function of Fe, given as 4.82 eV in Fe, the electrons flow from the inhibitor to the Fe surface. The electronegativity value of oleic acid is the lowest amongst other DPS molecules, although the difference in electronegativity value is too small as compared to those of lauric, myristic, and palmitic acids.
Global hardness (η) and softness (σ) are terms used to describe the resistance of atoms to the deformation of their electron cloud [46]. These are important characteristics for calculating molecular stability and reactivity. A large ∆E exists in hard molecules, while the ∆E is low in soft molecules. A hard molecule is less reactive than a soft molecule because it cannot easily give electrons to the acceptor molecule. Thus, a soft-molecule inhibitor is supposed to be more reactive and has more inhibition efficiency than a hard-molecule inhibitor because soft molecules easily provide electrons to the metal surface. In this research, the values of η and σ of lauric, myristic, caprylic, and palmitic acids show small differences, which suggest that the resistance of the species is similar to the disfigurement of its electron structure. As hard molecules are less interactive than soft molecules, the alikeness of the η and σ values of lauric, myristic, caprylic, and palmitic acids suggests that these acids will have the same reactivity towards the Fe surface as inhibitors. This can also be explained by the small differences in their ∆E values. However, the values of η and σ for oleic acid and phthalic acid are not quite as close to those of other inhibitors, which indicates that they would have different reactivity towards the Fe surface. As shown in Table 6, the lowest hardness value for phthalic acid is 1.740 eV, and the lowest softness value is 0.3783 eV −1 , which is assumed to be the most effective for a corrosion inhibitor.
The IE% through the electrons transferred (∆N) was higher for oleic acid, indicating a higher tendency to contribute electrons to the Fe surface. All ∆N values are also shown to be lower than 3.6, and according to Lukovits [46], ∆N value of less than 3.6 indicates higher inhibition efficiency on the metal surface due to higher electron-donating power. If ∆N exceeds 0, electrons are transferred from the inhibitor molecules to the Fe surface. On the other hand, if ∆N is less than 0, the opposite process occurs, and electrons are transferred from the Fe surface to the inhibitor molecules [47]. The results show that the inhibitors examined in this study were electron donors and the Fe surface was the electron acceptor.
The electrophilic attack sites representing the regions where the inhibitor molecule and metal surface show that the highest bonding ability is carried by the HOMO orbital. Nucleophilic attack sites are carried by LUMO orbital; they exhibit an antibonding orbital occurring between inhibitor molecules and metal surface to create a bond of feedback that strengthens the interaction between the inhibitor and the surface of Fe. Table 7 presents the distribution of HOMO electron density over the inhibitor means that the inhibitor molecule is likely to be active in the donation of electrons to the empty Fe orbital, resulting in efficient corrosion inhibition. The distribution of LUMO density over the molecule, on the other hand, confirms that electrons from the occupied Fe orbitals can be effectively accepted, which is a major factor for interactions between the donor and the acceptor to occur. It can be observed that the HOMO and LUMO of lauric, myristic, phthalic, caprylic, and palmitic acid molecules are mainly localised around the carboxyl (COOH) group. However, in the case of oleic acid, the HOMO was mainly localised on the C=C bond, and this finding is consistent with another report [48]. This can be due to the middle of the oleic acid contain a double bond, so the HOMO was saturated around the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side.
Therefore, these sites are the most active for the electron donation-acceptance type of interaction and most likely to facilitate adsorption over the Fe surface. Also, the distribution of HOMO-LUMO indicates that all double bonds in simple molecules serve as active HOMO sites, suggesting their tendency to share electronic charge with the atoms of surface metal. In the case of phthalic acid, which has two groups of carboxyl, the distribution of HOMO and LUMO around its benzene ring is observed over the entire molecule. Table 7. DFT calculations of optimised structure and HOMO and LUMO structures for DPS fatty acids compounds (atom legend: white = H, light grey = C, and red = O).

Lauric acid
Molecules 2021, 26, x 15 of 18 the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. the area. This is supported by a finding from [49], which found that the major contribution to the HOMO comes from the carbon atoms adjacent to the C=C in the oleic acid side. Therefore, these sites are the most active for the electron donation-acceptance type of interaction and most likely to facilitate adsorption over the Fe surface. Also, the distribution of HOMO-LUMO indicates that all double bonds in simple molecules serve as active HOMO sites, suggesting their tendency to share electronic charge with the atoms of surface metal. In the case of phthalic acid, which has two groups of carboxyl, the distribution of HOMO and LUMO around its benzene ring is observed over the entire molecule.

Conclusions
The inhibitor properties of DPS for preventing carbon steel corrosion were investigated using experimental and theoretical methods. The corrosion inhibition of carbon steel in an acidic solution by DPS was proven to be more effective than other inhibitors reported in the previous literature. The inhibition efficiency decreased with an increase in both immersion time and temperature, but it increases with an increase in concentrations of DPS up to 1400 ppm. The surface morphology of the carbon steel sample protected with 1400 ppm inhibitor was smoother compared with the sample exposed to the acid solution. This suggests that a protective layer was formed on the carbon steel surface. The EDX analysis of the carbon steel surface shows that the peaks of Cl and O are high in the absence of DPS inhibitor. The activation energy and enthalpy values suggest that DPS performs a dual adsorption, and the properties were endothermic. The adsorption studies indicated that DPS obeyed the Langmuir adsorption model. In addition, the values of Gibbs free energy signified that the DPS inhibition mechanism worked through mixture adsorption on the carbon steel surface. The results attained from a quantum chemical study using DFT methods indicate that the COOH group and C=C bond are the active sites on DPS molecules and are most likely to be responsible for the adsorption on the Fe surface. The findings obtained from the experimental and theoretical measurements in this study are in good agreement. Therefore, these sites are the most active for the electron donation-acceptance type of interaction and most likely to facilitate adsorption over the Fe surface. Also, the distribution of HOMO-LUMO indicates that all double bonds in simple molecules serve as active HOMO sites, suggesting their tendency to share electronic charge with the atoms of surface metal. In the case of phthalic acid, which has two groups of carboxyl, the distribution of HOMO and LUMO around its benzene ring is observed over the entire molecule.

Conclusions
The inhibitor properties of DPS for preventing carbon steel corrosion were investigated using experimental and theoretical methods. The corrosion inhibition of carbon steel in an acidic solution by DPS was proven to be more effective than other inhibitors reported in the previous literature. The inhibition efficiency decreased with an increase in both immersion time and temperature, but it increases with an increase in concentrations of DPS up to 1400 ppm. The surface morphology of the carbon steel sample protected with 1400 ppm inhibitor was smoother compared with the sample exposed to the acid solution. This suggests that a protective layer was formed on the carbon steel surface. The EDX analysis of the carbon steel surface shows that the peaks of Cl and O are high in the absence of DPS inhibitor. The activation energy and enthalpy values suggest that DPS performs a dual adsorption, and the properties were endothermic. The adsorption studies indicated that DPS obeyed the Langmuir adsorption model. In addition, the values of Gibbs free energy signified that the DPS inhibition mechanism worked through mixture adsorption on the carbon steel surface. The results attained from a quantum chemical study using DFT methods indicate that the COOH group and C=C bond are the active sites on DPS molecules and are most likely to be responsible for the adsorption on the Fe surface. The findings obtained from the experimental and theoretical measurements in this study are in good agreement. Therefore, these sites are the most active for the electron donation-acceptance type of interaction and most likely to facilitate adsorption over the Fe surface. Also, the distribution of HOMO-LUMO indicates that all double bonds in simple molecules serve as active HOMO sites, suggesting their tendency to share electronic charge with the atoms of surface metal. In the case of phthalic acid, which has two groups of carboxyl, the distribution of HOMO and LUMO around its benzene ring is observed over the entire molecule.

Conclusions
The inhibitor properties of DPS for preventing carbon steel corrosion were investigated using experimental and theoretical methods. The corrosion inhibition of carbon steel in an acidic solution by DPS was proven to be more effective than other inhibitors reported in the previous literature. The inhibition efficiency decreased with an increase in both immersion time and temperature, but it increases with an increase in concentrations of DPS up to 1400 ppm. The surface morphology of the carbon steel sample protected with 1400 ppm inhibitor was smoother compared with the sample exposed to the acid solution. This suggests that a protective layer was formed on the carbon steel surface. The EDX analysis of the carbon steel surface shows that the peaks of Cl and O are high in the absence of DPS inhibitor. The activation energy and enthalpy values suggest that DPS performs a dual adsorption, and the properties were endothermic. The adsorption studies indicated that DPS obeyed the Langmuir adsorption model. In addition, the values of Gibbs free energy signified that the DPS inhibition mechanism worked through mixture adsorption on the carbon steel surface. The results attained from a quantum chemical study using DFT methods indicate that the COOH group and C=C bond are the active sites on DPS molecules and are most likely to be responsible for the adsorption on the Fe surface. The findings obtained from the experimental and theoretical measurements in this study are in good agreement. Therefore, these sites are the most active for the electron donation-acceptance type of interaction and most likely to facilitate adsorption over the Fe surface. Also, the distribution of HOMO-LUMO indicates that all double bonds in simple molecules serve as active HOMO sites, suggesting their tendency to share electronic charge with the atoms of surface metal. In the case of phthalic acid, which has two groups of carboxyl, the distribution of HOMO and LUMO around its benzene ring is observed over the entire molecule.

Conclusions
The inhibitor properties of DPS for preventing carbon steel corrosion were investigated using experimental and theoretical methods. The corrosion inhibition of carbon steel in an acidic solution by DPS was proven to be more effective than other inhibitors reported in the previous literature. The inhibition efficiency decreased with an increase in both immersion time and temperature, but it increases with an increase in concentrations of DPS up to 1400 ppm. The surface morphology of the carbon steel sample protected with 1400 ppm inhibitor was smoother compared with the sample exposed to the acid solution. This suggests that a protective layer was formed on the carbon steel surface. The EDX analysis of the carbon steel surface shows that the peaks of Cl and O are high in the absence of DPS inhibitor. The activation energy and enthalpy values suggest that DPS performs a dual adsorption, and the properties were endothermic. The adsorption studies indicated that DPS obeyed the Langmuir adsorption model. In addition, the values of Gibbs free energy signified that the DPS inhibition mechanism worked through mixture adsorption on the carbon steel surface. The results attained from a quantum chemical study using DFT methods indicate that the COOH group and C=C bond are the active sites on DPS molecules and are most likely to be responsible for the adsorption on the Fe surface. The findings obtained from the experimental and theoretical measurements in this study are in good agreement. Therefore, these sites are the most active for the electron donation-acceptance type of interaction and most likely to facilitate adsorption over the Fe surface. Also, the distribution of HOMO-LUMO indicates that all double bonds in simple molecules serve as active HOMO sites, suggesting their tendency to share electronic charge with the atoms of surface metal. In the case of phthalic acid, which has two groups of carboxyl, the distribution of HOMO and LUMO around its benzene ring is observed over the entire molecule.

Conclusions
The inhibitor properties of DPS for preventing carbon steel corrosion were investigated using experimental and theoretical methods. The corrosion inhibition of carbon steel in an acidic solution by DPS was proven to be more effective than other inhibitors reported in the previous literature. The inhibition efficiency decreased with an increase in both immersion time and temperature, but it increases with an increase in concentrations of DPS up to 1400 ppm. The surface morphology of the carbon steel sample protected with 1400 ppm inhibitor was smoother compared with the sample exposed to the acid solution. This suggests that a protective layer was formed on the carbon steel surface. The EDX analysis of the carbon steel surface shows that the peaks of Cl and O are high in the absence of DPS inhibitor. The activation energy and enthalpy values suggest that DPS performs a dual adsorption, and the properties were endothermic. The adsorption studies indicated that DPS obeyed the Langmuir adsorption model. In addition, the values of Gibbs free energy signified that the DPS inhibition mechanism worked through mixture adsorption on the carbon steel surface. The results attained from a quantum chemical study using DFT methods indicate that the COOH group and C=C bond are the active sites on DPS molecules and are most likely to be responsible for the adsorption on the Fe surface. The findings obtained from the experimental and theoretical measurements in this study are in good agreement. Therefore, these sites are the most active for the electron donation-acceptance type of interaction and most likely to facilitate adsorption over the Fe surface. Also, the distribution of HOMO-LUMO indicates that all double bonds in simple molecules serve as active HOMO sites, suggesting their tendency to share electronic charge with the atoms of surface metal. In the case of phthalic acid, which has two groups of carboxyl, the distribution of HOMO and LUMO around its benzene ring is observed over the entire molecule.

Conclusions
The inhibitor properties of DPS for preventing carbon steel corrosion were investigated using experimental and theoretical methods. The corrosion inhibition of carbon steel in an acidic solution by DPS was proven to be more effective than other inhibitors reported in the previous literature. The inhibition efficiency decreased with an increase in both immersion time and temperature, but it increases with an increase in concentrations of DPS up to 1400 ppm. The surface morphology of the carbon steel sample protected with 1400 ppm inhibitor was smoother compared with the sample exposed to the acid solution. This suggests that a protective layer was formed on the carbon steel surface. The EDX analysis of the carbon steel surface shows that the peaks of Cl and O are high in the absence of DPS inhibitor. The activation energy and enthalpy values suggest that DPS performs a dual adsorption, and the properties were endothermic. The adsorption studies indicated that DPS obeyed the Langmuir adsorption model. In addition, the values of Gibbs free energy signified that the DPS inhibition mechanism worked through mixture adsorption on the carbon steel surface. The results attained from a quantum chemical study using DFT methods indicate that the COOH group and C=C bond are the active sites on DPS molecules and are most likely to be responsible for the adsorption on the Fe surface. The findings obtained from the experimental and theoretical measurements in this study are in good agreement.

Conclusions
The inhibitor properties of DPS for preventing carbon steel corrosion were investigated using experimental and theoretical methods. The corrosion inhibition of carbon steel in an acidic solution by DPS was proven to be more effective than other inhibitors reported in the previous literature. The inhibition efficiency decreased with an increase in both immersion time and temperature, but it increases with an increase in concentrations of DPS up to 1400 ppm. The surface morphology of the carbon steel sample protected with 1400 ppm inhibitor was smoother compared with the sample exposed to the acid solution. This suggests that a protective layer was formed on the carbon steel surface. The EDX analysis of the carbon steel surface shows that the peaks of Cl and O are high in the absence of DPS inhibitor. The activation energy and enthalpy values suggest that DPS performs a dual adsorption, and the properties were endothermic. The adsorption studies indicated that DPS obeyed the Langmuir adsorption model. In addition, the values of Gibbs free energy signified that the DPS inhibition mechanism worked through mixture adsorption on the carbon steel surface. The results attained from a quantum chemical study using DFT methods indicate that the COOH group and C=C bond are the active sites on DPS molecules and are most likely to be responsible for the adsorption on the Fe surface. The findings obtained from the experimental and theoretical measurements in this study are in good agreement.