Introduction

Mild steel is widely used for the manufacture of a wide variety of metal structures and equipment. It is economical and easily available on the market [1]. In industries, during various industrial processes such as pickling, cleaning, etching, and acidification of oil wells, the mild steel is subjected to corrosion [2]. However, in recent years, it is preferable to use heterocyclic compounds as corrosion inhibitors to overcome this corrosion problem [3, 4]. In aggressive media (HCl, H2SO4, ...), the compounds that reduce the degradation of metallic materials can be distinguished into three types: surfactant inhibitors, organic inhibitors and inorganic inhibitors [5,6,7,8,9,10,11,12,13,14,15,16]. Among the commonly available acids are hydrochloric acid, which is replaced by sulfuric acid [17] and other acids such as nitric acid, perchloric acid, citric acid acetic acid, and formic acid, which are used only for specific applications.

The choice of effective mild steel corrosion inhibitors was based on their mechanism of action and their ability to produce electrons [18]. Moreover, the heterocyclic organic inhibitors have many advantages for the inhibition of corrosion in an acid medium [19]. Quinazolinone derivatives are the effectiveness of corrosion inhibition on the mild steel surface in acidic media. Many researchers have investigated the quinazoline compounds as corrosion inhibitors, since their nitrogen atoms with a free pair of electrons act as potential sites for bonding with metals, thereby inhibiting corrosion [20,21,22,23,24,25,26,27].

The novelty of this work lies in the synthesis of three new quinazolinone compounds derivatives of 8-hydroxyquinoline to obtain a new variety of multifunctional heterocycles, having several reactive sites for use as corrosion inhibitors of mild steel in acidic medium. The corrosion inhibiting action find out about of these compounds was evaluated by electrochemical methods (potentiodynamic polarization, impedance spectroscopy) and gravimetric methods (mass loss). in addition, MC simulations and DFT calculations are employed to discuss the adsorption configuration to give an explanation for the corrosion inhibition mechanism of utilized inhibitors on the MS surface.

Procedure

General information

Unless otherwise stated, all the reagents and solvents used in this study were obtained from Sigma-Aldrich Chemical Company (Spain or France). Melting points were determined on Banc Kofler apparatus and are uncorrected. The recording of NMR spectra was performed on a Bruker Advanced 300 WB at 300 MHz for solutions in Me2SO-d6 and chemical shifts are given in δppm with reference to tetramethylsilane (TMS) as an internal standard. The elemental composition (carbon, hydrogen, and nitrogen) was determined on a Perkin-Elmer Model 240 CHN Analyzer. The progress of the reaction is followed by chromatography with thin layer (TLC) of silica 60 F254 (E. Merck).

The mild steel samples were used with C, 0.11; Si, 0.24; Mn, 0.47; Cr, 0.12; Mo, 0.02; Ni, 0.1; Al, 0.03; Cu, 0.14; Co, < 0.012; V, < 0.003; W, 0.06; Fe, balance; and the remainder of iron. Before any measurement, they were abraded with a series of emery paper grades 180–1200. The specimens are thoroughly washed with double distilled water, degreased with acetone and then dried. The aggressive solution 1 M HCl was prepared by the dilution of concentrated HCl (37%) analytical grade with bi-distilled water.

Synthesis methods

A mixture of quinazolinone derivatives (1 eq) and 5-chloromethyl-8-hydroxy-quinolinehydrochloride (2 eq) in 50 mL of pure tetrahydrofuran in the presence of triethylamine (2 eq) was refluxed for 24 h under stirring. The reaction was monitored by CCM. After evaporation of the solvent, the residue obtained was hydrolyzed with a saturated NaCl solution (20 mL), extracted with chloroform (3 × 20 mL). The combined organic layers were dried over anhydrous magnesium sulfate, filtered, and evaporated in vacuum to give crudes products as solids. The purification of the product was realized by chromatography on a silica gel column utilizing dichloromethane/hexane (85:15, v/v), and then recrystallized from absolute ethanol, (Scheme 1).

Scheme 1
scheme 1

Synthetic route for the preparation of quinazoline derivatives based on 8-hydroxyquinoline

Corrosion tests

The electrochemical techniques have been described in the same previous public work [15]. The values of performance ηPDP(%) are calculated utilizing Eq. 1:

$$ {\eta}_{\mathrm{PDP}}\left(\%\right)=\kern0.36em \left(\frac{i_{\mathrm{corr}}\kern0.36em -{i}_{\mathrm{corr}}^{\hbox{'}}}{i_{\mathrm{corr}}}\right)\times 100 $$
(1)

where icorr is the corrosion current density in the absence of HQ-ZH, HQ-ZNO2, and HQ-ZOH, and \( {i}_{\mathrm{corr}}^{\hbox{'}} \) is the corrosion current density with HQ-ZH, HQ-ZNO2 and HQ-ZOH [15].

The conventional electrochemical impedance spectroscopy (SIE) was run at a frequency ranging from 100 kHz up to 100 mHz with a.c. amplitude 10 mV at OCP [15]. All the electrochemical experiments were performed at room temperature (298 ± 2 K) but potentiodynamic polarization study was carried out at various temperature range from 298 to 328 ± 2 K for calculating kinetic and thermodynamic parameters. Nyquist plots were made from these experiments. The best fit of the experiments was done utilizing Bouckamp program. The Eq. 2 was utilized to estimate the ηEISηEIS(%):

$$ {\eta}_{\mathrm{EIS}}\left(\%\right)=\left(\frac{R_p-{R}_p^{\hbox{'}}}{R_p}\right)\times 100 $$
(2)

where RpRp is of polarization resistance in the presence of HQ-ZH, HQ-ZNO2, and HQ-ZOH, and \( {\mathrm{R}}_{\mathrm{p}}^{\prime } \) is the value of polarization without inhibitors.

Surface analysis

Scanning electron microscopy

After immersing in a solution of HCl (1 M) for 6 h except and with optimum concentration (1 mM) of quinazoline derivatives, the surface of the steel was analyzed by way of scanning electron microscopy (SEM). The method of sample preparation in our steel was identical to that described in the “General information” section. The SEM images were performed on the surface of the MS panels in the absence and in the presence of HQ-ZH, HQ-ZNO2, and HQ-ZOH to analyze the morphology of the deposited protective layers.

UV-visible spectra

To discover more data on the bonding mechanism of MS surfaces/compounds/aggressive environment, corrosion protection was also investigated by means of ultraviolet-visible spectrophotometry (UV-Vis), before and after immersion of the MS sample for 24 h. The Jenway ultraviolet-visible spectrophotometer (series 67) was once utilized for this analysis.

Theoretical studies

Density functional theory

The GAUSSIAN 09 W [11] software was utilized to process quantum parameters, the geometry of the studied molecules was fully optimized by the DFT method at B3LYP level with the bases 6-31G (d, p) and 6-311G (d, p) in two gaseous and aqueous phases.

The values of the energies of the HOMO and LUMO orbitals were determined by the electronic affinity and ionization energy [28]:

$$ IP=-{E}_{HOMO} $$
(3)
$$ EA=-{E}_{LUMO} $$
(4)

In order to find the values of the electronegativity and the overall hardness of the inhibitory molecule, the values of A and I are treated by the eq. (5, 6), [29, 30]:

$$ \chi =\frac{IP+ EA}{2} $$
(5)
$$ \eta =\frac{IP- EA}{2} $$
(6)

The number of transferring electrons (∆N) was calculated according to eq. 7.

$$ \varDelta N=\frac{\phi -{\chi}_{\mathrm{inh}}}{2\left({\eta}_{Fe}+{\eta}_{\mathrm{inh}}\right)} $$
(7)

ϕ is the work function utilized as the measure of electronegativity of iron, and ηFe = 0. The value of ϕ = 4.82 eV for Fe (110) surface which is reported to have higher stabilization energy [31].

The local reactivity of molecular (electrophilic and nucleophilic attacks) were obtained by Fukui functions using the following equations [32]:

$$ {f}_i{\left(\overrightarrow{r}\right)}^{+}={q}_i\left(N+1\right)-{q}_i(N) $$
(8)
$$ {f}_i{\left(\overrightarrow{r}\right)}^{-}={q}_i(N)-{q}_i\left(N-1\right) $$
(9)

where qi(N + 1), qi(N), qi(N-1) are charge values of atom i for cation, neutral and anion, respectively. Fukui indices were performed by the method DFT/B3LYP / 6-31G (d, p) [33].

Monte Carlo simulations

Metropolis Monte Carlo simulations utilizing simulated annealing procedure were carried out to quantify the adsorption of HQ-ZH, HQ-ZNO2, and HQ-ZOH on Fe (110) surface. The simulation box consisted of 5 layers of iron atoms cleaved along the (110) plane. A supercell of (10 × 10) was created and vacuum layer of 50 nm height was fabricated. Optimized HQ-ZH, HQ-ZNO2, and HQ-ZOH molecules were positioned near the surface of Fe (110) plane utilizing the simulated annealing adsorption locator module with COMPASS force field. The simulations were performed under fine convergence conditions, while each simulation went through 5 cycles at 50,000 steps per cycle. Lowest adsorption energies were obtained and documented for HQ-ZH, HQ-ZNO2, and HQ-ZOH as they interact with the Fe surface.

Results and discussions

Chemistry

Data, value and validation

Characterization of 3-((8-hydroxyquinolin-5-yl)-methyl)-2-phenylquinazolin-4(3H)-one (HQ-ZH)

Yield: 80%, Aspect: white solid, Mp = 162–164 °C, Rf = 0.25 (hexane/ethanol, 70/30: v/v). IR (νmax/cm−1): 1300–1600 (C=C), 1419.41 (C=N), 3248.08 (OH bonded), 2367.24–2888.57 (C-H), 1624.09 (CH2). 1H (300 MHz, DSMO-d6): δppm = 5.12 (S, 2 H, CH2), 5.61 (S, 1 H, OH), 7.59-7.61-7.63-8.81-8.82 (m, 5 H, ArH-quinoline) 7.25-7.60-7.91-8.99-9.02 (m, 9 H, ArH-quinazolinone). 13C (300 MHz, DSMO-d6): δppm = 69.53 (CH2), 148.76 (ArC-OH), 152.35 ((N=C(Ph)N), 153.91 (C=O), 126.90–126.99-127,74-128.28-13.52-132.69-133.31 (ArCH-quinazolinone), 119.69-129.26-148.28 (ArC-quinazolinone), 112.55-122.156-13.71-148.40 (ArCH-quinoline), 127.74-122.74-139.31 (ArC-quinoline).

Analysis elemental:

  • Calculated: C, 75.97%; H, 4.52%; N, 11.08%.

  • Obtained: C, 76.01%, H, 4.53%, N, 11.12%.

Characterization of 3-((8-hydroxyquinolin-5-yl)-2-(4-nitrophenyl)-quinazolin-4(3H)-one (HQ-ZNO2)

Yield: 65%, Aspect: yellow solid, Mp = 169–171 °C, Rf = 0.29 (hexane/ethanol, 70/30: v/v).

IR(νmax/cm−1): 1518.39–1642.49 (C=C), 1451.13 (C=N), 3414.35 (OH bonded), 2036.30 (C-H), 1624.49 (CH2). 1H (300 MHz, DSMO-d6): δppm = 5.22 (S, 2 H, CH2), 5.72 (S, 1 H, OH), 7.12-7.24-7.62-8.92-9.98 (m, 5 H, ArH- quinoline), 7.63-7.65-8.86-8.88-8.89 (m, 8 H, ArH-quinazolinone). 13C (300 MHz, DSMO-d6): δppm = 46.12 (CH2), 152.87 (ArC-OH), 152.19 (C=O) 151.00 ((N=C(ph)N), 124.64-125.97-126.92-127.39-128.64-138.76 (ArCH-quinazolinone), 121.78-133.93-145.88-148.0 (ArCquinazolinone), 111.24-122.03-127.18-130.30-152.188 (ArCH-quinoline), 127.18-127.78-128.77 (ArC-quinoline).

Analysis elemental:

  • Calculated: C, 67.92%; H, 3.80%; N, 13.20%.

  • Obtained: C, 67.95%, H, 3.79%, N, 13.15%.

Characterization of 2-(2-hydroxyphenyl)-3-((8-hydroxyquinolin-5-yl)-methyl)-quina-zolin-4 (3H)-one (HQ-ZOH)

Yield: 70%, Aspect: brown solid, Mp = 149–151 °C, Rf = 0.31 (hexane/ethanol, 70/30: v/v). IR: 1723.95–1777.87 (C=C), 1505.86 (C=N), 3641.79 (OH bonded), 2037.54 (C-H), 1794.99 (CH2). 1H (300 MHz, DSMO-d6): δppm = 5.33 (S, 2 H, CH2), 6.43 (S, 2 H, OH), 7.08-7.41-7.64-8.66-8.89 (m, 5 H, ArH-quinoline), 7.06-7.38-7.63-7.66-7.67-8.65-8.68 (m, 8 H, ArH-quinazolinone).

13C (300 MHz, DSMO-d6): δppm = 61.10 (CH2), 152.04 (ArC-OH quinoline), 147.99 (ArC-OH benzene rang of quinazolinone) 155.74 (C=O) 153.06 ((N=C(ph)N), 122.44-126.11-127.60-128.491-128.84-130.46-134.59 (ArCH-quinazolinone), 111.62-123.11-140.90 (ArC-quinazolinone), 116.11-126.11-128.62-134.59-139.26 (ArCH-quinoline), 127.72-130.02-138.08 (ArC-quinoline).

Analysis elemental:

  • Calculated: C, 72.90%; H, 4.33%; N, 10.63%.

  • Obtained: C, 72.88%, H, 4.35%, N, 10.53%.

Electrochemical impedance spectroscopy measurements

EIS measurements were performed to study the impedance parameters MS in 1 M HCl at various concentrations of HQ-ZH, HQ-ZNO2, and HQ-ZOH at 298 ± 2 K. Before each test, the working electrode was immersed in the test solution for 1/2 h at 298 ± 2 K to attain the steady potential. To analyze the impedance parameters from the experimental outcomes, the data were fitted to the electrical equivalent circuit. Figure 2 shows the used electrical equivalent circuit in the appearance and non-appearance of HQ-ZH, HQ-ZNO2, and HQ-ZOH. The EIS curves (Nyquist) for MS with and without HQ-ZH, HQ-ZNO2, and HQ-ZOH are shown in Fig. 1. According to these figures, all plots show only one time constant and the semicircular shape did not change after addition of HQ-ZH, HQ-ZNO2, and HQ-ZOH [34]. This means that the corrosion reaction is under charge transfer control and the corrosion mechanism did not change. It can be seen from the Nyquist plots that the increase in inhibitor concentration resulted in the increase of diameter of Nyquist plots.

Fig. 1
figure 1

Nyquist plots for MS in 1 M HCl with 0–10−3 M concentrations of HQ-ZH, HQ-ZNO2, and HQ-ZOH at OCP and 298 ± 2 K

The equivalent circuit shown in Fig. 2 has been utilized to adapting of the experimental impedance data. The circuit includes constant phase elements (CPE), polarization resistance (Rp) and solution resistance (Rs). Generally, the double layer formed by the adsorption of inhibitors on the metal surface behaves like a CPE rather than a pure capacitor and, therefore, the capacitor has been replaced by CPE to fit more precisely the data of semicircle impedance. The admittance (YCPE) and the impedance (ZCPE) of the CPE can be represented by the following relationships (10,11):

$$ {Y}_{CPE}={Y}_0{\left( j\omega \right)}^n $$
(10)
$$ {Z}_{CPE}=\left(\frac{1}{Y_0}\right){\left[{\left( j\omega \right)}_n\right]}^{-1} $$
(11)
Fig. 2
figure 2

Equivalent circuit for MS/molar HCl/substituted quinazoline compounds

Where Y0 is the CPE constant, ω is the angular frequency; j is the imaginary number (i.e. j2 = −1) and n is the phase shift (exponent) which is related to the degree of surface in homogeneity.

The derived impedance parameters are presented in Table 1.

Table 1 Parameters of impedance and the corrosion inhibition performance of MS in 1 M HCl at different concentrations of HQ-ZH, HQ-ZNO2, and HQ-ZOH

In the light of the obtained results, we can make the following remarks:

The results in Table 1 show that the index values n in the presence of HQ-ZH, HQ-ZNO2, and HQ-ZOH greater than that of white, which suggests that the inhomogeneity of the surface decreases in the presence of the organic inhibitors this can be explained by the formation of a film protector on the steel surface. In addition, Rp values increase progressively with inhibitor concentrations that are attributed due to the adsorption of inhibitors on the metal surface that isolate the metal from the electrolyte and protect against corrosion [35, 36].

Another important thing was observed that Cdl values decrease after adding HQ-ZH, HQ-ZNO2, and HQ-ZOH. This also indicates that the thickness of the double layer increase with HQ-ZH, HQ-ZNO2, and HQ-ZOH concentration, which is well explained by this formula [35]:

$$ {C}_{dl}=\frac{\varepsilon_0\varepsilon }{d}S $$
(12)

where, ε0 is the permittivity of space, ε is the local dielectric constant, d is the film thickness and S is the surface area. From formula, it is found that Cdl is directly proportional to ε and inversely proportional to d. The Cdl value was decreased due to decrease in local dielectric constant because of replacement of water molecules (higher ε value) by the inhibitor molecules (lower ε value). The increase in thickness (d) of the electrical double layer was observed with increase in concentration of HQ-ZH, HQ-ZNO2, and HQ-ZOH which also play an important role in decrease of Cdl value [36].

On the other hand, the corrosion inhibiting performance increases with the concentration of the inhibitors to reach an optimal value of 95%, 93.90%, and 90.8% respectively for HQ-ZH, HQ-ZNO2, and HQ-ZOH. On the other hand, the HQ-ZNO2 inhibitor has a good performance compared to HQ-ZH and HQ-ZOH respectively in 1 M of HCl medium. This was explained by the nature and position of the groups (-NO2, -OH); para position gives a performance better than ortho position. The result was confirmed by the theoretical study (Fig. 3).

Fig. 3
figure 3

Bode and phase diagrams of steel after immersion in HCl solutiondifferent concentrations of inhibitors and blank solution

Stationary electrochemical study

Concentration effect

The concentration effect of the HQ-ZH, HQ-ZNO2, and HQ-ZOH on the polarization character for MS in 1 M HCl at 298 ± 2 K were analyzed. The Tafel plots were recorded at different inhibitor concentration, which is represented in Fig. 4. From Tafel plots we got the values of the anodic and cathodic Tafel slopes (βa& βc), corrosion current density (icorr), corrosion potential (EcorrEcorr) and corrosion restraint effectiveness (ηPDP%). Table 2 shows the polarization parameters for MS in 1 M HCl without and with different concentrations of HQ-ZH, HQ-ZNO2, and HQ-ZOH at 298 ± 2 K.

Fig. 4
figure 4

Potentiodynamic polarization curves for MS in 1 M HCl containing different concentration of HQ-ZH, HQ-ZNO2, and HQ-ZOH at 298 ± 2 K

Table 2 Polarization parameters for MS in 1 M HCl without and with different concentrations of HQ-ZH, HQ-ZNO2, and HQ-ZOH at 298 ± 2 K

Analysis of the potentiodynamic polarization curves shows that the HQ-ZH, HQ-ZNO2, and HQ-ZOH compounds decrease both the cathodic and anodic current densities, and their effect becomes more remarkable with increasing concentration. These results reveal that the HQ-ZH, HQ-ZNO2, and HQ-ZOH compounds inhibit both anodic metal dissolution and cathodic hydrogen evolution reactions. In addition, the increase of the protective effect with the inhibitor concentration reveals that quinazoline derivatives act by adsorption on the metallic surface [37].

No definite shift was observed in the corrosion potential (Ecorr) (Table 2). According to Riggs [38] and other authors [39], for an inhibitor of the cathodic or anodic type, the displacement should be more than 85 mV/Ecorr while for an inhibitor of the mixed type, it is equal to or less than 85 mV/Ecorr. In our case, the maximum displacement is < 85 mV/Ecorr, which indicates that HQ-ZH, HQ-ZNO2, and HQ-ZOH can be considered as a mixed-type inhibitor.

Addition of HQ-ZH, HQ-ZNO2, and HQ-ZOH to the corrosive environment causes a modification of cathodic Tafel slope (βc), indicating that the quinazoline derivatives have a direct influence on the kinetics of hydrogen evolution. Also, when compared corrosive environment, the values of the (βa) changed irregularly in the presence of quinazoline derivatives, which indicates that the anodic reaction is affected by the presence of HQ-ZH, HQ-ZNO2, and HQ-ZOH. The presence of heteroatoms with a lone pair of electrons, such as N and O atoms in HQ-ZH, HQ-ZNO2, and HQ-ZOH molecules can facilitate the formation of Fe(II)- HQ-ZNO2, Fe(II)- HQ-ZH, and Fe(II)- HQ-ZOH complexes, and thus changes the dissolution mechanism of iron [40].

The polarization results are in agreement with the results of the impedance spectroscopy.

Temperature effect

The stability of a corrosion inhibitor in an aggressive medium at given use temperatures is very important for its application. In acid stripping, the role of the inhibitors is to protect the metal installations against acid attacks. These stripping operations are usually carried out at high temperatures [41]. In our case, the study of the influence of temperature (298–328 ± 2 K) on the corrosion inhibition rate of MS for the three quinazoline was carried out potentiodynamic polarization. The cathodic and anodic polarization curves of steel in 1 M HCl medium in the absence and in the presence of HQ-ZH, HQ-ZNO2, and HQ-ZOH at 10−3 M are shown in Fig. 5. The values of corrosion current densities (icorr), corrosion potentials of steel (Ecorr), and the inhibitory performance of HQ-ZH, HQ-ZNO2, and HQ-ZOH as a function of temperature are given in Table 3. We note that the increase in temperature causes an increase in icorr and the inhibitory performance decreases throughout the temperature range studied [42]. It also shows that HQ-ZH, HQ-ZNO2, and HQ-ZOH retain their inhibitory properties for all temperatures studied. However, in the case of the inhibitor HQ-ZNO2 which proved to be the best inhibitor of this family, the decrease in the inhibitory performance is less important and reaches 90% at 328 K.

Fig. 5
figure 5

Effect of temperature on the polarization curves of MS in 1 M HCl and in the presence of HQ-ZH, HQ-ZNO2, and HQ-ZOH

Table 3 Values of the corrosion current density and the inhibition performance in the presence of 10−3 M of HQ-ZH, HQ-ZNO2, and HQ-ZOH at different temperatures

Kinetic activation parameters

The thermodynamic parameters specifically activation energy (Eact), entropy of activation (ΔSact) and enthalpy of activation (ΔHact) for corrosion reaction at 10−3 M for HQ-ZNO2, were calculated from Arrhenius and transition state plot. The activation energy was calculated by Arrhenius formula:

$$ {i}_{corr}=A\exp \left(\frac{-{E}_a}{RT}\right) $$
(13)

and other two parameters ΔHact and ΔSact were calculated utilizing the transition state formula:

$$ {i}_{\mathrm{corr}}=\frac{RT}{Nh}\exp \left(\frac{\varDelta {S}_{\mathrm{act}}}{R}\right)\exp \left(\frac{-\varDelta {H}_{\mathrm{act}}}{RT}\right) $$
(14)

where, R, T, A, N, and h are universal gas constant, absolute temperature, pre-exponential factor, Avogadro number and plank constant, respectively. The icorr values were obtained from the extrapolation of Tafel plot at different temperature with and without adding HQ-ZH, HQ-ZNO2, and HQ-ZOH molecules. Here, icorr values consider as a corrosion rate. From the Arrhenius plots, Ln icorr against 1000/T at optimum concentration of HQ-ZNO2, HQ-ZH and HQ-ZOH display in Fig. 6.

Fig. 6
figure 6

Arrhenius plots for MS corrosion in 1 M HCl in the absence and presence of HQ-ZH, HQ-ZNO2, and HQ-ZOH

According to Fig. 6, showing a straight line curve having a slope equal to –Ea/RT and Ea was calculated from this slope. Another plot of Ln (icorr /T) vs. 1000/T show a straight line curve (Fig. 7) with a slope and intercept those are equal to – ΔHact /R and Ln (R/Nh) + ΔSact/R, respectively.

Fig. 7
figure 7

Transition state plots for HQ-ZH, HQ-ZNO2, and HQ-ZOH in 1 M HCl medium on MS corrosion

The values of ΔHact and ΔSact listed in Table 4 which were calculated from the slope and intercept. From Table 4 and Fig. 6, it can be seen that the activation energy (Eact) in presence of three HQ-ZH, HQ-ZNO2, and HQ-ZOH is higher than the blank solution on MS corrosion which indicates the metal dissolution decreases in acidic medium because of increase in the energy barrier for MS corrosion. In 1965 Radovici proposes that when Eact (inh) > Eact (blank), inhibitors adsorbs on the substrate by electrostatic nature bonds (weak bonds). The results obtained in Table 5 indicate that the increase in activation energy in the presence of the studied inhibitors can be attributed to the phenomenon of physisorption. The bonds formed in this type of interaction can be sensitive to temperature and does not allow fighting effectively against corrosion when the temperature increases.

Table 4 Activation parameters of MS corrosion in 1 M HCl medium without and with addition of three HQ-ZH, HQ-ZNO2, and HQ-ZOH at 10−3 M
Table 5 Activation parameters of MS corrosion in 1 M HCl medium without and with addition of HQ-ZH, HQ-ZNO2, and HQ-ZOH at 10−3 M

Meanwhile, the activation entropy (ΔSact) value increases in addition of HQ-ZH, HQ-ZNO2, and HQ-ZOH compared to given acid solution and the values were found in negative. The higher ΔSact values in presence of HQ-ZH, HQ-ZNO2, and HQ-ZOH signified the entropy of the solvent increases. This may occur due to desorption of large numbers of water molecule which were already adsorbed on the metal surface and less disorder larger HQ-ZH, HQ-ZNO2, and HQ-ZOH molecules adsorbed on the MS surface [43, 44].

Isotherms and thermodynamic parameters of adsorption

The adsorption isotherm provides some useful information regarding corrosion mechanism. Many factors control the adsorption process, like nature of the metal surface and its charge, solvent, and other ionic species adsorption, electrochemical potential between metal-solution interface, temperature during corrosion reaction. The adsorption process is divided into two categories. First one is chemisorption; it occurs when the direct interaction between adsorbed inhibitors molecule and metal surface like donor-accepter type interaction. Chemical adsorption implies the charge sharing or charge transfer from adsorbates (inhibitor molecule) to the metal surface and forms a very strong metal-inhibitor coordinate bond. This types of interaction are basically irreversible in nature. The second one is physisorption; here, the inhibitor molecules adsorb on the metal surface through week undirected interaction which is basically formed due to the electrostatic interaction between metal and inhibitor’s solution interface [45]. To evaluate the adsorption isotherm nature, several adsorption isotherms were tested. It was observed that the adsorption of HQ-ZH, HQ-ZNO2, and HQ-ZOH on MS in 1 M HCl medium obey the Langmuir adsorption isotherm formula:

$$ \frac{C_{\mathrm{inh}}}{\theta }=\frac{1}{K_{\mathrm{ads}}}+{C}_{\mathrm{inh}} $$
(15)

where Kads,θ and Cinh are inhibitor adsorption constant, degree of surface coverage, and HQ-ZH, HQ-ZNO2, and HQ-ZOH concentration, respectively. Values of θ = ƞ/100 were taken from polarization measurement. The plot of Cinh/θ vs Cinh gave a straight line curve (Fig. 8) having 1/Kads intercept and the correlation coefficient (R2) value for three HQ-ZH, HQ-ZNO2, and HQ-ZOH is 1.00.

Fig. 8
figure 8

Langmuir adsorption isotherm plots for the adsorption of HQ-ZH, HQ-ZNO2, and HQ-ZOH on MS corrosion surface in 1 M hydrochloric acid

The straight line and strong correlation coefficient value indicate the Langmuir adsorption isotherm the best fitted with experimental data. The \( \varDelta {G}_{ads}^o \) value was calculated utilizing the formula:

$$ \varDelta {G}_{ads}^{{}^{\circ}}=- RT Ln\left(55.55{K}_{ads}\right) $$
(16)

where, T is the temperature, R is the gas constant. The values of Kads is represented here in L mol−1, thus in this formula the conc. of water is taken in L mol−1 (55.5 mol/L). In general when the obtained \( \varDelta {G}_{ads}^o \) values of inhibitor lie in the order of – 20 kJ mol−1 or even lower (more positive), it satisfies the physisorption of inhibitor on metal surface. While the \( \varDelta {G}_{ads}^o \) values around − 40 kJ mol−1 or higher (more negative) are associated with chemisorption [46]. The obtained \( \varDelta {G}_{ads}^o \) values of HQ-ZH, HQ-ZNO2, and HQ-ZOH are − 46.43 kJ/mol, − 43.76 kJ/mol, and − 43.14 kJ/mol for HQ-ZH, HQ-ZNO2, and HQ-ZOH, respectively (Table 6). The above range of \( \varDelta {G}_{ads}^o \) values indicates the contribution of chemisorption [47].

Table 6 Calculated quantum chemical parameters of the studied compounds

UV-visible spectroscopy

The absorption of monochromatic light is a suitable method for identification of complex ions, the absorption of light is proportional to the concentration of the absorbing species. For routine analysis, a simple conventional technique based on UV–vis absorption is the more sensitive direct spectrophotometric detection. Change in position of the absorption maximum and or change in the value of absorbance indicate the formation of a complex between two species in solution.

To better understand the binding mechanism between inhibitors and iron in the acid solution, we use UV-visible spectroscopy. The electron absorption spectra of HQ-ZNO2, HQ-ZH and HQ-ZOH solutions Fig. 9, before immersion of MS in 1 M HCl solution show visible absorption bands 251.93, 251.92, and 254.42 nm. respectively for HQ-ZNO2, HQ-ZH, and HQ-ZOH. This band may be assigned to the π − π* transition involving the whole electronic structure system of the substituted quinazoline compound with a considerable charge transfer character [10, 48].

Fig. 9
figure 9

UV-visible spectra of 1 M HCl solution containing 10−3 M of HQ-ZNO2, HQ-ZOH, and HQ-OH before (black) and after (red) After 24 h of MS immersion

However, after 24 h of immersion of specimen in aggressive solution Fig. 8, the absorption bands λmax underwent a bathochromic shift from 251.93 at 257.92 nm, 251.92 at 254.93 nm, and 254.42 at 260.77 nm, respectively for HQ-ZNO2, HQ-ZH, and HQ-ZOH. Our experimental findings are good evidence for the possibility of the formation of a complex among Fe2+ and inhibitors in HCl 1 M.

Surface morphology

Scanning electron micrographs (Fig. 10) of the mild steel surface in 1 M HCl with and without addition of HQ-ZNO2, HQ-ZOH, and HQ-OH were taken in order to establish whether inhibition is due to the formation of an organic film on the metal surface. The resulting of the high-resolution SEM micrograph shows that the steel surface was strongly damaged in the absence of the three inhibitors with the increased number and depth of the pits. However, there are less pits and cracks observed in the micrographs in the presence of HQ-ZNO2, HQ-ZOH, and HQ-OH (Fig. 10) which suggests a formation of protective film on steel surface which was responsible for the corrosion inhibition. Indeed, HQ-ZNO2, HQ-ZOH, and HQ-OH has a strong tendency to adhere to the steel surface and can be regarded as good inhibitors for steel corrosion in normal hydrochloric medium. The high inhibitive performance of these quinazoline derivatives suggests a strong bonding of the HQ-ZNO2, HQ-ZOH, and HQ-OH on the metal surface due to presence of lone pairs from heteroatom (nitrogen and oxygen) and π-orbitals, blocking the active sites and therefore decreasing the corrosion rate.

Fig. 10
figure 10

Surface morphology of MS before and after immersion for 6 h in 1 M HCl with 1 mM of HQ-ZNO2, HQ-ZOH, and HQ-ZOH

Theoretical calculations

Density functional theory

Frontier molecular orbitals

To obtain detailed information about the mechanism of inhibition, quantum theoretical calculation by the DFT 6–31 G (d,p) methods were carried out and compared with the experimental results. For this, we performed a theoretical calculation to determine the quantum chemical parameters, such as highest occupied molecular orbital energy (EHOMO), lowest unoccupied molecular orbital energy (ELUMO), energy gap (ΔE), dipole moment (μ) etc.

The energy (EHOMO) indicates the ability of the molecule to yield electrons to another empty molecular orbit, but the value of ELUMO energy describes the ability of a compound to accept electrons. The energy difference between (EHOMO) and (ELUMO) or energy gap is generally the lowest electronic energy excitation. The adsorption of energy between the metal surface of iron and the inhibitors increases once the gap energy decreases [49].

The optimized geometry of the structure, its HOMO and LUMO electron density distributions are given in Fig. 11.

Fig. 11
figure 11

Optimized structure and Frontier molecular orbital’s neutral of inhibitors molecules

The analysis of Fig. 11 shows that the electronic density for the three inhibitors, HOMO is distributed on the cycle quinoline.

The LUMO electronic density is localized on the ring substituted by -NO2 for HQ-ZNO2. However, for compounds HQ-ZH and HQ-ZOH, the LUMO is distributed throughout the cycle quinoline.

Frontier molecular orbital energies

The values of calculated quantum chemical parameters are listed in Table 6. The higher the (HOMO) energy of the inhibitor, the greater the trend of offering electrons to unoccupied (d) orbital of the metal, the lower the (LUMO) energy, The process of transition of electrons to the metal surface is easy, the analysis of Table 6 shows that the highest value of EHOMO (− 4.905 eV) of HQ-ZNO2 indicates a better inhibition performance than EHOMO (− 5.687 eV) of HQ-ZH and EHOMO (− 5.660 eV) of HQ-ZOH. The lower the ELUMO, the easier is the acceptance of electrons from the d-orbital of the metal. The lowest value of ELUMO (− 1.721 eV) of HQ-ZNO2 indicates a better inhibition performance in this family.

Low values of the energy of the gap ΔE = ELUMO − EHOMO implies that the energy to remove an electron from the last occupied orbital will be minimized, corresponding to improved inhibition efficiencies. The values of the gap energy are listed in Table 6. We notice that the values of the ∆E for the compounds tested HQ-ZNO2, HQ-ZOH, and HQ-OH are 3.184 eV, 4.218 eV, and 4.245 eV, respectively.

The quality of inhibition by the HQ-ZNO2 compound is higher than HQ-ZOH and HQ-ZH.

We classify these derivatives according to their energies of gape:

$$ \varDelta E\left( HQ- ZOH\right)>\varDelta E\left( HQ- ZH\right)>\varDelta E\left( HQ- ZN{O}_2\right) $$

The results obtained in Table 6 indicate that the effectiveness of inhibition of inhibitors tested increased with the ionization potential (Pi); the HQ-ZNO2 compound has the highest ionization potential (− 3.313 eV).

Chemical hardness (η) and softness (σ) are important properties to measure the molecular stability and reactivity. The values calculated of (σ) and (η) are also listed in Table 6. The compound HQ-ZNO2 has a good reactivity chemical to the surface of Metal due to the increase of the value of softness (σ = 0.628 eV−1) and the diminution of hardness (η = 1.590 eV).

The fraction of electrons transferred (ΔN) from inhibitor to MS surface was also calculated utilizing a theoretical χFe and ηFe values for MS. The total energy of the best inhibitor HQ-ZNO2 is the lowest among the compounds studied; this result indicates that the HQ-ZNO2 is well adsorbed on the metal surface. The inhibitory performance increases with the increase of the electron donor of the inhibitor on the surface of the metal (∆N). The compound HQ-ZNO2 has a high value of ∆N (1.157 eV) in the order of ∆N (HQ-ZNO2) > ∆N (HQ-ZH) ≈ ∆N (HQ-ZOH).

These results agree with the experimental observations, which imply that HQ-ZNO2 compound has better corrosion performance.

Fukui index analysis

The importance of the highest occupied molecular orbital and the lowest unoccupied molecular orbital in chemical reactions was introduced and explained by Fukui. Since a chemical reaction is nothing other than an exchange of electrons between reagents, we can understand the importance of the Fukui hypothesis, which gives an insight into molecular reactivity.

The electrophilic and nucleophilic chemical reactivity of the atoms for the three quinoline compounds is listed in Table 7, which contains the values of the natural population [(P (N), P (N–1) and P (N + 1)] with the corresponding values of the Fukui functions (\( {\mathrm{f}}_{\mathrm{k}}^{-} \)and \( {\mathrm{f}}_{\mathrm{k}}^{+} \)) of the studied molecules. The C27 atom, which belongs to two 8-hydroxyquinoline moiety, is available for electrophilic attack for all three compounds. The C1, C24, and C28 atoms of compound HQ-ZH possess a high value of the Fukui function; moreover, they are available for nucleophilic attack.

Table 7 Values of the Fukui function considering natural population analysis (NPA) of molecules calculated at the B3LYP/6–31 G (d, p)

The atoms C3, C26, and C28 of compound HQ-ZNO2 possess a high value of the function of Fukui; these atoms are considered as sites available for electrons (nucleophilic attack). The C2, C3, and C27 atoms of compound HQ-ZOH possess a high value of the function of Fukui; these atoms are available for electrophilic attack.

Monte Carlo simulations

Monte Carlo simulations were carried out to simulate the low energy adsorption configuration and to determine the adsorption energies as the inhibitor molecules slowly interacts with Fe surface. This methodology has earlier been adopted by us to understand the strength and mechanism of inhibitor-metal interactions in the literature [50, 51].

As can be seen in Fig. 12(a–c), the three inhibitor molecules (HQ-ZNO2, HQ-ZOH, and HQ-OH) are adsorbed in a parallel orientation to the metal surface to maximize contact. The heteroatoms such as N and O present in the molecules were in close contact with the Fe surface and could serve as the adsorption sites. Although NO2,-group is an electron withdrawing group, the presence of extra O atom in HQ-NO2 could enhance its interaction with Fe surface when compared with other inhibitors investigated. This could result in a higher adsorption energy for HQ-NO2. Figure 11d shows the probability distribution curves for the adsorption energies of the three inhibitors on the Fe surface. It can be seen that HQ-NO2 has a higher negative adsorption energy when compared to HQ-ZH, HQ-ZOH, which suggests a stronger interaction of the inhibitor molecule with the metal surface [52]. In fact, the order of the adsorption energy is HQ-ZNO2˃ HQ-ZOH ˃ HQ-ZH. We conclude from the results obtained that the interaction between HQ-ZNO2 and the steel surface is greater than that of the other two inhibitor molecules studied. This result indicates that is HQ-ZNO2 is expected to inhibit steel corrosion more than HQ-ZH and HQ-ZOH. The results obtained utilizing Monte Carlo simulations are in good agreement with the experimentally determined corrosion inhibition efficiencies of the three molecules investigated.

Fig. 12
figure 12

Model Structures simulating the equilibrium adsorption configuration of (a) HQ-ZH, (b) HQ-ZOH and (c) HQ-ZNO2 on the Fe surface. (d) Probability distribution curves in adsorption energy function for HQ-ZH, HQ-ZOH, and HQ-ZNO2 on the Fe surface

Conclusion

The inhibition effect and adsorption behavior of the quinazolinone derivatives have been investigated utilizing electrochemical studies, SEM surface investigations, UV − vis and quantum chemical calculations. The conclusions of these investigations are as follows:

  • Quinazolinone derivatives acted as efficient corrosion inhibitors for MS in acidic medium.

  • Polarization studies have shown that the studied inhibitors acting as mixed inhibitors.

  • EIS study revealed that values of polarization resistance (Rp) increase in presence of inhibitors due to the adsorption of inhibitors at metal/electrolyte interfaces.

  • The adsorption of the inhibitors on the MS surface obeys the Langmuir adsorption isotherm.

  • The adsorption of quinazoline compounds was investigated by using UV-visible, SEM techniques.

  • DFT and Monte Carlo simulations support the experimental outcomes.