Introduction

The environmental toxicity of organic corrosion inhibitors has prompted the search for green corrosion inhibitors as they are biodegradable and do not contain heavy metals or other toxic compounds. As in addition to being environmentally friendly and ecologically acceptable, plant products are inexpensive, readily available, and renewable. Investigations of corrosion inhibiting abilities of tannins, alkaloids, organic amino acids, and organic dyes of plant origin are of interest [16].

The olive tree (Olea europaea L.) is the most important ever-green tree in Morocco. In the olive tree cultivation, the harvesting of olive fruit and the pruning of olive trees generate an important number and large amounts of by-products such as leaves, twigs, and stems in farms. These solid wastes are a result of pruning or defoliation of olive fruits prior to processing and also accumulating in the olive oil industries [18].

The chemical composition of olive solid waste depends on the year, season, variety, proportion of branches of tree, storage condition, drying procedure, climatic conditions, moisture content, and degree of contamination with soil [28]. However, the phenolic content of olive leaf extracts strongly depends on several factors such as leaf age, degree of ripeness, geographical origin cultivar, phonological stage during sampling [37], and the extraction procedure [17]. Oleuropein is the major phenolic compound of olive leaves [24], and it is easily extracted as part of the phenolic fraction of olive fruits, leaves, and seeds, but it has not been reported in virgin olive oils [38].

By-products of (Olea europaea L.) such as leaves, stems, and roots gather the interest of the scientific community and the industries worldwide. Hence, important scientific and technical efforts have been made to determine the value of this agricultural waste [34]. The chemical compositions of olive leaves are shown in Table 1. The CP, EE, and ash contents of olive leaves have been reported (in order) as 126.9, 22.6, and 63.3 g kg−1 DM by Boudhrioua et al. [8]; 70, 32.1, and 16.2 g kg−1 DM by Garcia et al. [29]; and 100, 56.4, and 120 g kg−1 DM by Molina Alcaide et al. [30]. The leaves are a rich source of protein (5.04–7.61/100 g fresh leaves) and of carbohydrates (37.14–42.58/100 g fresh leaves). The fresh leaves contain variable amounts of total phenols according to the olive leaves variety (1.40–2.40 g caffeic acid/100 g dm) [28]. Olive leaves have the highest oleuropein content, which ranges from 1 to 14 % compared to olive oil (0.005–0.12 %) and OMW (0.87 %) [21], and the oleuropein content of the leaves was 72.63 mg g−1 DM [40]. Recent studies suggest that olive leaf is a significant source of bioactive phenolic compounds compared to olive oil and fruits [11]. Several studies have explored the presence of a high number of phenolic compounds in olive leaves, notably, hydroxytyrosol, rutin, verbascoside, luteolin-7-glucoside, luteolin-40-glucoside, oleuropein, oleuropein aglycone, and ligstroside aglycone [35]. The most important classes of phenolic compounds in olive leaf include phenolic acids, phenolic alcohols, flavonoids, and secoiridoids [39].

Table 1 Chemical composition of olive leaves (g Kg−1)

Steel which used in various industries as structural materials exposure to aggressive environments like concentrated acids, such as hydrochloric acid solution which is widely used in many industries for the pickling, cleaning, descaling, and etching of mild steel [1]. Inhibitors are commonly used to prevent metal dissolution as well as acid consumption and retard the corrosive attack on metallic materials.

Corrosion inhibitors are chemical compounds used in small concentrations in industry to reduce the corrosion rate of metals and alloys in contact with aggressive environment, and therefore, retard the corrosion process and keep its rate to a minimum, and thus prevent economic losses due to metallic corrosion. The mechanism action of inhibitors is of great importance and depends on their formulation as well as on their rational use in various environments. The electronic characteristics of the adsorbate molecules, the solution chemical composition, the nature of metallic surface, the temperature of the reaction, the immersion time, and the electrochemical potential at the metal–solution interface determine the adsorption degree and hence the inhibition efficiency [42].

Corrosion inhibitors’ synthetic chemicals are widely used to protect metals against corrosion, but most of them are not environment friendly due to their toxicity levels, bioaccumulation, and/or biodegradability [3]. Hence, the research of new corrosion inhibitors’ non-toxic, eco-friendly, natural, at low or ‘‘zero’’ environmental impact are desired [20]. Plant extract is a rich source of naturally synthesized chemical compounds, readily available at low cost and eco-friendly, and can be obtained through simple extraction process with low cost as well as biodegradable [15]. The advantages of using plant extracts for steel corrosion control under acidic media are that the inhibitor is readily soluble and becomes their corresponding acid salt which leads to both economic and environmental benefits [27]. Many plant extracts have been used as effective corrosion inhibitors of iron or steel in acidic media such as olive [10]. Many recent researches have adopted this trend and carried out their work on naturally occurring substances. In our laboratory, which is dedicated for corrosion study and the inhibition by olive extracts was studied before [9]. The main reason for the choice of olive leaf extract (OLE), olive stem extract (OSE), and olive root extract (ORE) is that olive leaves, roots, and stems are abundant resources with fast renewal and continual, and is virtually nonpoisonous.

Materials and methods

Samples and solutions

Fresh olive roots, stems, and leaves were collected after harvesting in January 2014 from olive trees of the cultivar picholine (Olea europaea L.) from an olive farm (Oujda). All samples were cleaned with tap water to eliminate ash of mud and washed with double-distilled water, and then oven dried at 40 °C for 4 days until complete dryness. The samples were stored in plastic bags at room temperature until diet supplementation.

Steel and HCl solution

The chemical compositions of the steel used in this experiment are 0.22 % C, 0.79 % Mn, 0.022 % P, 0.030 % S, 0.21 % Si, 0.02 % Ni, 0.030 % Al, and the remainder is iron. Coupons of steel with dimensions (2 cm × 2 cm × 0.3 cm) of exposed surface area 4 cm2 were used for weight loss measurements. For potentiostatic polarization experiments, a cylindrical rod of steel is embedded in araldite with exposed surface area of 0.4 cm2. The electrodes were polished with different grades of emery papers, degreased with acetone, and rinsed in distilled water before they were inserted into the test solution.

The aggressive solution of 1.0 M HCl was prepared by dilution of analytical reagents grade of 37 % HCl with distilled water.

All chemicals used for preparing the test solutions were of analytical grade, and the experiments were carried out at room temperature of 25 ± 1 °C.

Preparation olive root, stem, and leaf extracts

Before the extraction, the samples were grinded using grinder with a sieve of 2.5 mm. A 20 g of each sample was extracted three times with a solvent (methanol/water: 70/30: v/v) for 2 h in a water bath at 60 °C. The refluxed solution of each sample was filtered, and the filter liquor was evaporated to 100 mL of dark brown residue, and then degreased with hexane and extracted with separatory funnel. The extract is filtered, and the collected liquid is used to prepare the desired concentrations by dilution. A stock solution was prepared, by weight, from the collected solid and used to prepare the desired concentrations by dilution. The solid residue was obtained for complete dryness and preserved in desiccators. Concentrations of the stock solution were determined by drying a sample and measuring the weight of the residue relative to the volume of the sample taken. Using dilution, stocks with different extract concentrations were prepared.

Infrared experiments

The milled samples of olive roots, stems, and leaves were characterized by Fourier transform infrared (FTIR) spectroscopy. FTIR spectra were recorded in an AVATAR-FTIR-360 spectrophotometer (Thermo Nicolet Company, USA), which extended from 4000 to 400 cm−1, using the KBr disk technique.

Weight loss measurements

Weight loss tests were conducted under total immersion in 50 ml of non-deaerated HCl solutions without and with three inhibitors tested. The experimental temperature was controlled at 35 °C using a water thermostat (±0.1 C). The parallel steel sheets of 2.0, 2.0, and 0.03 were abraded by a series of emery paper (grade from 600 to 1200) and then washed with distilled water and acetone. After weighing using digital balance with sensitivity of ±0.1 mg, the parallel specimens were totally suspended in a beaker containing test solution using glass hooks and rods. For weight loss measurements, the steel coupons were left hanging in the test solution for 6 h (immersion time) at 308 K before loss weight was recorded. The corrosion rate was calculated, in milligrams per square centimeter per hour [mg (cm2 h−1)−1], on the basis of the apparent surface area. In order to investigate the effects of temperature on the inhibitor performance, some tests were carried out in a temperature range of 313–338 K with 1 h immersion time for the weight loss. In order to get good reproducibility, experiments were carried out in triplicate. The mean weight loss of all parallel steels was obtained, and then corrosion rates (W) and inhibition efficiency (%IE) were calculated [25]. The inhibition efficiency calculations were based on the weight loss measurements at the end of the whole exposure period. The results of the weight loss experiments are the mean of three runs, each with a fresh steel sheet and a fresh acid solution. The percentage inhibition efficiency of the extracts was calculated using Eq. (1):

$${\text{IE}}_{w} \% = 100\, \times \,\left( {\frac{{W_{\text{Corr}} - W_{\text{Corr}}^{ \circ } }}{{W_{\text{Corr}} }}} \right),$$
(1)

where W corr and \(W_{\text{corr}}^{ \circ }\) are the corrosion rates of the mild steel without and with different sample extracts, respectively.

Electrochemical measurements

The electrochemical study was carried out using a potentiostat PGZ100 piloted by Volta master software. This potentiostat is connected to a cell with three electrodes with a platinum counter electrode (CE), a saturated calomel electrode (SCE) coupled to a fine lugging capillary as the reference electrode (RE), and a working electrode (WE). The surface area exposed to the electrolyte is 1 cm2.

Potentiodynamic polarization curves were plotted at a polarization scan rate of 1 mV s−1. Before all experiments, the potential was stabilized at free potential during 30 min. The polarization curves are obtained from −800 mV to −200 mV at 308 K. The solution test has been achieved after deaerated by bubbling nitrogen. Gas bubbling is maintained prior and through the experiments.

The principle of the realized electrochemical sensor is based on the measure of the impedance of an electrochemical cell by the technique of spectroscopy of impedance. This technique allows controlling the process of charge transfer in the interface electrode/electrolyte. Indeed, a potential imposed with a sinusoidal disturbance of low amplitude, between the reference electrode and the working electrode, allows the measure of a current, of the same shape, generated between the working electrode and the auxiliary electrode.

The data in Tafel region have been processed for evaluating the corrosion kinetic parameters by plotting the polarization curves. In a large domain of the potential, the linear Tafel segments of the cathodic curves were extrapolated to the corresponding corrosion potentials to obtain the corrosion current values. The inhibition efficiency (IEp) was evaluated using the relationship Eq. (2):

$${\text{IE}}_{\text{p}} \% \; = \;100\; \times \;\left( {\frac{{I_{\text{Corr}}^{{^{ \circ } }} - I_{\text{Corr}} }}{{I_{\text{Corr}}^{{^{ \circ } }} }}} \right),$$
(2)

where \(I_{\text{Corr}}^{{^{ \circ } }}\) and Icorr are the corrosion current density values without and with inhibitors, respectively.

To determine the impedance parameters of the C38 steel specimens in acidic solution, the measured impedance data were analyzed using Z view program based upon an electric equivalent circuit [14]. The charge transfer resistance (R t) values were calculated from the difference in impedance at low and high frequencies. The double-layer capacitance (C dl) was obtained at the frequency f max at which the imaginary component of the impedance is maximal (Z i max) using Eq. (3):

$$C_{\text{dl}} \; = \; 1 / ( 2\pi .f_{ \hbox{max} } .R_{\text{t}} ).$$
(3)

The inhibition efficiency of the inhibitors has been determined using Eq. (4):

$${\text{IE}}_{\text{imp}} \% \; = \;100\; \times \;\left( {\frac{{R_{\text{inh}} - R_{\text{inh}}^{ \circ } }}{{R_{\text{inh}} }}} \right),$$
(4)

where R inh and \(R_{\text{inh}}^{ \circ }\) are the charge transfer resistance values in the absence and in the presence of the inhibitors, respectively.

Results and discussions

Weight loss measurements

To study the corrosion inhibition of steel in HCl using olive extracts, weight loss method of monitoring corrosion rate and inhibition efficiency were used due to its simple application and high reliability [31].

The data in Table 2 represent the results of the corrosion rate (W) and the inhibition efficiency percentage (%IE w ) of mild steel coupons in 1 M HCl at 308 K after 6 h of immersion period in the presence of different concentrations from 1.0 × 10−5 mL L−1 to 1.4 × 10−5 mL L−1 of olive roots, stems, and leaves, obtained from weight loss experiments.

Table 2 Gravimetric results of steel in 1 M HCl with and without addition of the different olive extracts at various concentrations from 1.0 × 10−5 to 1.4 × 10−5 at 308 K

Those data reveal that the rate of carbon steel corrosion is greatly reduced upon the addition of the selected three inhibitors of olive sample extracts (roots, stems, and leaves) and decreases with the inhibitor concentration due to the fact that the adsorption coverage increases, which shields the steel surface efficiently from the acid solution. In acidic media, the corrosion rate decreases sharply with an increase in olive samples concentrations.

At any given inhibitor concentration, the corrosion rate follows the following order: w (olive root extract) < w (olive stem extract) < w (olive leaf extract), which indicates that olive root exhibits the best inhibitive performance among these additives.

Clearly, the inhibition efficiency increases with an increase in the inhibitor concentration. It reaches 89.24, 88.84, and 85.13 % for 1.4 x 10−5 mL L−1 of the added extracts olive root, stems, and leaves, respectively. The same result is obtained from the olive leaves. It reaches 91 % at 900 ppm of the added extract in 1 M HCl solution. The corrosion inhibition enhances with the inhibitor concentration. This behavior is due to the fact that the adsorption amount and coverage of inhibitor on steel surface increases with the inhibitor concentration. The inhibitive action of olive extracts acts as a barrier between the steel surface and the aggressive solution, leading to a decrease in the corrosion rate.

It could be concluded that the inhibition efficiency of inhibitors follows the general order: %IE w (olive root) > %IE w (olive stem) > %IE w (olive leaf). This result implies that the crude extract of olive root exhibits better inhibition performance than its major components. It was suggested that the oleuropein and hydroxytyrosol may play the major role in the inhibition process. The phenolic compounds get adsorbed onto the steel surface through the lone pairs of electrons of the oxygen atoms forming a covering film. Inspection of the phenolic structures reveals that the oxygen atoms almost surround the aromatic rings of the phenolic. This arrangement of the oxygen atoms may lead to the conclusion that the phenolic compound is forced to be adsorbed horizontally onto the steel surface.

Polarization studies

Potentiodynamic polarization curves

The inhibition of olive extracts on mild steel specimens immersed in 1 M HCl was further studied by measuring the change in the cathodic and anodic behaviors of the specimens which correspond to hydrogen reduction and metal oxidation.

The cathodic and anodic potentiodynamic polarization curves of C-steel in 1.0 M HCl solution without and with different concentrations of samples of olive extracts were recorded at a scanning rate of 1 mV s−1 at 35 °C (immersion time is 30 h), and are represented in Fig. 1.

Fig. 1
figure 1

Typical polarization curves of steel in 1 M HCl for various concentrations of olive roots (a), stems (b), and leaves at 308 K (c)

The figure reveals that the polarization curves are shifted toward more negative potentials and less current density upon addition of olive extracts. This phenomenon corresponds to a decrease in the corrosion rate which can be explained by the shift of the cathodic and anodic Tafel slopes. It is also noticed that there was a clear shift for both anodic and cathodic parts for the sweeps at the various test concentrations. The shift range in the cathodic Tafel slopes of the tests is more noticeable than the shift range in the anodic Tafel slopes. This may indicate that the decrease of the oxidation rate of the metal with higher extract concentrations corresponds to the relative drop in the corrosion rate. The extract adsorption on the metal surface is causing the decrease in the metal dissolution at a relatively more noticeable higher rate while affecting the hydrogen reduction to a lesser extent. The shifts in both anodic and cathodic curves indicate that the olive extract is a mixed inhibitor with significant cathodic efficiency.

The potentiodynamic polarization parameters including corrosion current densities (I corr), corrosion potential (E corr), cathodic Tafel slope (β c), anodic Tafel slope (β a), and inhibition efficiency of polarization (IEPol) are presented in Table 3.

Table 3 Polarization parameters for steel in 1 M HCl acid at different olive extracts tested at 308 K at various concentrations

Inspection of the data of the table revealed that the corrosion potential shifts to more negative values with increased concentrations of olive extract. Moreover, the corrosion current density decreases markedly on addition of the extract. I corr decreases considerably in the presence of inhibitors in acid and decreases with the increase of inhibitor concentration. The inhibition efficiency increases with the increasing extract concentrations, reaching up to 84.76, 77.34, and 89.17 % in olive roots, stems, and leaves, respectively.

This result suggests that the presence of olive root extract and olive stem extract affects the anodic dissolution of steel low than the cathodic reduction of hydrogen ions. Therefore, it could be concluded that the molecules of both extracts get adsorbed onto both anodic and cathodic sites of the steel surface. This behavior indicates that the extracts of olive root and stem act as a mixed inhibitor but slightly cathodic which for the olive leaf extract acts as inhibitor mixed. The same results were also observed by previous studies [15].

Electrochemical impedance spectroscopy (EIS)

Electrochemical impedance spectroscopy (EIS) was used to obtain information about the kinetics and mechanism of the mild steel corrosion inhibition by the olive extracts at 35 °C. Figure 2 shows the Nyquist diagrams for steel in 1 M HCl at 35 °C with and without olive extracts. These diagrams have similar shape throughout all tested conditions, indicating that there is almost no change in the corrosion mechanism which occurs due to the inhibitor addition. The impedance spectra exhibit one single capacitive loop, which indicates that the corrosion of steel is mainly controlled by the charge transfer process [4]. In HCl acid, with respect to blank solution, the shape is maintained throughout all tested concentrations, indicating that there is almost no change in the corrosion mechanism which occurs regardless of the inhibitor addition [22]. It is noted that the capacitive loop in acid is not a perfect semicircle which can be attributed to the frequency dispersion effect as a result of the roughness and inhomogeneous of electrode surface [23].

Fig. 2
figure 2

Nyquist diagrams for steel electrode with and without olive roots, stems, and leaves after 30 min of immersion in 1 M HCl at various concentrations

Figure 2 shows the Nyquist diagrams for steel electrode with and without olive roots, stems, and leaves after 30 min of immersion in 1 M HCl at various concentrations.

Furthermore, the diameter of the capacitive loop in the presence of olive extracts is larger than that in blank solution, and the diameter of Nyquist plots increased upon increasing the concentration of olive extracts which resulted in strengthening the inhibitive film. This indicates that the impedance of inhibited substrate increases with the inhibitor concentration and leads to good inhibitive performance. The kinetic parameters derived from the Nyquist plots and the percentages of inhibition efficiency are given in Table 3 As the concentration of inhibitor increased, the capacitance (C dI) decreased and polarizing resistance (R ct) increased.

The results of the inhibition efficiencies obtained from weight loss measurements (%IE w ), potentiodynamic polarization curves (%IEpol), and EIS (%IEimp) are in good reasonably agreement.

The EIS results of these capacitive loops are simulated by the equivalent circuit shown in Fig. 3 to pure electric models that could verify or rule out mechanistic models and enable the calculation of numerical values corresponding to the physical and/or chemical properties of the electrochemical system under investigation [33].

Fig. 3
figure 3

Equivalent circuit used to fit the impedance spectra of olive extracts (ORE, OSE, and OLE)

The circuit employed allows the identification of both solution resistance (R s) and charge transfer resistance (R t). It is worth mentioning that the double-layer capacitance (C dl) value is affected by imperfections of the surface. This effect is simulated via a constant phase element (CPE) [7]. The CPE is composed of a component Q dl and a coefficient a. The parameter ‘a’ quantifies different physical phenomena like surface in homogeneousness resulting from surface roughness, inhibitor adsorption, porous layer formation, etc. Therefore, the capacitance is deduced from Eq. (5) [19]:

$$C_{\text{dl}} \; = \;Q_{\text{dl}} \; \times \;\left( {2\pi f_{\hbox{max} } } \right)^{a\; - \;1} ,$$
(5)

where f max represents the frequency at which imaginary value reaches a maximum on the Nyquist plot. The electrochemical parameters of R t, C dl, and IEimp are calculated by ZSimpWin software and presented in Table 4.

Table 4 Impedance parameters of steel in acid at various samples of olive extracts

Clearly, R t increases prominently, while C dl reduces with the concentration of olive extracts in acid. A large charge transfer resistance is associated with a slower corroding system. In contrast, better protection provided by an inhibitor can be associated with a decrease in capacitance of the metal according to Helmholtz model [36].

Effect of the temperature

Weight loss, corrosion rates, and inhibition efficiency

The compositions of the medium and its temperature are essential parameters affecting the corrosion rate of metal and modifie the adsorption of inhibitor on electrode surface. The effect of the absence and presence of olive samples tested at concentration 1.4 × 10−5 mL L−1 during 1 h of immersion on the corrosion of steel in 1 M HCl solution was studied using weight loss at different temperatures from 313 to 338 K. The inhibition efficiency IEw (%) is calculated at various concentrations using Eq. (6). The corresponding data are shown in Table 5.

Table 5 Effect of temperature on the corrosion rate of steel at various samples of olive extracts at 1 h at concentration 1.4 × 10−5 mL L−1
$${\text{IE}}_{w} \% \; = \;100\; \times \;\left( {\frac{{W_{\text{Corr}} \; - \;W_{\text{Corr}}^{ \circ } }}{{W_{\text{Corr}} }}} \right),$$
(6)

where both W corr and \(W_{\text{corr}}^{ \circ }\) are the corrosion rates of steel in 1 M HCl in the absence and presence of olive extracts, respectively, at different temperatures from 313 to 338 K.

The inhibition efficiency of the olive extract decreases markedly with increasing temperature. This can be attributed that the higher temperatures might cause desorption of inhibitor molecule from metal surface. This result supports the idea that the adsorption of components’ olive extracts onto the steel surface is physical in nature. Thus, as the temperature increases, the number of adsorbed molecules decreases, leading to a decrease in the inhibition efficiency.

Thermodynamic parameters

Activation thermodynamic parameters of the corrosion reaction at various temperatures (313–338 K) in the presence and absence of olive extracts at 1 h of immersion, such as the energy E a, the entropy \(\Delta S_{\text{ads}}^{^\circ }\), and the enthalpy \(\Delta H_{\text{ads}}^{^\circ }\) of activation, were calculated using Arrhenius Eqs. (79) and its alternative formulation called transition state (Eqs. 810).

$$W\; = \;K\exp \,\left( { - \frac{{E_{\text{a}} }}{RT}} \right)$$
(7)
$$\log \,(w) = - \frac{{E_{\text{a}} }}{RT}\; + \;k$$
(8)
$$W = \frac{RT}{Nh}\exp \left( {\frac{{\Delta S_{\text{a}}^{o} }}{R}} \right)\exp \left( { - \frac{{\Delta H_{\text{a}}^{o} }}{RT}} \right)$$
(9)
$$\log (W/T) = \left[ {\left( {\log \left( \frac{R}{Nh} \right) + \frac{{\Delta S_{\text{a}}^{o} }}{R}} \right)} \right] - \frac{{\Delta H_{\text{a}}^{o} }}{RT} ,$$
(10)

where T is the absolute temperature, K is a constant, E a is the apparent activation corrosion energy, R is the universal gas constant, A is the Arrhenius pre-exponential factor, h is the Plank’s constant, N is the Avogadro’s number, \(\Delta S_{\text{ads}}^{^\circ }\) is the entropy of activation, and \(\Delta H_{\text{ads}}^{^\circ }\) is the enthalpy of activation.

The inhibition efficiency decreases with the increase in temperature, and the activation energy increases with increase in inhibitor concentrations. This behavior is an indication of the formation of an adsorption film of physical electrostatic nature [32].

The obtained results suggest that olive leaf extract inhibits the corrosion reaction by increasing its activation energy. This could be done by adsorption onto the steel surface, making a barrier to mass and charge transfer. However, such types of inhibitors perform good inhibition at ordinary temperature, with considerable loss in inhibition efficiency at elevated temperatures [15].

The linear regressions between log W and 1000/T were calculated, and the parameters are given in Table 6. Figure 4 shows the Arrhenius straight lines of log W versus 1000/T for the blank and different inhibitors which gave linear regression coefficients (r) very close to 1, which indicates that the linear relationship between log W and 1000/T is good.

Table 6 Activation parameters of the dissolution of mild steel in 1.0 M HCl in the absence and presence of different concentrations of olive pomace at various temperatures (303–333 K)
Fig. 4
figure 4

Typical Arrhenius plots for log W versus 1000/T (a) and log (W/T) versus 1/T for steel in 1 M HCl at different concentrations of olive extracts

Kinetic parameter of apparent activation energy E a is important to study the inhibitive mechanism. Compared with uninhibited solution, the increase of E a in inhibited solution may be interpreted as a physical adsorption [5].

Table 6 reveals that the value of E a in the presence of any inhibitor is higher than that in the uninhibited acid solution, which indicates that the adsorption of inhibitor is mainly physical adsorption, while the weak chemical bonding between the inhibitor molecules and the steel surface would also occur [26].

Fourier transforms infrared (FTIR) spectroscopy of extracts

From the FTIR studies (Fig. 5), we can conclude the following:

Fig. 5
figure 5

Fourier transforms infrared (FTIR) spectroscopy of olive root (a), stem (b), and leaf extract (c)

  • The strong absorption bands at 3460, 3555, and 3500 cm−1 for the olive roots, stems, and leaves, respectively, are attributed to N–H or O–H (Phenol) stretching mode.

  • The absorption bands at 2900 cm−1 in three samples are related to C–H stretching vibration (alkane C–H band stretching mode) which appears at 1706 cm−1 to C=O.

  • Besides these, there is an absorption band at 1072 cm−1, which can be assigned to the C–N or C–O stretching vibration (the stretching mode of C–O alcohol).

  • Finally, the absorption bands below 1000 cm−1 correspond to aliphatic and aromatic C–H group.

  • The olive extracts (roots, stems, and leaves) contain oxygen and nitrogen atoms in functional groups (O–H, N–H, C=C, C=O, C=N, C–N, C–O) and aromatic ring, which meets the general consideration of typical corrosion inhibitors.

Explanation for inhibitions

The steel surface charges positive in acid solution so it is difficult for these protonated compounds to approach the positively charged steel surface due to the electrostatic repulsion. Olive sample extracts are composed of numerous naturally occurring organic compounds containing many O and N atoms in functional groups (O–H, C=O, C–O, N–H) and O-heterocyclic rings, and they act as reaction centers leading to the formation of film on the surface of the alloy. These compounds could be protonated in the acid solution; accordingly, the inhibitive action could be attributed to the adsorption of its components on the steel surface [27].

The corrosion inhibition property of plant extract is normally due to the presence in their composition of complex organic species such as tannins, alkaloids and nitrogen bases, carbohydrates, amino acids, and proteins as well as hydrolysis products. These organic compounds contain polar functions with N, S, and O atoms as well as conjugated double bonds or aromatic rings in their molecular structures, which are the major adsorption centers [13]. Also, the anticorrosion activity is attributed to the presence of heterocyclic constituents such as alkaloids, flavonoids, tannins, cellulose, and others which form an adsorbed film on the metal surface [2]. The plant extracts such as olive roots, stems, and leaves are a mixture of various components, which results in the complex inhibitive mechanism. It is rather difficult to determine what components present in plant extracts contribute to inhibit corrosion [27]. Those properties of olive extracts are mostly attributed to their polyphenols which are classified as secondary metabolites having redox potential, which act as reducing agents, hydrogen donators, metal chelators, and singlet oxygen quenchers [41]. Synergistic functions of various molecules in olive tree extracts such as roots, stems, and leaves of olive compared to the action of one or two main components of the extract appear questionable. However, it is possible that the activity of the major components is modulated by other minor compounds. In fact, the synergistic effects of various major and minor components present in raw plant extracts should be considered to account for their inhibitory activity of the phenomenon of corrosion of metals in acidic media such as HCl [12]. These effects of olive leaf extracts have been attributed to synergistic phenomena among olive biophenols [6].

Conclusions

Based on the results obtained from the weight loss methods and electrochemical measurements, the following conclusions are drawn:

  1. 1.

    Olive extracts (roots, stems, and leaves) act as good corrosion inhibitors for C-steel in 1 M HCl solution.

  2. 2.

    Inhibition efficiency (%E) increases with increasing inhibitor concentration, and the maximum  %IE of 1.4 × 10−5 mL L−1 of olive extracts are higher than 89.24, 88.84, and 89.83 % at 35 °C, in olive roots, stems, and leaves, respectively.

  3. 3.

    The inhibition action of the extract was attributed to the physical adsorption of its compounds onto the steel surface.

  4. 4.

    The extracts act as mixed inhibitors with significant cathodic efficiency. The inhibition efficiency values obtained from weight loss, polarization curves, and EIS are in good agreement.

  5. 5.

    The inhibition efficiency decreases with increasing temperature.

  6. 6.

    Test results obtained from various corrosion techniques point out that the corrosion rate of mild steel increases with high temperatures, which indicates that the adsorption of the extract on the metal surface is of physisorption type.

  7. 7.

    The presence of extracts increases the activation energy of the corrosion process and decreases the charge density in the transpassive region.

  8. 8.

    The introduction of olive roots, stems, and leaves into HCl solution results in the formation of a film on the steel surface, which effectively protects steel from corrosion

  9. 9.

    However, neither the molecular mechanism of the anti-corrosive nor the specific compound or mixture of compounds responsible for this bioactivity is well known.