Introduction

Austenitic stainless steels are iron–chromium–nickel (Fe–Cr–Ni) alloys. They may contain small amounts of other alloying elements, e.g., Mn, Nb, Mo, Si, Al and Ti, which may alter their specific properties. The formation of a passive layer of corrosion inhibitors on surfaces of these materials causes high corrosion resistance [1, 2]. Because of their strength, corrosion resistance, mechanical workability, and excellent electrical and thermal conductivities, austenitic stainless steels are one of the most important materials that are used widely in different industries [36]. The corrosion of stainless steel, especially when it occurs in acidic solution, is the concern of the steel users [7]. Acidic solutions are the cause of the detriment to many materials and considerable economic losses [810].

The corrosion inhibition efficiency depends on the structure, chemical composition, the nature of the metal and other conditions [11]. Theoretical studies of the efficiency of corrosion inhibitors have aimed at gaining insight on the molecular chemical activity, structural and electronic properties [1217]. Newly, experimental and quantum chemical studies on inhibition of the corrosion of steel by two pyrazole compounds [18], benzothiazole derivatives [19], 1H-pyrrole-2,5-dione derivatives [20], some sulfonamides [21] and Schiff base molecules [22] have been calculated. The density functional theory calculations were performed on benzoin, benzil, benzoin-(4-phenylthiosemicarbazone) and benzil-(4-phenylthiosemicarbazone) used as corrosion inhibitors for mild steel in acidic medium by Kayadibi et al. [23]. The effect of temperature on corrosion and inhibition processes is discussed by Odozi et al. [24]. They showed that corrosion rate increases as temperature increases both in the absence and presence of the inhibitor and decreases further in the presence of the inhibitor. Radilla et al. [25] have studied the adsorption of the corrosion inhibitor 2-mercaptoimidazole onto Fe (1 0 0) surface.

The presence of heteroatoms with a number of lone pairs of electrons may result in the protonation of the inhibitor at the heteroatom centers. Therefore, several works have been done in this area. In the quinoline derivatives [26] (the N atom is the only heteroatom), protonated species is more electron deficient than the non-protonated species. Theoretical studies on phenazine and related compounds as corrosion inhibitors for mild steel in sulfuric acid medium [27] show that molecules with N atoms are preferentially protonated in acidic medium while molecules with S and O atoms do not prefer to undergo protonation, which confirms the results obtained from the calculation of the proton affinity. All the quinoxaline molecules have N atoms; they are all likely to be protonated in aqueous acid medium [28]. A comparison of the quantum chemical reactivity parameters for protonated species and the neutral species indicates the relative tendency of these species to interact with the metal surface.

The objective of this paper is to carry out a theoretical study on the corrosion inhibition effect of two pyrimidine derivatives, which have a class of sulfur and nitrogen-containing compounds. Caliskan et al. studied the corrosion inhibition effect of same pyrimidine derivatives in 1 M HCl solution at 298 K using polarization and impedance techniques [29]. The pyrimidine derivatives that were studied by us and also investigated by Caliskan et al. in their work are 5-Benzoyl-4-(4-carboxphenyl)-6-phenyl-1,2,3,4-tetrahydro-2-iminopyrimidine (BCPTI) and 5-Benzoyl-4-tolyl-6-phenyl-1,2,3,4-tetrahydro-2-thioxopyrimidine (BTPTT) [29]. The composition of the studied austenitic chromium–nickel steel is as follows: (composition is expressed in weight %) C: 0.0425; Si: 0.421; Mn: 2.13; P: 0.0133; S: 0.113; Cr: 18.51; Mo: 0.563; Ni: 8.34; Al: 0.0334; Co: 0.0901; Cu: 0.358; Fe: balance [29].

Computational methods

The calculations on BCPTI and BTPTT were performed by Gaussian09 [30] software using the B3LYP function and the 6-311++G (d, p) basis set. This software has been used specifically for systems containing transition metal atoms. These calculations were performed to investigate the structural parameters that affect the inhibition efficiency of the two pyrimidine derivatives and also to study the adsorption mechanisms on the austenitic stainless steel surface. From the optimized geometries of BCPTI and BTPTT, their global molecular descriptors [3144] such as the energy of the highest occupied molecular orbital (E HOMO), the energy of the lowest unoccupied molecular orbital (E LUMO), the energy gap (∆E), the ionization potential (IP), the electron affinity (EA), the global hardness (η), the electronegativity (χ), the global softness (σ), the electrophilicity (ω), the electrodonating (ω ), the electroaccepting (ω +), the net electrophilicity (Δω ±), the fraction of electron transferred (∆N), the total negative charge (TNC) and the dipole moment (μ) were calculated. It is expected that the properties of molecules and ions to be different in gas and liquid phases. In this work, all calculations for solvent effect on the inhibitors were carried out using the IEFPCM method [45]. The theoretical results can be used to identify compounds with desired properties using quantitative structure activity relationship (QSAR) method [46]. The correlation between the inhibition efficiencies of the compounds indicated that QSAR method could be used to study the inhibitors. A quadratic model has been suggested to calculate the approximate inhibition efficiencies. According to this model, the regression analyses fitted the Caliskan et al. experimental data [29] well and the calculated inhibition efficiencies of the two pyrimidine derivatives were found to be close to their experimental values.

Results and discussion

Reactivity parameters

The structures and the optimized configurations of the BCPTI and PTPTT corrosion inhibitors are shown in Fig. 1. The inhibitor conformers are considered to be minima based on the absence of imaginary frequencies. The HOMO and the LUMO of the BCPTI and PTPTT inhibitors in gas and liquid phases are shown in Fig. 2.

Fig. 1
figure 1

The structures and the optimized geometries of the BCPTI and PTPTT inhibitors

Fig. 2
figure 2

The HOMO and the LUMO of the BCPTI and BTPTT inhibitors in gas and liquid

The HOMO of the BCPTI molecule is delocalized throughout the system except on ring d and has maxima on C2, C6, C4, C8 and C10 atoms in particular on heteroatoms N and N2. The LUMO is delocalized throughout the BCPTI system except on ring a, and has maxima on ring d (see Fig. 2), C12 and O atoms in both gas and liquid phases. The HOMO of the BTPTT molecule is delocalized on ring b and has maxima on S and C12 atoms in gas phase. The maxima of the HOMO is delocalized on ring a, a slight delocalization on rings b and c and has maxima on S and C12 atoms. The LUMO is delocalized throughout the BTPTT system except on ring a in both phases (see Fig. 2). The LUMO of the BTPTT has maxima on C12 and C10 atoms in particular on heteroatoms O and S in both phases. The regions of a molecule on which their HOMO are distributed indicate the sites which have the highest tendency to interact with a metal surface. The LUMO indicates regions which have the highest tendency to accept electrons.

Table 1 shows the bond lengths and angles of the BCPTI and BTPTT inhibitors that are considered to be significant. A comparison of bond lengths and angles for both gas and liquid phases shows the effect of solvent on the geometry. The changes in the bond lengths are less than 0.014 and 0.02 Å for BCPTI and BTPTT, respectively. This suggests that protonation has minimal influence on the bond lengths of the inhibitors. The bond angles vary (in both directions) by <3° in both structures with the exception of the C8–C11–C12–O, C5–C8–N1–C9 and N2–C10–C19–C24 in BCPTI structure. The lengthening of C1=O1 (1.225 Å) and C9–S (1.695 Å) bond distances in their respective structures was noted in liquid phase which is probably the result of the high polarity of these bonds.

Table 1 Comparison of the bond lengths and bond angles of BCPTI and BTPTT in gas and liquid phases

The quantum chemical descriptors are listed in Table 2 for the BCPTI and BTPTT molecules in gas and liquid phases. Table 2 descriptors were calculated by both energetic parameter and orbital parameter methods. The quantum chemical descriptors of the BCPTI and BTPTT molecules are not similar in gas and liquid phases in particular the dipole moment of BCPTI compound.

Table 2 The quantum chemical descriptors of the BCPTI and BTPTT

The binding ability of the BCPTI and BTPTT inhibitors to a metal surface increases with increasing HOMO and decreasing LUMO energies. The higher the value of E HOMO becomes, the lower will be the capability of an inhibitor to accept electrons because the E HOMO describes the electron-donating ability of the inhibitor. The energy of the LUMO indicates the ability of a molecule to accept electrons and thus the lower the value of E LUMO becomes, the more probable that the molecule would accept electrons. Table 2 shows BCPTI and BTPTT have similar E HOMO in gas and liquid phases but the E LUMO of BTPTT is lower than the E LUMO of BCPTI in both phases.

The gap between the HOMO and LUMO energy levels of the BCPTI and BTPTT molecules is a function of reactivity of the inhibitors with a metallic surface. The BCPTI and BTPTT have similar energy gaps in gas phase but BTPTT has a lower energy gap in liquid phase. The binding ability of the inhibitors to a metal surface increases with decreasing energy gap. This means that the BTPTT molecule could perform better as a corrosion inhibitor in liquid phase.

Ionization potential (IP) is a basic descriptor of the chemical reactivity of atoms and molecules. IP is the minimum energy required to remove an electron from an atom. Chemical potential indicates the molecular capability of accepting electrons. A low IP indicates less energy needed to remove electrons from a system and also low stability. Similarly, a low chemical potential indicates low stability. Table 2 shows BCPTI and BTPTT have low ionization energies in gas and liquid phases.

The absolute hardness and softness are important properties for measuring a molecular stability and reactivity. Table 2 shows that BCPTI has a lower hardness and a higher softness in gas and liquid phases (except for values obtained by orbital parameter method) which reflect the high reactivity of BCPTI as compared with BTPTT.

A hard molecule has a large energy gap and a soft molecule has a small energy gap. Soft molecules are more reactive than hard ones because they could easily offer electrons to an electron acceptor. BCPTI is a soft molecule in both gas and liquid phases. It has a small energy gap in gas phase but a large energy gap in liquid phase. BCPTI molecule is more reactive than BTPTT in gas phase but is less reactive than BTPTT in liquid phase as indicated by calculations based on orbital parameter. The ability of an inhibitor molecule to accept electrons is described by its electrophilicity index. Electrophilicity is a measure of the energy stabilization after a system accepts additional amount of electron charge from its environment.

Based on energetic parameter calculations, BCPTI has a lower value of electrophilicity in gas phase and therefore this molecule is a stronger nucleophile than BTPTT but based on orbital parameter calculations, the BCPTI is a weaker nucleophile than BTPTT in liquid phase. A larger electroaccepting value corresponds to a better capability of accepting charge, whereas a smaller value of electrodonating value of a system makes it a better electron donor [47].

The calculated electrodonating, electroaccepting and net electrophilicity values of the BCPTI and BTPTT inhibitors are listed in Table 2. The energy parameter indicates BCPTI is a better electron donor than BTPTT in gas phase and the orbital parameter indicates BCPTI is also a better electron donor than BTPTT in liquid phase. In contrast to this, the energy parameter indicates BTPTT molecule has a better capability of accepting charge in gas phase and the orbital parameter indicates BTPTT molecule has also a better capability of accepting charge in liquid phase. The total electrophilicity indicates BCPTI is the strongest nucleophile in gas phase if energy parameter is applied and also is the strongest nucleophile in liquid phase if orbital parameter is applied. In contrast to this, BTPTT molecule is the strongest nucleophile in gas phase if orbital parameter is applied and also is the strongest nucleophile in liquid phase if energy parameter is applied. These are similar to the results obtained by the electrophilicity index. The calculated back-donation (∆E T) values of the inhibitors are listed in Table 2. This Table shows the back-donation (∆E T) values are similar to global softness values (σ).

The trend of electrons’ donation within a set of inhibitors is described by the fraction of electrons transferred (∆N). If ∆N is below 3.6 eV, then the inhibition efficiency increases with increasing ω ability at the mild steel interface [48]. Table 2 shows that all values of the ∆N are below 3.6 eV and the BCPTI and BTPTT have the highest values of ∆N in gas and liquid phases. Because iron is the major constituent of austenitic stainless steel, the theoretical values of the iron electronegativity (χ Fe = 7 eV) and the iron global hardness (η Fe = 0) were used to compute ΔN for the various Hamiltonians [49].

The calculations show that BTPTT and BCPTI have the highest TNC values in gas and liquid phases. The adsorption of the inhibitor onto the mild steel surface is enhanced at higher TNC values. The TNC values of the BTPTT and BCPTI molecules are higher in liquid phase than in gas phase.

Information about the polarity of a molecule describes its μ. In general, there is no significant relationship between the μ values and inhibition efficiencies. In some systems, the μ appears to increase with increasing inhibition efficiencies [50] while in some other systems the μ appears to decrease as the inhibition efficiency increases [51]. Table 2 shows that BCPTI has the highest μ value in gas and liquid phases and the highest molecular mass. There is a correlation between the molecular mass and the inhibition efficiency. As a molecular mass increases, its adsorption on a metal surface will increase. Inhibition efficiency increases as adsorption increases. It is clear from Table 2 that μ is higher in water than in gas and this is an indication of the polarization effect of the solvent on the inhibitor molecules. The difference between the μ values of BTPTT in gas and water is 2.02 but for BCPTI this difference is 6.61. This demonstrates that the polarization effect of the solvent on BCPTI molecule is more than its effect on the BTPTT molecule. This is because BCPTI has two oxygen atoms and a nitrogen atom but BTPTT has a sulfur atom.

From the computed results obtained for gas and liquid phases (Table 2), we can easily notice the stabilization effect of the solvent on the significant decrease of the E T values of the two inhibitors. The E T values show that BCPTI is more stable than BTPTT.

QSAR consideration

The QSAR method was used to correlate the inhibition efficiencies of the BCPTI and BTPTT with their molecular structures in gas and liquid phases. Attempts were made to establish a relationship between the experimental corrosion inhibition efficiencies and the calculated quantum chemical parameters. To obtain equations that are useful in predicting inhibition efficiency (Iecal) from the concentrations of the inhibitors and their quantum chemical parameters, Eq. (1) has been proposed to calculate the Iecal.

$$ {\text{Ie}}_{\text{calc}} {\% } = A + \frac{{B_{1} X_{1} }}{{C_{1} }} + \frac{{B_{2} X_{2} }}{{C_{2}^{2} }} + \frac{{B_{3} X_{3} }}{{C_{3}^{3} }} + \cdots \in + \frac{{B_{n} X_{n} }}{{C_{n}^{n} }}, $$
(1)

where A and B n are constants obtained by regression analysis, X n parameters are the independent variables consisting of quantum chemical values and C n parameters are the inhibitor concentrations. The Eq. (1) shows that inhibition efficiency strongly depends on density parameter. To simplify the Eq. (1), only the first four terms were used.

$$ {\text{Ie}}_{\text{calc}} \% = A + \frac{{B_{1} X_{1} }}{{C_{1} }} $$
(2)
$$ {\text{Ie}}_{\text{calc}} \% = A + \frac{{B_{1} X_{1} }}{{C_{1} }} + \frac{{B_{2} X_{2} }}{{C_{2}^{2} }} $$
(3)
$$ {\text{Ie}}_{\text{calc}} \% = A + \frac{{B_{1} X_{1} }}{{C_{1} }} + \frac{{B_{2} X_{2} }}{{C_{2}^{2} }} + \frac{{B_{3} X_{3} }}{{C_{3}^{3} }} $$
(4)
$$ {\text{Ie}}_{\text{calc}} \% = A + \frac{{B_{1} X_{1} }}{{C_{1} }} + \frac{{B_{2} X_{2} }}{{C_{2}^{2} }} + \frac{{B_{3} X_{3} }}{{C_{3}^{3} }} + \frac{{B_{4} X_{4} }}{{C_{4}^{4} }}. $$
(5)

Equations (25) were utilized to correlate the composite index of the quantum chemical parameters with the experimental inhibition efficiency (I exp %) of the studied inhibitors. Tables 3 and 4 show the fitted equations obtained using multiple regression analyses. Table 5; Figs. 3 and 4 show that the Iecal % values of BCPTI and BTPTT, calculated by using Eqs. (5) and (3), agree well with the experimental results.

Table 3 A pair of quantum chemical parameters utilized to derive the multiple regression Eq. (1) that correlates the theoretically estimated and the experimentally determined inhibition efficiencies, for BCPTI
Table 4 A pair of quantum chemical parameters utilized to derive the multiple regression Eq. (1) that correlates the theoretically estimated and the experimentally determined inhibition efficiencies, for BTPTT
Table 5 Experimental inhibition efficiencies of BCPTI and BTPTT and computational inhibition efficiencies at different concentrations using Eqs. (25)
Fig. 3
figure 3

The plots of experimental inhibition efficiencies of BCPTI and computational inhibition efficiencies at different concentrations using Eqs. (25). The R2 values are also reported

Fig. 4
figure 4

The plots of experimental inhibition efficiencies of BTPTT and computational inhibition efficiencies at different concentrations using Eqs. (2, 3). The R2 values are also reported

Local molecular reactivity

Selectivity parameters indicate the regions of a molecule that are likely to interact with a metal surface. These parameters include the Mulliken atomic charges, distribution of frontier molecular orbital and the Fukui functions [52]. An atom with the highest negative partial atomic charge interacts most strongly with a metal surface through a donor–acceptor type of interaction because it represents the site with the highest electron density. Tables 6 and 7 report the Mulliken atomic charges of the atoms in the anionic (Q N+1), neutral (Q N ) and cationic (Q N−1) states of the studied compounds in both phases. Q N+1 is an anion with an electron added to the LUMO of its neutral molecule. Q N−1 is a cation with an electron removed from the HOMO of its neutral molecule.

Table 6 Calculated Mulliken atomic charges for BCPTI using DFT at the B3LYP/++6-31G (d, p) basis set
Table 7 Calculated Mulliken atomic charges for BTPTT using DFT at the B3LYP/++6-31G (d, p) basis set

The highest negative charges are on C6 and C10 atoms of the BCPTI in its gas phase and on C10 atom in its liquid phase. High negative charges exist on oxygen and nitrogen atoms of the BCPTI.

The highest negative charges are on C12 and the heteroatom S of the BTPTT in both phases. Because heteroatoms have lone pair of electrons, these lone pair of electrons could be donated to the vacant s or partially filled d orbital of a metal and thereby facilitate the adsorption of the inhibitor on the metal surface. BCPTI has more heteroatoms than BTPTT. Therefore, BCPTI has a higher charge density and would interact with a metal surface at more sites than BTPTT. BTPTT has the highest sites for adsorption onto a metal surface because it has the highest number of heteroatoms.

The Fukui indices permit the distinction between the reactive regions of a molecule, the nucleophilic and electrophilic behaviors of a molecule and the chemical reactivity. These functions can be given by Eqs. (6) and (7) [53]:

$$ f^{ + } = Q_{N + 1} - Q_{N} $$
(6)
$$ f^{ + } = Q_{N} - Q_{N - 1} . $$
(7)

The calculated values of the Fukui functions for the non-hydrogen atoms are reported in Tables 8 and 9.

Table 8 Calculated Fukui functions for BCPTI using DFT at the B3LYP/++6-31G (d, p) basis set
Table 9 Calculated Fukui functions for BTPTT using DFT at the B3LYP/++6-31G (d, p) basis set

The maximum of f+ corresponds to reactivity with respect to nucleophilic attack and the maximum of f shows the preferred site for adsorption of electrophilic agents. For BCPTI, the highest f + is associated with C13 and O atoms in gas phase and O atom in liquid phase and the highest f occurs at C10 and C11 atoms in gas phase and at C2 and C8 atoms in liquid phase. The BTPTT sites for nucleophilic attack are the S atoms in gas phase and O atoms in liquid phases. However, the BTPTT sites for electrophilic attack are only the S atoms in both gas and liquid phases.

The adsorption of inhibitors on austenitic stainless steel

Iron is the major element of the austenitic stainless steel. Therefore, the iron interaction with the inhibitor molecules should be investigated [2628]. The binding capability of a metal on the inhibitors depends strongly on the electronic charge of the active site. The Mulliken atomic charges, distribution of frontier molecular orbital and the Fukui functions show that iron atom is located among C6, C8, C10 and O atoms of BCPTI molecule whereas in BTPTT molecule, the iron atom Therefore, BCPTI and BTPTT were allowed to interact with the Fe metal at the C6, C8, C10 and the S atom. The interaction energy between the inhibitor and the metal was then estimated as the difference between the energy of the complex (E Fe−X) and the sum of the energy of the isolated inhibitor and isolated Fe atom (E X + E Fe) resulting in the equation: E interaction = E Fe−X − (E X + E Fe). The binding energy of the inhibitor molecule is the negative value of interaction energy [54].

The optimized inhibitor···Fe complexes are shown in Fig. 5. The inhibitor···Fe separation distance, the calculated interaction and binding energy are reported in Table 10. The strong adsorption between the inhibitor molecules and the iron can be estimated as the larger negative values of interaction energy [55]. Table 10 shows that BCPTI has the highest interaction energy and therefore has the highest inhibition efficiency. From the theoretical point of view, the higher magnitude of BCPTI binding energy suggests a more stable adsorption and a higher inhibition efficiency system.

Fig. 5
figure 5

The structures of Fe–inhibitor complexes (using DFT/B3LYP/6-311++G (d, p))

Table 10 The interaction energy and the energy binding between the metal and the inhibitor

Conclusions

Quantum chemical calculations based on density functional theory method were performed on two pyrimidine derivatives which may be used as corrosion inhibitors for austenitic stainless steel. The quantum chemical properties of the two pyrimidine derivatives that are most relevant to their potential action as corrosion inhibitors were calculated in gas and liquid phases for comparison purposes. Our results indicate computational data for liquid phase represent the experimental results better than the data for gas phase. The quantum chemical parameters of the inhibitors are different in gas and liquid phases and some of the same type parameters obtained by orbital method are different from those obtained by energy method. We have not been able to establish relationships between some of quantum chemical parameters, e.g., molecular softness and energy gap.

In this study, the corrosion inhibition capabilities of the BCPTI and BTPTT were investigated. We have made the following conclusions:

  1. 1.

    BTPTT has a smaller energy gap than BCPTI in liquid phase and therefore it is a better inhibitor.

  2. 2.

    Based on global softness, hardness and chemical potential obtained by energy method but excluding calculations obtained by orbital method, BCPTI is a better inhibitor than BTPTT in both gas and liquid phases.

  3. 3.

    Based on dipole moment and molecular mass, BCPTI is a better inhibitor than BTPTT in both gas and liquid phases.

  4. 4.

    An equation has been proposed to calculate the inhibition efficiency. The regression analyses fitted the Caliskan et al. experimental data well and the calculated inhibition efficiencies of the studied compounds were found to be close to their experimental corrosion inhibition efficiencies.

  5. 5.

    The adsorption of the studied compounds onto the steel surface shows that BCPTI inhibitor has a higher magnitude of binding energy than BTPTT.

  6. 6.

    Overall, BCPTI may be a better inhibitor than BTPTT.