1 Introduction

Evaluation of corrosion inhibitors for steel in acidic media signify for some industrial facilities as well as is very interesting from theoretical aspects. Acidic solutions are widely used in chemical laboratories and in several industrial processes such as acid pickling, acid cleaning, acid descaling, and oil well cleaning, etc. Also C-steel is utilized under different conditions in chemical and allied industries for handling alkaline, acid, and salt solutions [1]. Adsorbed organic compounds on metallic surface decrease the corrosion rate [24]. The adsorption observed depends mainly on certain physico-chemical properties of the inhibitor group, like functional groups, electron density at the donor atom, π-orbital character, and the electronic structure of the molecule [510].

Heterocyclic compounds such as antibiotic (pharmaceutical drugs) can provide excellent inhibition. These molecules depend at most on certain physical properties of the inhibitor molecules such as functional groups, steric factors, electron density at the donor atom, and electronic structure of the molecules [11]. A few researchers have reminded the use of antibacterial drugs as corrosion inhibitors because of the presence of oxygen, nitrogen, and sulfur in their structures as active centers, high solubility in water, high molecular size, nontoxic “environmentally friendly” corrosion inhibitors, important in biological reactions and drugs that can be easily produced and purified [1219]. In recent years the use of drugs as corrosion inhibitors for different metals due to their nontoxic nature, namely Cefatrexyl, Ciprofloxacin, Norfloxacin, Ofloxacin drugs, and Tacrine have been paid attention on by some authors [2022], therefore replacement by environmentally benign inhibitors is necessary. Recently, we have examined the inhibiting action of drugs such as Cefotaxime sodium, Cefazolin, Doxycycline, Pheniramine, Streptomycin, Cefalexin, Fexofenadine, Mebendazole, and Dapsone, on corrosion of metals in acid media [2331]. The use of drugs as corrosion inhibitors is due to the presence of π electrons, heteroatoms in their molecules through which they are either adsorbed or form insoluble metal complex at the metal surface and inhibit metal corrosion [32].

Moxifloxacin drug is a fourth-generation synthetic fluoroquinolone antibacterial agent that has greater activity against Gram-(+) bacteria, anaerobes, and is nontoxic and available. Hence attempts are made to utilize this pharmaceutical drug as anticorrosion agent on carbon steel in HCl medium using chemical and electrochemical techniques. The surface morphology of the carbon steel specimens was evaluated using scanning electron microscope (SEM) and energy dispersive X-ray (EDX) analysis.

2 Experimental Techniques

2.1 Materials

Rectangular specimens with dimensions 2 × 2 × 0.2 cm of carbon steel with chemical composition seen in (Table 1) were used for all measurements. For electrochemical tests, the exposed surface area of the metal was 1 cm2.

Table 1 Chemical composition (weight %) of the carbon steel

2.2 Inhibitors and Chemicals

The pharmaceutical compound named Moxifloxacin has been investigated which was purchased from Memphis company, Cairo, Egypt. The investigated pharmaceutical drug is used as received and chosen because it is easily soluble in water, has high molecular weight, and contains many donating atoms (N, O, and P). All the solutions were prepared from AR grade chemicals using bidistilled water. The aggressive solutions used were made from 37 % HCl, appropriate concentrations of acid were prepared using bidistilled water. 1000 ppm stock solutions from the investigated inhibitor were prepared by dissolving 1 g/l of the solid pharmaceutical drug in bidistilled water; the other concentrations of pharmaceutical drug (50–300 ppm) were prepared by dilution with bidistilled water. All the materials used were of AR grade and used as received (Table 2).

Table 2 Represents the name, structure, molecular weight and molecular formula of the investigated drug

2.3 Methods

2.3.1 Chemical Measurements

2.3.1.1 Weight Loss Measurements

Coupons of C-steel specimens of area equal to 8 cm2 were abraded with emery papers of 1/0, 2/0, 3/0, and 4/0 grade, degreased by acetone and weighed, then immersed in 100 ml of the test solution in open beakers. The beakers were placed into a water bath maintained at 25 °C. Each sample of C-steel was withdrawn from the test solution after every 30 min, washed, and dried in air before reweighing. The difference in weight after each interval was taken as the weight loss. The experiment was repeated at 25–45 °C. From the weight loss results, the inhibition efficiency (% IE) of the drug, degree of surface coverage (θ), and corrosion rate (k corr) were determined using the following equations [33]:

$$\% {\text{ IE}} = \theta \times 100 = [1 - (W_{1} /W_{2} )] \times 100,$$
(1)
$$k_{\text{corr}} { = }W /At,$$
(2)

where W 1 and W 2 are the weight losses for C-steel in the presence and absence of the drug, A is the area of the C-steel coupon (cm2), t is the time of immersion (min), and W is the weight loss (mg cm−2) of C-steel after time t (min).

2.3.1.2 Hydrogen Evolution Method

Hydrogen Evolution Method assembly used for the measurement of hydrogen gas evolved from the corrosion reaction was described by Onuchukwu [34]. 100 ml of tested solution was used in each experiment. The time was recorded and H2 evolved was collected in a calibrated tube by displacement of water over time interval of 120 min. A plot of H2 evolved per unit area (ml/cm−2) against time (min) in the presence of different concentrations of the Moxifloxacin yield straight lines with slope that represent the rate of H2 evolved.

2.3.1.3 Thermometric Method

The reaction vessel and the procedure for determining the corrosion of carbon steel in 1 M HCl solution were the same as described before [35]. The test pieces were made of sheets measuring 1 × 10 × 0.2 cm. Before being used, these were lightly abraded with different grades of emery papers then degreased by acetone. Each experiment was carried out with a new clean specimen and with 15 mL of the aggressive solution. The variation of the temperature of the system was measured to ±0.1 °C on a calibrated thermometer.

The inhibiting efficiency was calculated from the percentage decrease in reaction number (RN) and was determined using the following equations:

$${\text{IE}}(\% ) = [{\text{RN}}_{\text{free}} - {\text{RN}}_{\text{inh}} /{\text{RN}}_{\text{free}} ] \times 100$$
(3)

The reaction number RN is defined as

$${\text{RN}} = [(T_{\text{m}} - T_{\text{i}} )/t = {{\Delta }}T/t^\circ {\text{C }}\min^{ - 1} ],$$
(4)

where T m and T i are the maximum and initial temperatures, respectively and t is the time in minutes taken to reach T m.

2.3.2 Electrochemical Measurements

A three-electrode electrochemical cell was used. The working electrode was C-steel of surface area of 1 cm2. Before each experiment, the electrode was abraded using emery papers as before. After this, the electrode was cleaned ultrasonically with ethyl alcohol and washed by bidistilled water. All potentials were given with reference to the saturated calomel electrode (SCE). The counter electrode was a platinum plate of surface area of 1 cm2. The working electrode was immersed in the test solution during 30 min until a steady-state open circuit potential (E ocp) was obtained. The polarization curves were recorded by polarization from −0.6 to 0.2 V under potentiodynamic conditions corresponding to 1 mV/s (sweep rate) and under air atmosphere. All measurements were carried out with C-steel electrode in 1 M HCl in the absence and presence of different concentrations of the investigated drug at 25 °C. All experiments were carried out at 25 °C. The inhibition efficiency and surface coverage (θ) were calculated from the following equation:

$$\% {\text{IE}} = \theta \times 100 = \left[ {1 - \left( {i_{\text{corr(inh)}} / \, i_{\text{corr(free)}} } \right)} \right] \times \, 100,$$
(5)

where i corr (free) and i corr (inh) are the corrosion current densities in the absence and presence of inhibitor, respectively.

Electrochemical impedance spectroscopy (EIS) tests were performed using the same cell that was used in polarization experiments. The EIS was carried out over a frequency range of 1 Hz to 100 kHz, with a signal amplitude perturbation of 10 mV. The inhibition efficiency (% IE) and surface coverage (θ) of the investigated compounds obtained were calculated from the following equation:

$$\% {\text{ IE}} = \theta \, \times 100 \, = \, [1 - \left( {R_{\text{ct}}^{ \circ } / \, R_{\text{ct}} } \right] \, \times \, 100,$$
(6)

where ct and R ct are the charge transfer resistance values in the absence and presence of the inhibitor, respectively.

Electrochemical frequency modulation (EFM) is a nondestructive technique that can directly and rapidly give values of the corrosion current without a prior knowledge of Tafel constants. The great of the EFM is the causality factors, which serve as an internal check on the validity of the EFM measurement. With the causality factors the experimental EFM data can be verified [36]. Identical cell assembly was used in impedance studies. All electrochemical measurements were carried out using Potentiostat/Galvanostat/Zra analyzer (Gamry PCI4-G750). A personal computer with DC105 software for potentiodynamic, EIS300 software for EIS and EFM140 software for EMF and Echem Analyst v 5.21 was used for data fitting.

2.3.3 Surface Examinations

The specimens of C-steel used for surface morphology examination were immersed in 1 M HCl in the absence (blank) and presence of 300 ppm of Moxifloxacin at 25 °C for one day. The analysis was performed using scanning electron microscope (JEOL JSM-5500, Japan). Rough elemental analyses for the exposed surface were conducted by EDX technique.

3 Results and Discussion

3.1 Chemical Measurements

3.1.1 Weight Loss Measurements

Weight loss of carbon steel was determined, at various time intervals, in the absence and presence of different concentrations of Moxifloxacin. From the experimental data of the weight loss measurements, the inhibition efficiency % IE, was calculated from Eq. (1). All the experiments were performed at 25–45 °C. Values of corrosion rates (k corr) and % IE of Moxifloxacin are summarized in Table 3. The value of % IE increases with increasing drug concentration and decreases with rise in temperature. This behavior can be attributed to the increase of the surface coverage and due to the adsorption of drug on the surface of C-steel. The optimum concentration needed to achieve an efficiency of 94 % was found to be 300 ppm. In all cases, the increase in the inhibitor concentration was accompanied by a decrease in weight loss and an increase in the percentage inhibition. These results lead to the conclusion that the Moxifloxacin under investigation is fairly efficient as inhibitor for C-steel dissolution in HCl solution. The results confirmed the very good effect of Moxifloxacin on the corrosion inhibition of C-steel in 1 M HCl solution. Figure 1 shows the weight loss–time curves for the corrosion of C-steel in 1 M HCl solution in the absence and presence of Moxifloxacin at 25 °C.

Table 3 Corrosion rate (CR) and inhibition efficiency data obtained from weight loss measurements for C-steel in 1 M HCl solution in the absence and presence of different concentrations of Moxifloxacin at 25 °C
Fig. 1
figure 1

Weight loss–time curves for the corrosion of C-steel in 1 M HCl solution in the absence and presence of Moxifloxacin at 25 °C

3.1.1.1 Effect of Temperature

The effect of temperature on the corrosion parameters of C-steel with the addition of Moxifloxacin was studied using weight loss method. A major advantage of this method is its relative simplicity and availability. The data of corrosion behavior of C-steel in 1 M HCl containing different concentrations of Moxifloxacin for 120 min immersion in temperature range 25–45 °C are presented in (Table 4). Inspection of this Table reveals that the corrosion rate of C-steel increases with increased temperature. On the other hand, the inhibition efficiency of Moxifloxacin decreased with raising temperature Fig. 2. This suggests possible desorption of the adsorbed drug molecules from the metal surface at higher temperatures. Such behavior indicates that the additive was physically adsorbed on the metal surface.

Table 4 Effect of Moxifloxacin concentration on corrosion rate (k corr) and inhibition efficiency (% IE) for C-steel in 1 M HCl at different temperatures and at 120 min immersion
Fig. 2
figure 2

Effect of Moxifloxacin concentration on the inhibition efficiency

Arrhenius-type dependence is observed between corrosion rate and temperature and often expressed as:

$$k_{\text{corr}} = \, A \, \exp - E^{*}_{a} /RT,$$
(7)

where \(E_{\text{a}}^{*}\) is the apparent activation energy, R is the universal gas constant, T is the absolute temperature, and A is the frequency factor. Figure 3 depicts Arrhenius plot log k corr against the reciprocal of temperature 1/T for C-steel in 1 M HCl solution in the absence and presence of different Moxifloxacin concentrations. An alternative formulation of Arrhenius equation is [37]:

$$k_{corr} = \, RT/Nh \, \exp \, \left( {\Delta S^{*} /R} \right) \, \exp \, \left( { - \Delta H^{*} /RT} \right),$$
(8)

where h is the Planck’s constant and N is the Avogadro’s number. Figure 4 shows a plot of log k corr/T as a function of 1/T for C-steel. Straight lines were obtained with a slope of −ΔH */R and an intercept of ln R/Nh + ΔS */R from which the values of ΔH * and ΔS * were calculated for the blank and Moxifloxacin. The values of the activation energy, enthalpy, and entropy are recorded in Table 5. The increase in the activation energy is proportional to the drug concentration, indicating that the energy barrier for corrosion process is also increased [38]. The increase in the activation enthalpy (ΔH *) in presence of the inhibitor means that the addition of the Moxifloxacin to the acid solution increases the height of the energy barrier of the corrosion reaction to an extent depends on the type and concentration of the present Moxifloxacin. The adsorption of the drug molecules on the metal surface leads to a lower number of hydrogen atoms adsorbed on it; this will cause a decrease in hydrogen evolution rate rather than the rate of metal dissolution, because of the blocking of the surface of the metal by the extract molecules.

Fig. 3
figure 3

Arrhenius plots for the corrosion rate of C-steel in 1 M HCl with and without Moxifloxacin

Fig. 4
figure 4

Log (k corr/T) versus 1/T for C-steel in 1 M HCl as blank and with Moxifloxacin at different temperatures

Table 5 Activation parameters for C-steel corrosion in the absence and presence of various concentrations of Moxifloxacin in 1 M HCl
3.1.1.2 Adsorption Isotherms

Attempts were made to fit the relationship between θ and the bulk concentration of the inhibitor used at a certain given temperature in order to give an insight into the adsorption process. Several adsorption isotherms are commonly used to characterize the drug performance and the best fit was obtained using Langmuir isotherm, which assumes that the solid surface contains a fixed number of adsorption sites and each site holds one adsorbed species [39] in good agreement with the following Eq. ( 9 ):

$${\text{C}}/\theta \, = \, 1/ \, K_{\text{ads}} + {\text{ C}},$$
(9)

where K ads is the equilibrium constant of the adsorption process. A plot of (C/θ) versus (C) of Moxifloxacin at different temperatures present in Fig. 5 suggests that there are no attraction or repulsion forces between the adsorbed molecules, since a linear relationship is obtained with a slope equal to unity and intercept equal to 1/K ads. The adsorption equilibrium constant being related to the standard free energy of adsorption (\({{\Delta }}G_{\text{ads}}^{{{\circ }}}\)) by the relation ( 10 ):

$$K_{\text{ads}} = \, \left( {1/55.5} \right) \, \exp \, \left( {\Delta G_{\text{ads}}^{ \circ } / \, RT} \right),$$
(10)

where the constant 55.5 is the molar concentration of water in solution in M−1. By applying Eq.  6 , we obtain different values of \({{\Delta }}G_{\text{ads}}^{{{\circ }}}\) for drug as a function of temperature and are listed in Table 6. The results of this Table show the dependence of \({{\Delta }}G_{\text{ads}}^{{{\circ }}}\) on the absolute temperature (T). Figure 6 shows the relation between \({{\Delta }}G_{\text{ads}}^{{{\circ }}}\) and T. A linear plot was obtained with high regression constant and with a slope equal to the entropy of adsorption (\({{\Delta }}S_{\text{ads}}^{{{\circ }}}\)) and intercept equal to the enthalpy of adsorption (\(\Delta H_{\text{ads}}^{ \circ }\)), according to Eq. ( 11 ):

$$\Delta G_{\text{ads}}^{ \circ } = \Delta H_{\text{ads}}^{ \circ } - T\Delta S_{\text{ads}}^{ \circ }$$
(11)
Fig. 5
figure 5

Langmuir adsorption isotherms for Moxifloxacin at different temperatures for C-steel immersed on 1 M HCl

Table 6 Kinetic parameters for the corrosion of C-steel in 1 M HCl at different temperatures
Fig. 6
figure 6

Log K ads versus (1000/T) for corrosion of C-steel in 1 M HCl in the presence of Moxifloxacin

The various thermodynamic functions for the adsorption process are given in Table 6. It is generally obvious that \({{\Delta }}G_{\text{ads}}^{{{\circ }}}\) has negative value, which indicates that the tested drug is adsorbed spontaneously on C-steel surface forming a relatively stable adsorbed layer. It known that values of \({{\Delta }}G_{\text{ads}}^{{{\circ }}}\) lower than 20 kJ mol−1 is indicative of physical adsorption [40]. The value of \({{\Delta }}G_{\text{ads}}^{{{\circ }}}\) is approximately equal 23 kJ mol−1 which indicates that the adsorption mechanism of the Moxifloxacin on C-steel surface involves physical adsorption. The K ads follows the same trend in the sense that larger value of K ads means more efficient adsorption and hence better inhibition efficiency. The negative sign of \(\Delta H_{\text{ads}}^{{{\circ }}}\) reveals that adsorption of the inhibitor on C-steel surface from 1 M HCl solution is an exothermic process, which implies that % IE for the drug decreases with the rise in temperature. Such behavior can be explained on the basis that temperature rise causes desorption of some adsorbed drug molecules on the C-steel surface and hence lower protection was observed.

3.1.1.3 Hydrogen Evolution (HE) Tests

Data are plotted for the volume of H2 gas evolved against time in minutes for 50–300 ppm of Moxifloxacin concentrations and presented in Fig. 7. Slopes of such lines are estimated and taken as the rates of corrosion reaction as mentioned before. The good linearity in the relations indicates the presence of insoluble film on the metal surface during corrosion. The calculated corrosion rates (k corr) obtained from HE are tabulated in (Table 7). As observed, corrosion rate decreases with the increasing of Moxifloxacin concentration. According to Eq. (12) which pointed out that iron dissolution in HCl solutions depends on H+ ion more than the Cl ion [41]. The hydrogen evolution and weight loss are produced by the same reaction:

Fig. 7
figure 7

Volume of hydrogen evolved versus time for C-steel corrosion in HCl solutions at different concentrations of Moxifloxacin at 25 °C

Table 7 Corrosion rates for C-steel sample at different concentrations of Moxifloxacin at 25 °C as determined by H2 evolution method
$${\text{Fe }}\left( {\text{solid}} \right){\text{ + 2 H}}^{ + } {\text{ = = Fe}}^{{ 2 { + }}} {\text{ + H}}_{ 2} \left( {\text{gas}} \right)$$
(12)

Data are plotted for the volume of H2 gas evolved against time in minutes for 50–300 ppm of Moxifloxacin concentrations and presented in Fig. 7. Slopes of such lines are estimated and taken as the rates of corrosion reaction as mentioned before. The good linearity in the relations indicates the presence of insoluble film on the metal surface during corrosion.

3.1.1.4 Thermometric Measurements

In this method the temperature change was followed in the absence and presence of different concentrations of the Moxifloxacin as inhibitor. Curves of Fig. 8 represent the behavior observed in the presence of different concentrations of drug. All curves of the tested drug are characterized by an initial slow rise (due to the oxide film originally present on the metal surface) [42] followed by a sharp rise and finally by a decrease in temperature after attaining a maximum value. The curves for additive containing systems fall below that of the free acid. This indicates that the additive behaves as inhibitor over the concentration range studied. The percentage reduction in RN of the studied drug is presented in (Table 8). The results of (Table 8) reveal that the efficiency of corrosion inhibition as determined from the percentage reduction in RN varies with the concentration of the drug.

Fig. 8
figure 8

Temperature–time curves obtained in the absence and presence of different concentrations of the drug

Table 8 The Inhibition Efficiency of Moxifloxacin at 25 °C as determined from thermometric method

3.2 Electrochemical measurements

3.2.1 Potentiodynamic Polarization Tests

The polarization curves for C-steel in 1 M HCl solution with and without Moxifloxacin are presented in Fig. 9. Corrosion current densities were obtained from polarization curves by linear extrapolation of anodic and cathodic branches of Tafel slopes. The inhibition efficiency (% IE) and surface coverage (θ) were calculated from Eq. ( 5 ). The electrochemical parameters such as: corrosion potential (E corr), corrosion current density (i corr), anodic Tafel constant (b a), and cathodic Tafel constant (b c) are presented in Table 9. From the results, one can see when the concentration of Moxifloxacin was increased, the corrosion current density gradually decreased and the inhibition efficiency increased. The nearly steady values of (E corr) and the decreases of corresponding partial anodic and cathodic current densities, these data show that Moxifloxacin acts as mixed-type inhibitor [43]. Addition of Moxifloxacin has no significant effect on the values of anodic and cathodic Tafel slopes (b a, b c). Therefore, the addition of this drug blocked the active sites of the electrode surface, decreasing the surface area available for corrosion reaction [44]. Therefore the presence of various concentrations of Moxifloxacin does not alter the corrosion mechanism. The experimental findings of Tafel curves were in good agreement with the data obtained in case of weight loss.

Fig. 9
figure 9

Tafel polarization curves of C-steel corrosion with and without different concentrations of Moxifloxacin at 25 °C

Table 9 Corrosion parameters in the presence and absence of Moxifloxacin obtained from polarization measurements

3.2.2 EIS Tests

Figure 10 shows the Nyquist plot for C-steel in 1 M HCl in the absence and presence of different concentrations of Moxifloxacin at 25 °C. This diagram has a semicircle appearance; it indicates that the corrosion of Moxifloxacin is mainly controlled by a charge transfer process. The Bode plot for the C-steel is shown in Fig. 11 where the high frequency limit corresponds to electrolyte resistance R Ω, while the low frequency limit represents the sum of (R Ω + R p) where R p is the first approximation determined by both the electrolytic conductance of the oxide film and polarization resistance of the dissolution and passivation process. Various impedance parameter such as charge transfer resistance (R ct), double layer capacitance (C dl), and inhibition efficiency (% IE) were calculated and are given in Table 10. The data obtained show that the value of charge transfer resistance (R ct) increases while the value of double layer capacitance (C dl) decreases with increasing the concentration of the drug. This is due to the adsorption of the drug molecules on the electrode surface leading to a film formation of Moxifloxacin on C-steel surface. The obtained Nyquist diagram in most cases does not show perfect semicircle. This may be attributed to the frequency dispersion as a result of the inheterogeneity of the electrode surface [45, 46]. However, the diameter of the capacitive loop increases with the increasing concentration of Moxifloxacin.

Fig. 10
figure 10

Nyquist plots for the corrosion of C-steel in 1 M HCl in the absence and presence of different concentrations of Moxifloxacin at 25 °C

Fig. 11
figure 11

Bode plots for the corrosion of C-steel in 1 M HCl in the absence and presence of different concentrations of Moxifloxacin at 25 °C and Equivalent circuit model used to fit the impedance spectra

Table 10 EIS data of different concentrations of Moxifloxacin in 1 M HCl for the corrosion of C-steel at 25 °C

3.2.3 EFM Tests

Figure 12 shows the EFM intermodulation spectra of carbon steel in HCl solution containing different concentrations of Moxifloxacin. The larger peaks were used to calculate the corrosion current density (i corr), the Tafel slopes (b c and b a), and the causality factors (CF-2 and CF-3). These electrochemical parameters are listed in Table 11. The data presented in Table 11 obviously showed that, the addition of Moxifloxacin at a given concentration to the acidic solution decreases the corrosion current density, indicating that this drug inhibits the corrosion of carbon steel in 1 M HCl through adsorption. The causality factors obtained under different experimental conditions are approximately equal to the theoretical values (two and three) indicating that the measured data are verified and of good quality. The inhibition efficiency (% IEEFM) increases by increasing the drug concentration and was calculated as from Eq. (5).

Fig. 12
figure 12

EFM spectra for carbon steel in 1 M HCl in the absence and presence of different concentrations of Moxifloxacin

Table 11 Electrochemical kinetic parameters obtained by EFM technique for C-steel in the absence and presence of various concentrations of Moxifloxacin in 1 M HCl at 25 °C

3.3 Surface Analysis

Figure 13a represents the surface of carbon steel without any addition. Figure 13 b gives the surface of C-steel after immersion in 1 M HCl solution, one can see the damage of the C-steel surface but Fig. 13c represents the surface of C-steel after the addition of 300 ppm drug. From this Figure, the surface is almost free from damages and it is smooth, this indicates a good protective film present on the carbon steel surface, and also confirms the highest inhibition efficiency of Moxifloxacin.

Fig. 13
figure 13

SEM micrographs of C-steel surface a before immersion in 1 M HCl, b after one day of immersion in 1 M HCl, and c after one day of immersion in 1 M HCl + 300 ppm of Moxifloxacin at 25 °C (SEI 20 kV, WD 5 mm, SS50, ×500, 50 μm)

Figure 14 portrays the EDX analysis of C-steel in 1 M HCl only and in the presence of 300 ppm of the drug. The spectra show additional lines, demonstrating the existence of carbon (owing to the carbon atoms of the drug). These data show that the carbon and oxygen atoms covered the specimen surface. This layer is entirely owing to the inhibitor, because the carbon and oxygen signals are absent on the specimen surface exposed to uninhibited HCl. It is seen that, in addition to O, C was also present in the spectra. A comparable elemental distribution is shown in Table 12.

Fig. 14
figure 14

EDX analysis on C-steel in presence and absence of drug for 2 days of immersion

Table 12 Surface composition (weight %) of carbon steel before and after immersion in 1 M HCl without and with 300 ppm of Moxifloxacin at 25 °C

3.4 Mechanism of Corrosion Inhibition

The adsorption of drug molecules can be attributed to the existence of polar unit having atoms of nitrogen and oxygen and aromatic/heterocyclic rings. Therefore, the possible reaction centers are unshared electron pair of heteroatoms and л-electrons of the aromatic rings [47]. The adsorption and inhibition effect of drug molecules in 1 M HCl solution can be explained as follows: In aqueous acidic solutions, drug molecules exist either as neutral molecules or as protonated molecules and may adsorb on the metal/acid solution interface by one and/or more of the following ways: (i) electrostatic interaction of protonated molecules with already adsorbed chloride ions, (ii) interaction between unshared electron pairs of heteroatoms and vacant d-orbital of iron surface atoms. The possible explanation of the inhibition is due to the adsorption process which is considered as the key of the mechanism of inhibition action. It might be proposed that the drug molecules adhere to the steel surface. This leads to a decrease of the surface area at which cathodic and anodic reactions take place. Inhibition efficiency of the drug molecules depends on many factors [48], which include the number of adsorption active centers in the molecule and their charge density, molecular size, and mode of interaction with the metal surface [49, 50]. The transition of metal/solution interface from a state of active dissolution to the passive state of great interest. The inhibition effect by inhibitor is attributed to the adsorption of the inhibitor molecules via their functional group onto the metal surface, that drug can be adsorbed in the form of negatively charged species on the metal surface which can interact electrostatically with positively charged metal surface, leading to increase in the surface coverage, and consequently protect the efficiency in controlling the anodic metal dissolution and cathodic hydrogen evolution. The adsorption rate is usually rapid and hence the reactive metal is shielded from the aggressive environment.

4 Conclusions

The nontoxic drug of Moxifloxacin acts as a good and efficient inhibitor for the corrosion of C-steel in 1 M HCl medium. The maximum inhibition was found to increase with concentration and decrease with the raise in temperature. The adsorption of the drug on C-steel obeys Langmuir adsorption isotherm. A polarization study reveals that the drug acts via mixed mode of inhibition. The impedance method revealed that charge transfer process mainly controls the corrosion of C-steel. The SEM morphology of the adsorbed protective film on C-steel surface has confirmed the high performance of inhibitive effect of the Moxifloxacin. Results obtained from weight loss, hydrogen evolution, thermometric, DC polarization, AC impedance, and EFM techniques are reasonably in good agreement with each other as shown below:

Methods

Chemical

Electrochemical

Wt. loss

Thermometric

H E

EFM

EIS

Pot

% IE

94.1

93

92.5

92.3

92

92