Background

Mild steel (MS) is a class of strong and tough steel that contains a low quantity of carbon. MS has relatively low tensile strength, but it is cheap and malleable, and its surface hardness can be increased through carburizing. It is the most important engineering material particularly for structural, instrumental, industrial and automobile applications. But it is highly susceptible to corrosion especially in acidic media [1]. Corrosion problem occurs in many industries, and can cause disastrous damage to metal and alloy structures causing economic consequences in terms of repair, replacement and product losses. Hence, various corrosion protection technologies have been employed, among them; the use of inhibitors is one of the practical methods for preventing corrosion of MS especially in acid media [2]. A wide variety of corrosion inhibitors ranging from rare earth elements [3] to organic compounds [47] have been used. The corrosion inhibition property of inhibitors depends on their molecular structures, planarity and the lone pairs of electrons present on the hetero atoms, which determine the adsorption of these molecules on the metallic surfaces. Corrosion inhibitors block the active sites and enhance the adsorption process, thus decreasing the rate of dissolution and extending the life span of the equipment [8, 9].

Although, several organic compounds have been used as inhibitors in different corrosive environment, choosing an appropriate inhibitor for specific environment and metal is of great importance. Generally, oxygen, nitrogen and sulphur containing heterocyclic organic compounds with multiple bonds have a tendency to resist corrosion [10, 11]. Compounds rich in heteroatoms can be regarded as environmental friendly inhibitors because of their characteristic strong chemical activity and low toxicity [12]. The adsorption characteristics of organic molecules are also affected by sizes, electron density at the donor atoms and orbital character of donating electrons [1316]. Organic compounds containing hetero atoms in the functional groups, pi-electron in triple or conjugated double bonds and presence of aromatic rings in their structure are the major adsorption centres and are usually good inhibitors [17]. Several heterocyclic compounds such as methylthiophenyl derivatives [18], isoxazolium cationic Schiff base compounds [19], quinoline derivatives [20], sulphonamide compounds [21], thiadiazoles derivatives [22], imidazole derivatives [23], fluoroquinolones [24], pyrazole derivatives [25], pyridazine derivatives [26] and pyridine derivatives [27] have been reported as anticorrosion substances in various corrosive environments.

In the present investigation attempts have been made to study the inhibitive effect of the four newly synthesized nicotinamide derivatives such as N-((1H-pyrrol-2-yl)methylene)nicotinamide (PMN), N-((methyl(phenyl)amino)methylene)nicotinamide (MMN), N-nicotinoylbenzimidothioic acid (NBT) and N-(4-(methylthio)benzylidene)nicotinamide (MBN), on the corrosion of MS in 0.5 M HCl using mass loss and electrochemical techniques. The experimental results were discussed with various activation and adsorption thermodynamic parameters. The passive film formed on the metal surface was characterized by FTIR, SEM and EDX. Further, the inhibition performances of the four derivatives have been compared and discussed.

Experimental

Materials

MS specimen used in the present study having the following chemical compositions (in wt%): C 0.051; Mn 0.179; Si 0.006; P 0.005; S 0.023; Cr 0.051; Ni 0.05; Mo 0.013; Ti 0.004; Al 0.103; Cu 0.050; Sn 0.004; B 0.00105; Co 0.017; Nb 0.012; Pb 0.001 and the remainder iron. For all experiments, square type MS specimens of dimension 2 cm × 2 cm × 0.1 cm were used. The specimens were mechanically well polished with different grades SiC (200–600) emery papers, degreased with benzene, washed with doubly distilled water and finally dried. All solvents and chemicals used were of AR grade, and used as such. Doubly distilled water was used in the preparation of the various concentrations of test solutions.

Synthesis of inhibitors

The nicotinamide derivatives, PMN, MMN, NBT and MBN have been synthesized by the literature method [28]. PMN was synthesized by dissolving 0.61 g (5 mmol) of nicotinamide (C6H6N2O, Mol. Wt. 122.12) in 15 mL of ethanol in a round bottom flask. To this 0.47 g (5 mmol) of pyrrole-2-carboxaldehyde (C5H5NO, Mol. Wt. 95.10) in 15 mL ethanol was mixed and refluxed for 6 h at 60 °C temperature in the presence of few drops glacial acetic acid, and then the solution was concentrated using rotor vaporizer and kept for dry in vacuum. MMN was synthesized by dissolving 0.61 g (5 mmol) of nicotinamide in 15 mL of ethanol in a round bottom flask. To this 0.62 mL (5 mmol) of N-methylformanilide (C8H9NO, Mol. Wt. 135.16) in 15 mL ethanol was mixed and refluxed for 6 h at 60 °C temperature in the presence of few drops glacial acetic acid, and then the solution was concentrated using rotor vaporizer and kept for dry in vacuum.

NBT was synthesized by dissolving 0.61 g (5 mmol) of nicotinamide in 15 mL of ethanol in a round bottom flask. To this 0.58 mL (5 mmol) of thiobenzoic acid (C7H6OS, Mol. Wt. 138.19) dissolved in 15 mL of ethanol was added and refluxed for 6 h with stirring at 60 °C temperature in the presence of few drops of glacial acetic acid. Then the solution was concentrated using rotor vaporizer and kept for dry in vacuum and the product obtained was collected. MBN was synthesized by dissolving 0.61 g (5 mmol) of nicotinamide in 15 mL of ethanol in a round bottom flask. To this a 0.66 mL (5 mmol) of the 4-(methylthio)benzaldehyde (C8H8OS, Mol. Wt. 152.21) dissolved in 15 mL of ethanol was added and refluxed for 6 h with stirring at 60 °C temperature in presence of glacial acetic acid. Then the solution was concentrated using rotor vaporizer and kept for dry in vacuum and the product obtained was collected. The synthetic schemes of PMN, MMN, NBT and MBN are shown in Fig. 1.

Fig. 1
figure 1

Synthetic scheme of PMN, MMN, NBT and MBN

The Chemical structures of the compounds are characterized by FTIR, 1H-NMR and Mass spectral studies. PMN (C11H9N3O, Mol. Wt. 199.21): Yield: 89 %, Melting Range (M. R, °C): 98–102. FTIR (KBr, cm−1): 1,457 (NH), 1,645 (N=C), 1,726 (C=O). 1H-NMR (400.15 MHz, DMSO-d6) δ ppm: 7.22–7.20 (t, J = 4.0 Hz, 1H), 7.50–7.47 (q, 1H), 7.63 (s, 1H), 7.90–7.89 (t, J = 4.2 Hz, 1H), 7.96–7.95 (d, J = 4.8 Hz, 2H), 8.70–8.68 (t, J = 3.8 Hz, 1H), 9.046–9.041 (d, J = 2.0 Hz, 1H), 10.41 (s, 1H). MS, m/z: 200 (M+1). Elemental analyses found (calculated) for C11H9N3O (%): C, 66.29 (66.32): H, 4.50 (4.55): N, 20.96 (21.09), O, 7.98 (8.03). 1H-NMR spectrum of PMN is shown in Fig. 2a.

Fig. 2
figure 2

1H-NMR spectrum of a PMN, b MMN, c NBT and d MBN

MMN (C14H13N3O, Mol. Wt. 239.27): Yield: 79 %, Melting Range (M. R, °C): 106–108. FTIR (KBr, cm−1): 1,630 (N=C), 1,710 (C=O). 1H-NMR (400.15 MHz, DMSO-d6) δ ppm: 3.68 (s, 3H), 7.50–7.47 (q, 1H), 7.63 (s, 1H), 8.20–8.19 (d, J = 1.8 Hz, 3H), 8.22–8.20 (t, J = 4.0 Hz, 2H), 8.70–8.68 (q, 2H), 9.046–9.041 (d, J = 2.0 Hz, 1H). MS, m/z: 240 (M+1). Elemental analyses found (calculated) for C14H13N3O (%): C, 70.19 (70.28): H, 5.41 (5.48): N, 17.48 (17.56), O, 6.57 (6.69). 1H-NMR spectrum of MMN is shown in Fig. 2b.

NBT (C13H10N2OS, Mol. Wt. 242.30): Yield: 83 %, Melting Range (M. R, °C): 82–84. FTIR (KBr, cm−1): 723 (C–S), 1,643 (N=C), 1,726 (C=O). 1H-NMR (400.15 MHz, DMSO-d6) δ ppm: 1.50 (s, 1H), 7.50–7.47 (q, 1H), 7.63 (s, 1H), 8.20–8.19 (d, J = 1.8 Hz, 3H), 8.22–8.20 (t, J = 4.2 Hz, 2H), 8.70–8.68 (q, 1H), 9.046–9.041 (d, J = 2.0 Hz, 1H). MS, m/z: 243 (M+1). Elemental analyses found (calculated) for C13H10N2OS (%): C, 64.38 (64.44): H, 4.07 (4.16): N, 11.44 (11.56), O, 6.58 (6.60), S, 13.17 (13.23). 1H-NMR spectrum of NBT is shown in Fig. 2c.

MBN (C14H12N2OS, Mol. Wt. 256.32): Yield: 85 %, Melting Range (M. R, °C): 90–94. FTIR (KBr, cm−1): 667 (C–S), 1,587 (N=C), 1,697 (C=O). 1H-NMR (400.15 MHz, DMSO-d6) δ ppm: 2.19 (s, 3H), 7.42–7.39 (m, 2H), 7.50–7.47 (q, 1H), 7.63 (s, 1H), 7.80–7.78 (m, 2H), 8.70–8.68 (q, 2H), 9.046–9.041 (d, J = 2.0 Hz, 1H). MS, m/z: 257 (M+1). Elemental analyses found (calculated) for C14H12N2OS (%): C, 65.54 (65.60): H, 4.68 (4.72): N, 10.89 (10.93), O, 6.19 (6.24), S, 12.47 (12.51). 1H-NMR spectrum of MBN is shown in Fig. 2d.

Methods

Mass loss measurements

Mass loss measurements were performed by weighing cleaned and dried MS specimens before and after immersion in 0.5 M HCl solutions from 1 to 5 h in the absence and presence of various concentrations of PMN, MMN, NBT and MBN at different temperatures (30–60 °C). Triplicate experiments were performed in each case and the mean value of the mass loss was noted. Corrosion rate (CR) in mg cm−2 h−1 and inhibition efficiency IE (%) were calculated using the following equations:

C R = Δ M S t
(1)

where ΔM is the mass loss, S is the surface area of the specimen and t is the immersion time.

IE % = ( C R ) a - ( C R ) p ( C R ) a × 100
(2)

where (CR)a and (CR)p are the corrosion rates in the absence and presence of inhibitor, respectively.

Potentiodynamic polarization measurements

The potentiodynamic polarization studies were carried out with MS specimen as working electrode in 0.5 M HCl solutions with different inhibitor’s concentrations (200–500 ppm) with an exposed area of 1 cm2 and this working area was remained precisely fixed throughout the experiment. A conventional three electrode cell consisting of MS as working electrode, platinum foil as counter electrode and saturated calomel electrode (SCE) as reference electrode was used. Potentiodynamic polarization studies were carried out using CH-instrument (model CHI660D). Before each Tafel experiment, the MS electrode was allowed to corrode freely and its open circuit potential (OCP) was recorded as a function of time up to 30 min. After this time, a steady state OCP corresponding to the corrosion potential (Ecorr) of the working electrode was obtained. The IE (%) was calculated from corrosion currents determined from the Tafel extrapolation plot method using the experimental relation:

IE ( % ) = ( I corr ) a - ( I corr ) p ( I corr ) a × 100
(3)

where (Icorr)a and (Icorr)p are the corrosion current density (µA cm−2) in the absence and presence of the inhibitor, respectively.

Electrochemical impedance spectroscopy (EIS)

Electrochemical impedance spectroscopy measurements were carried out using the same CH-instrument. The EIS data were taken in the frequency range 10–0.05 kHz. The double layer capacitance (Cdl) and the polarization resistance (Rp) were determined from Nyquist plots [29]. The percentage inhibition efficiency, IE (%) was calculated from Rp values using the following expression:

IE ( % ) = 1 1 ( R p ) a ( R p ) a - 1 1 ( R p ) p ( R p ) p 1 1 ( R p ) a ( R p ) a × 100
(4)

where (Rp)a and (Rp)p are polarization resistances in the absence and presence of inhibitor, respectively.

FTIR, EDX and SEM studies

The MS specimens were immersed in 0.5 M HCl in the presence of inhibitors (500 ppm) for a period of 1 h. Then the specimens were taken out and dried. The surface adhered film was scratched carefully and its FTIR spectra were recorded using a Jasco FTIR 4100 double beam spectrophotometer. The surface feature of the MS specimens in the absence and presence of inhibitors was studied by energy dispersive X-ray spectroscopy (EDX) and scanning electron microscope (model JSM-5800).

Characterization of inhibitors

Melting range was determined by Veego Melting Point VMP III apparatus. FTIR spectra were recorded using a Jasco FTIR 4100 double beam spectrophotometer. 1H-NMR spectra were recorded on Bruker DRX-500 spectrometer at 400 MHz using DMSO-d6 as solvent and TMS as an internal standard. Mass spectral data were obtained by LC/MSD Trap XCT. Elemental analyses were recorded on VarioMICRO superuser V1.3.2 Elementar.

Results and discussion

Mass loss studies

The CR and IE (%) in the absence and presence of various concentrations of PMN, MMN, NBT and MBN in 0.5 M HCl solution and at different temperatures (30–60 °C) are presented in Table 1. The mass loss was found to be decreased and IE (%) observed to be increased with increase in concentration of nicotinamide derivatives. The studied inhibitors were found to attain the maximum inhibition efficiency at 500 ppm. Further increase in concentration (beyond 500 ppm) did not cause any remarkable change in the inhibition efficiency. This conclusion is also supported by electrochemical studies. There is no appreciable increase in the inhibition efficiency after 1 h of immersion time, this is due to desorption of the inhibitor molecules from the metal surface with increasing immersion time and instability of the inhibitor film on the metal surface [30, 31]. The IE (%) of nicotinamide derivatives follows the order: MBN > NBT > MMN > PMN. The inhibition efficiency obtained from weight loss measurements is lower than that for electrochemical experiments, this phenomenon attributed to the fact that the weight loss experiment gives average corrosion rates whereas the electrochemical experiments give instantaneous corrosion rates.

Table 1 CR and IE (%) obtained from mass loss measurements of MS in 0.5 M HCl solution containing various concentrations of PMN, MMN, NBT and MBN at different temperatures

Effect of temperature

The effect of temperature on CR and IE (%) was studied in 0.5 M HCl in the temperature range of 30–60 °C in the absence and presence of different concentrations of inhibitors (Table 1). The inhibition efficiencies were found to decrease with increasing temperature from 30 to 60 °C.

This may be explained with desorption of adsorbed inhibitor molecules on the MS surface. This proves that the inhibition occurs through the adsorption of the inhibitors on the metal surface, and desorption is aided by increasing temperature. The activation parameters for the corrosion process were calculated from the Arrhenius type plot according to the following equation:

C R = k exp - E a / R T
(5)

where Ea is the activation energy, k is the frequency factor, T is the absolute temperature and R is the universal gas constant. The values of Ea for MS in 0.5 M HCl without and with various concentrations of inhibitors were obtained from the slope of the plot of log CR versus 1/T (Fig. 3) and are shown in Table 2. It was found that Ea values for inhibited systems are higher than those for the uninhibited systems (Table 2). This increase in the activation energy decreases the corrosion rate of metal [32]. With increasing temperature there is an appreciable decrease in the adsorption of the inhibitors on the metal surface and a corresponding rise in the corrosion rate occurred.

Fig. 3
figure 3

Plot of log CR versus 1/T for a PMN, b MMN, c NBT and d MBN

Table 2 Values of activation parameters for MS in 0.5 M HCl medium in the absence and presence of various concentrations of PMN, MMN, NBT and MBN

An alternative Arrhenius plots of log CR/T versus 1/T (Fig. 4) for MS dissolution in 0.5 M HCl medium in the absence and presence of different concentrations of PMN, MMN, NBT and MBN were used to calculate the values of activation thermodynamic parameters such as enthalpy of activation (∆Ha) and entropy of activation (∆Sa) using the relation (6),

C R = R T N h exp Δ S a R exp - Δ H a R T
(6)

where R is the universal gas constant, T is the absolute temperature, N is the Avogadro’s number, h is Planks constant. The values of ∆Ha and ∆Sa were obtained from the slope and intercept of the above plot, and presented in Table 2. The obtained ∆Ha values are in good agreement with the calculated ∆Ha from the equation, Δ H a = E a - R T .

Fig. 4
figure 4

Alternative Arrhenius plots for MS dissolution in 0.5 M HCl medium in the absence and presence of a PMN, b MMN, c NBT and d MBN

The positive values of enthalpy of activation in the absence and presence of inhibitors indicate an endothermic nature of MS dissolution process [33], and increase in the entropy of activation values decreases in the system disorder due to the adsorption of inhibitor molecules on the MS surface [3436].

Adsorption isotherm

The efficiency of a corrosion inhibitor mainly depends on its adsorption ability on the metal surface. So, it is necessary to know the mechanism of adsorption and the adsorption isotherm that can give valuable information on the interaction of inhibitor and metal surface. The adsorption of inhibitor molecules from aqueous solution is a quasi-substitution process, and was found to be highly pH dependent [37]. The surface protection of MS depends upon how the inhibitor molecule will adsorbed on the metal surface, and also ionization and polarization of molecule [38]. The degree of surface coverage (θ) as function of concentration (C) of the inhibitor was studied graphically by fitting it to various adsorption isotherms to find the best adsorption isotherm. The Langmuir adsorption isotherm model was taken into account since equilibrium adsorption of all the four inhibitors was found to obey this adsorption isotherm model on MS in 0.5 M HCl medium. According to this adsorption isotherm, θ is related to the inhibitor concentration, C and adsorption equilibrium constant Kads through the following expression:

C C θ θ = 1 K ads + C
(7)

The surface coverage was tested graphically for fitting a suitable adsorption isotherm. In the present case, the plots of C/θ versus C (Fig. 5) yield straight lines with the linear correlation coefficient (R2) values close to unity, which suggests that the adsorption of PMN, MMN, NBT and MBN in 0.5 M HCl medium on MS surface obeys the Langmuir adsorption isotherm. The Gibbs free energy of adsorption was calculated using the relation (8):

Δ G ads = - 2.303 R T log 55.5 K ads
(8)

where R is the universal gas constant, T is the absolute temperature, Kads is the equilibrium constant for adsorption–desorption process and 55.5 is the molar concentration of water in solution (mol L−1). The other adsorption thermodynamic parameters such as enthalpy of adsorption ( Δ H ads ) and entropy of adsorption ( Δ S ads ) were obtained from the slope and intercept of the plot of log Kads versus 1/T (Fig. 6) using the Eq. (9).

log K ads = 1 2.303 - Δ H ads R T + Δ S ads R
(9)

The calculated values of Kads, Δ H ads , Δ G ads and Δ S ads over the temperature range of 30–60 °C are recorded in Table 3. The negative values of Δ G ads indicate the spontaneous adsorption of inhibitors on the surface of MS [39]. In the present study, Δ G ads values for PMN, MMN, NBT and MBN are found to be in the range −33.95 to −36.97, −34.08 to −37.07, −34.83 to −37.86 and −34.97 to −38.04 kJ mol−1 in the temperature range of 30–60 °C, respectively indicating that the adsorption is the combination of both physisorption and chemisorption [4043].

Fig. 5
figure 5

Langmuir’s adsorption isotherm plots for the adsorption of a PMN, b MMN, c NBT and d MBN in 0.5 M HCl on MS surface at different temperature

Fig. 6
figure 6

Plot of lnKads versus 1/T for PMN, MMN, NBT and MBN

Table 3 Thermodynamic parameters for adsorption of PMN, MMN, NBT and MBN on MS in 0.5 M HCl at different temperatures

FTIR spectral studies

FTIR spectra were recorded to understand the interaction of inhibitor molecules with the metal surface. Figures 7a, 8a, 9a and 10a show the FTIR spectra of pure PMN, MMN, NBT and MBN, and Figs. 7b, 8b, 9b and 10b represent the FTIR spectra of the scrapped samples obtained from the metal surfaces after corrosion experiments. It was found that peaks in the spectrum of scrapped samples were changed when compared to pure compounds. The azomethine group stretching frequencies for pure PMN, MMN, NBT and MBN were found at 1,645, 1,630, 1,643 and 1,587 cm−1, and carbonyl stretching frequencies were observed at 1,726, 1,672, 1,726 and 1,697 cm−1, respectively. In the FTIR spectra of scrapped samples, the stretching frequencies of the azomethine and carbonyl groups were found to be disappeared in the case of PMN, MMN and MBN, but in the case of NBT azomethine group was also disappeared and carbonyl stretching frequency was found to be slightly shifted to lower frequency (1,689 cm−1). These observations confirm that the azomethine and carbonyl groups of PMN, MMN, NBT and MBN are involved in the complex formation with the metal.

Fig. 7
figure 7

FTIR spectra of a PMN and b scratched MS surface adsorbed PMN film

Fig. 8
figure 8

FTIR spectra of a MMN and b scratched MS surface adsorbed MMN film

Fig. 9
figure 9

FTIR spectra of a NBT and b scratched MS surface adsorbed NBT film

Fig. 10
figure 10

FTIR spectra of a MBN and b scratched MS surface adsorbed MBN film

Potentiodynamic polarization studies

Polarization measurements were carried out to know the kinetics of anodic and cathodic reactions. Figure 11 reveals the polarization curves for MS in 0.5 M HCl in the absence and presence of different concentrations of PMN, MMN, NBT and MBN at 30 °C. Inspection of Tafel extrapolation plots showed that the addition of inhibitors hindered the acid attack on the MS electrode. In all the cases, the addition of inhibitors reduces both anodic and cathodic current densities indicating that these inhibitors exhibit cathodic and anodic inhibition effects, hence they are relatively mixed type of inhibitors [44, 45].

Fig. 11
figure 11

Polarization curves of MS in 0.5 M HCl in the presence of different concentrations of PMN, MMN, NBT and MBN

As the corrosion current density decreases, there will be a corresponding decrease in the electron transfer in the redox process; therefore the rate of corrosion reaction becomes slower. Usually a very good corrosion protection can be seen at low current density and at long anodization time due to the diminution of the porosity of the anodic films formed. Table 4 clearly highlights that there is a gradual decrease in the corrosion potential and corrosion current values as the inhibitor concentration was raised from 200 to 500 ppm. The values associated with electrochemical polarization parameters such as corrosion current density (Icorr), corrosion potential (Ecorr), corrosion rate and IE (%) were determined from the polarization plots, and are given in Table 4. The values of corrosion current densities were obtained by extrapolating the current–potential lines to the corresponding corrosion potentials. It is evident that IE (%) increases with inhibitors concentration, and protection action of PMN, MMN, NBT and MBN can be attributed to the electron density of the azomethine (–C=N–) group and this electron density varies with the substituent’s in the inhibitor molecules. The imine nitrogen can donate the lone pair of electrons to the metal surface more easily and hence reduces the corrosion rate. The IE (%) was found to be in the order: MBN > NBT > MMN > PMN, which can probably be explained on the basis of additional functional groups and also the nature of the hetero atoms in the inhibitor molecules.

Table 4 Polarization parameters and corresponding inhibition efficiency (IE) for the corrosion of the MS in 0.5 M HCl without and with various concentrations of PMN, MMN, NBT and MBN

Electrochemical impedance spectroscopy

Nyquist plots for MS in 0.5 M HCl solution with and without different concentrations of PMN, MMN, NBT and MBN are presented in Fig. 12. The Nyquist plots were regarded as one part of the semicircle mostly referred to as frequency dispersion which could be attributed to different physical phenomenon such as roughness, heterogeneities, impurities, grain boundaries and distribution of the surface active sites [46]. The electrochemical impedance parameters derived from the Nyquist plots and IE (%) are listed in Table 5. From the plots, it was clear that the impedance response of MS in uninhibited acid solution has significantly changed after the addition of inhibitors to the corrosive solution. This indicates that the impedance of the inhibited metal has increased with increasing concentration of inhibitors. The measured impedance data were based upon the equivalent circuit, given in the Fig. 13, which consists of constant double layer capacitance (Cdl) in parallel with polarization resistance (Rp) which is in series with solution resistance (Rs).

Fig. 12
figure 12

Nyquist plots for MS in 0.5 M HCl in the presence of different concentrations of PMN, MMN, NBT and MBN

Table 5 Impedance parameters for the corrosion of MS in 0.5 M HCl in the absence and presence of different concentrations of PMN, MMN, NBT and MBN
Fig. 13
figure 13

Equivalent circuit used to fit the impedance spectra

It was observable that, Rp values in the absence of the inhibitors were always lower than those in the presence of the inhibitors. The increase in the Rp values in the presence of different concentrations of PMN, MMN, NBT and MBN indicates reduction in the MS corrosion rate with the formation of adsorbed protective film on the metal-solution interface [47, 48]. When the concentration was raised from 200 to 500 ppm, there was a gradual increase in the diameter of each semicircle of the Nyquist plot reflecting the increase in Rp values from 27.81 to 163.8, 190.5, 316.8 and 562.0 Ω cm2 for PMN, MMN, NBT and MBN, respectively which indicates the adsorption of inhibitor molecules on the metal surface and also increase in stability of inhibitors film adsorbed on the metal surface.

The double layer capacitance (Cdl) values were decreased due to decrease in local dielectric constant and/or an increase in the thickness of the electrical double layer, indicating that the inhibitor molecules adsorbed at the metal-solution interface [49, 50]. Decrease in the surface area [51] and imperfections of the metal surface may also be the reason for decrease of Cdl values. Addition of inhibitors provided lower Cdl values because of the replacement of water molecules by inhibitor molecules at the electrode surface [52]. It was clear that as the immersion time increases the Rp values increase and Cdl values decrease which indicate the higher protection efficiency as a result of slow adsorption of these inhibitor molecules on to the surface of MS. However, when the immersion time is further enhanced, a sudden decrease in Rp values and increase in Cdl values were observed. This behaviour can be due to the instability of the passive film or desorption of the inhibitor molecules.

Mechanism of inhibition

The inhibition effect of nicotinamide derivatives towards the corrosion of MS in 0.5 M HCl solution may be attributed to the adsorption of these compounds at the metal-solution interface. The principal type of interaction between an organic inhibitor and metal surface is physisorption or chemisorption or both. The adsorption of inhibitor is influenced by the nature of the metal, chemical structure of inhibitors, type of aggressive electrolyte, temperature and the morphology of MS [53, 54]. The values of inhibition efficiency depend essentially on the electron density at the active centre of the inhibitor molecule. The thermodynamic parameters showed that the adsorption of these inhibitors on the MS surface in 0.5 M HCl solution involves both chemisorption and physisorption. Chemisorption of these inhibitors arises from the donor–acceptor interactions between the free electron pairs of hetero atoms and π electrons of multiple bonds as well as phenyl group and vacant d orbitals of iron [55].

The inhibition effect of PMN, MMN, NBT and MBN is due to the interaction of π-electrons of pyrrole, pyridine and phenyl rings as well as the presence of electron donor groups such as N, O, S, CH3 and C=N, through which the inhibitors adsorbed on the MS surface forming insoluble, stable and uniform thin film. Greater corrosion inhibition behaviour of compound MBN is linked to the electron donating effect of thiomethyl group attached to aromatic ring, which increases the electron density on the benzene ring. The increasing delocalization electron density in the molecule may be responsible for inhibiting corrosion process. The adsorption of inhibitor molecules is further stabilized by participation of π-electrons of benzene ring. The good inhibition efficiency of NBT compare to MMN and PMN may be due to the presence of extra thiol (SH) group. MMN (86 %) and PMN (83 %) are structurally almost similar exhibiting comparable corrosion inhibition efficiency at 500 ppm. The order of inhibition efficiency of the four inhibitors from mass loss, potentiodynamic polarization and EIS studies was found to be: MBN > NBT > MMN > PMN.

EDX analysis

EDX spectra were used to determine the elements present on MS surface before and after exposure to the inhibitor solution. The results are displayed in Fig. 14. Figure 14a is the EDX spectrum of polished MS sample and it is notable that the peak of oxygen is absent which confirms the absence of air formed oxide film. However, for inhibited solutions (Fig. 14b–e) the additional lines characteristics for the existence of N, O and S (due to the N and O atoms of the PMN and MMN, N, O and S atoms of the NBT and MBN) in the EDX spectra were obtained. These data showed that the N, O and S atoms of inhibitors are involved in bonding with the MS electrode surface. These results confirm those obtained from IR and SEM observations.

Fig. 14
figure 14

EDX images of a polished MS surface, b MS in 500 ppm PMN, c MS in 500 ppm MMN, d MS in 500 ppm NBT and e MS in 500 ppm MMN

SEM analysis

The SEM images of the polished and corroded MS surface in the absence and presence of inhibitors are shown in Fig. 15a–f. Figure 15a represents the SEM image for polished MS surface. Figure 15b is the SEM image of MS surface in 0.5 M HCl without inhibitor. It was found that the corroded MS surface contains large number of pits. However, SEM images of MS surface in the presence of inhibitors (Fig. 15c–f) were observed to be smoother than that of MS surface in 0.5 M HCl alone. These observations reveal that the inhibitors form protective layer on the MS surface, which prevents the attack of acid as well as the dissolution of MS by forming surface adsorbed layer and thereby reducing the corrosion rate.

Fig. 15
figure 15

SEM images of a polished MS surface, b MS in 0.5 M HCl, c MS in 500 ppm PMN, d MS in 500 ppm MMN, e MS in 500 ppm NBT and f MS in 500 ppm MBN

Conclusion

  1. 1.

    All the synthesized nicotinamide derivatives showed good inhibition efficiency for the corrosion of MS in 0.5 M HCl solutions and the inhibition efficiency found to be time, temperature and concentration dependent.

  2. 2.

    Langmuir adsorption isotherm was found to be the best description for the studied inhibitors, and the negative values of Gibbs free energy of adsorption indicate that the adsorption of inhibitors involves both physisorption and chemisorption process.

  3. 3.

    The inhibition efficiency was found in the order: MBN > NBT > MMN > PMN and the inhibition efficiencies determined by mass loss, potentiodynamic polarization and EIS methods are in good agreement with each other.

  4. 4.

    FTIR spectra, scanning electron microscopy (SEM) and energy dispersive X-ray spectroscopy (EDX) were performed to characterize the passive film on the metal surface.