Introduction

Corrosion inhibitors are compounds added to the medium to decrease the rate of corrosion of metal. Inhibitors are used in closed or circulating systems [1, 2] and are chosen for their effectiveness in protecting the specific metal or different metals in a given system. Halogenated compounds, surfactants, and heterocyclic compounds containing nitrogen, phosphorus, oxygen, and sulfur can inhibit the corrosion of metals [36]. Some high molecular weight organic compounds such as proteins and polysaccharides have good corrosion inhibitive properties [7]. Inhibitors prevent the corrosion process and reduce the acid utilization during acid pickling of fabricated metals. The inhibitors’ mechanism of action is preceded by electrostatic or chemical interaction between the metal surface and the heteroatoms included in their chemical structures. In spite of the existence of many organic compounds as inhibitors, development of new compounds must be done to achieve more economic, environmentally friendly, and efficient inhibitors [8, 9]. Pure natural compounds can be used as corrosion inhibitors. For example, vanillin was evaluated as an environmentally friendly corrosion inhibitor for aluminum dissolution in acidic medium [10, 11]. Vanillin offers interesting possibilities for corrosion inhibition owing to its environmentally friendly nature [10] and its high solubility in water [12]. The efficiency of pure vanillin was in the range of 80–85 % based on its concentration. The inhibition action of vanillin is attributed to its adsorption on the surfaces through the active centers contained in its structure. Tannic acid is a specific compound of polyphenol tannin. Tannic acid is used in the conservation of ferrous metal objects without the necessity of corrosion products removal from corroded surfaces [13]. Tannic acid is therefore especially useful in anticorrosive protection of objects of heritage. Tannic acid can also be applied in corrosion protection of copper [14], aluminum [15], zinc and nickel [16]. Although tannins can be applied as corrosion inhibitors, sometimes they can increase the acidity of the medium. Thus, modification of the chemical structure of tannic acid can improve the efficiency and applicability of its derivatives as corrosion inhibitors.

Schiff bases are more efficient inhibitors than the corresponding amines. Schiff bases of some aliphatic amines showed excellent inhibition of carbon steel corrosion in acidic medium, which is of particular interest to petroleum companies [17, 18]. Schiff bases of heterocyclic compounds also showed good inhibition efficiencies for steel in different media [19, 20]. The anticorrosion inhibition efficiency of Schiff bases is attributed to the bonding of imine π electrons with d orbitals of the metal [18, 20]. The aim of this study was to synthesize nonionic surfactants derived from a naturally occurring compound (tannic acid), to study their surface and thermodynamic properties, and to evaluate their ability as inhibitors of the corrosion of carbon steel in acidic medium. The target surfactants were chosen to be environmentally friendly and ideally exhibit higher efficiency as corrosion inhibitors than the reported pure natural compounds.

Experimental Section

Materials

Polyethylene glycols (PEG) of different molecular weight (purity 99.8 %) were purchased from Alfa Aesar, Germany. Vanillin (purity 99 %) and 4-hydroxybenzaldehyde (purity 99.9 %) were obtained from Sigma-Aldrich, Germany. Paraffin oil (a mixture of C16–C26 hydrocarbons) was obtained from ADWIC, Egypt.

Synthesis of Tannic Acid–Polyethylene Glycol Esters (T1–3)

Tannic acid (0.017 mol, 30 g) was reacted with PEG of different molecular weight (PEG-400, 6.8 g, 0.017 mol; PEG-600, 10.2 g; and PEG-1500, 25.5 g) in the presence of hydrochloric acid (two drops) as a dehydrating agent and 100 mL of xylene as a solvent. The reaction was performed at 138 °C in a 500-mL round-bottom flask equipped with a mechanical stirrer and Dean–Stark condenser. The reaction was stopped after obtaining 0.31 mL of water and cooled. The solvent (xylene) was evaporated under reduced pressure in a closed system oven equipped with a glass trap and mini-vacuum pump. The reaction product was washed with acetonitrile to remove the excess reactants, then with methanol, and dried under vacuum [21]. The obtained products were brown-yellow and waxy, and designated as follows: T1, tannic acid–PEG-400 (MW 2082 g/mol); T2, tannic acid–PEG-600 (MW 2282 g/mol); T3, tannic acid–PEG-1500 (MW 3182 g/mol).

Synthesis of Tannic Acid–Polyethylene Glycol–p-Aminobenzoic Acid Diesters (TA1–3)

p-Aminobenzoic acid (0.017 mol, 2.055 g) was reacted with T1–3 esters (0.015 mol, 31.23, 34.23, 47.73 g) individually at 138 °C in the presence of two drops of hydrochloric acid and 100 mL of xylene, as dehydrating agent and solvent, respectively. The reaction was performed in a 250-mL round-bottom flask equipped with a mechanical stirrer and Dean–Stark condenser. The reaction was stopped after obtaining 0.015 mol of water (0.27 mL). The reaction products were washed twice with methanol and dried under vacuum [21]. The solvent was evaporated under reduced pressure in a closed system oven equipped with a glass trap and mini-vacuum pump. The obtained brown waxy esters were designated as follows: TA1, tannic acid–PEG-400–p-aminobenzic acid (MW 2201 g/mol); TA2, tannic acid–PEG-600–p-aminobenzic acid (MW 2401 g/mol); TA3, tannic acid–PEG-1500–p-aminobenzic acid (MW 3301 g/mol).

Synthesis of Vanillin and p-Hydroxybenzaldehyde Schiff Bases of TA1–3 Diesters

Vanillin (0.01 mol, 1.52 g) and p-hydroxybenzaldehyde (0.01 mol, 1.22 g) were reacted with the three diesters TA1–3 (0.01 mol, 22.01, 24.01, 33.01 g) in the presence of xylene as a solvent at 140 °C, with continuous removal of water during the reaction using a Dean–Stark condenser. The reaction was stopped after obtaining 0.18 mL of water, and then the solvent was removed under reduced pressure. The obtained products were washed with excess methanol and dried under vacuum [22] to obtain six nonionic Schiff bases denoted as follows: V1, vanillin Schiff base of TA1; V2, vanillin Schiff base of TA2; V3, vanillin Schiff base of TA3; H1, p-hydroxybenzaldehyde Schiff base of TA1; H2, p-hydroxybenzaldehyde Schiff base of TA2; H3, p-hydroxybenzaldehyde Schiff base of TA3.

Measurements

Analyses

FTIR spectroscopic analyses were performed using a Genesis FTIR spectrometer, USA.

Surface Tension Measurements

Surface and interfacial tension values were measured by using a Kruss-K6 tensiometer with a platinum ring (precision range ±0.5 mN/m). Freshly prepared solutions of the synthesized Schiff base nonionic surfactants V1–3 and H1–3 were prepared with a concentration range of 1 × 10−2 to 5 × 10−5 M in doubly distilled water. Surface tension measurements were performed for the prepared solutions at 25 °C. The measurements were repeated three times and the average was taken for each concentration. Each reading was measured after 2 min in the measuring cell to allow surface stabilization to be achieved. The measuring cell was made of Teflon to avoid adsorption of surfactant on the cell wall. The platinum ring was washed with diluted acid, acetone, and finally with distilled water after each reading to ensure that accurate values were obtained [23].

Interfacial Tension Measurement

Interfacial tension measurements were performed between light paraffin oil and surfactant solutions with a concentration of 0.1 % by weight at 25 °C. Twenty milliliters of surfactant solution was placed in the measuring cell, and the platinum ring holds in the bottom of the cell. Then, 20 mL of light paraffin oil was placed on the solution surface and the platinum ring was adjusted to locate it at the interfacial surface of the oil–solution system. The interfacial tension value was considered after detachment of the ring from the solution phase to the oil phase. The measurements were repeated three times, each time with a fresh system, and the interfacial tension value was the average of these three readings [24].

Emulsion Stability Measurements

Emulsion stability was measured by placing 25 mL of 0.1 % solution of each surfactant by weight and 25 mL of light paraffin oil in a 100-mL measuring cylinder. The temperature of the cylinder was adjusted to 25 °C. The cylinder was vigorously shaken for 5 min, and the mixture was then allowed to separate. The time required for separation of 20 mL of pure surfactant solution was recorded. Measurements were repeated three times and the time was taken as the average of these readings. Measurements were considered for each surfactant individually, and readings were calculated in minutes [24].

Potentiodynamic Polarization Measurements

Potentiodynamic polarization measurements were performed using a Volta Lab-PGZ-301 (France). A conventional 250-mL cylindrical glass cell equipped by three electrodes was used. A saturated calomel electrode (SCE) and platinum electrode (2 cm2 area) were used as reference and auxiliary electrodes, respectively. The working electrode (carbon steel disc of 0.8 cm2) was surrounded with epoxy except the working surface. Potentiodynamic polarization curves were obtained by changing the potential from −200 to +200 mV versus open circuit potential (OCP) with the scan rate of 5 mV s−1. The inhibition efficiency (η%) was calculated using the following equation [4, 5].

$$\eta \% = \frac{{i_{\text{corr(uninh)}} - i_{\text{corr(inh)}} }}{{i_{\text{corr(uninh)}} }} \times 100$$

where i corr(uninh) and i corr(inh) are the corrosion current densities without and with inhibitors, respectively.

Electrochemical Impedance Spectroscopy (EIS)

Electrochemical impedance spectroscopy measurements were carried out using a Volta Lab, model PGZ-301 (France) and a software program (Voltameter 4) [4]. The measurements were performed using AC signal (10 mV) peak to peak at the OPC in the frequency range of 100 kHz to 10 mHz.

Results and Discussion

Structure

The chemical structures of TA1–3 diesters were confirmed by FTIR spectroscopic analysis using a Genesis FTIR spectrophotometer (Mattson, Wisconsin, USA) (Scheme 1).

Scheme 1
scheme 1

Synthesis of the nonionic surfactants under study

FTIR spectra of TA1–3 showed the following absorption bands: a broad band from 3200 to 3600 cm−1 centered at 3400 cm−1 corresponded to hydroxyl and amino groups; two absorption bands at 2920 and 2850 cm−1 corresponded to symmetric and asymmetric vibration of methylene groups; a band at 1690 cm−1 corresponded to ester groups, 1190 cm−1 corresponded to C–N groups, 1029 cm−1 corresponded to ether groups, and bands at 970 and 730 cm−1 corresponded to the phenyl groups (see additional data file).

The chemical structures of V1–3 were confirmed using FTIR spectroscopic analysis, which showed the following absorption bands: 3100–3650 cm−1 broad band centered at 3400 cm−1 corresponded to hydroxyl groups, two bands at 2920 and 2850 cm−1 corresponded to CH2 stretching, 1710 cm−1 corresponded to ester groups, 1610 cm−1 corresponded to azomethine groups, 1325 cm−1 corresponded to C–N groups, 1030 cm−1 corresponded to ether groups, and 870, 767, 735 and 693 cm−1 corresponded to phenyl groups (Fig. 1). Similarly, p-hydroxybenzaldehyde Schiff base derivatives (H1–3) showed the listed absorption bands.

Fig. 1
figure 1

IR spectra of V1 nonionic surfactant

Surface Activity of the Synthesized Compounds

Surface Tension and Critical Micelle Concentration

In an aqueous medium, surfactant molecules are adsorbed at the air–water interface such that the hydrophilic part is directed to the water phase and the hydrophobic part is located at the air–water interface. The adsorption of surfactant molecules at the air–water interface decreases the surface tension of the solution, and the gradual increase of the adsorbed surfactants is followed by gradual decrease in the surface tension. A marked decrease in the surface tension indicates that the surfactant molecules have great tendency towards adsorption at the air–water interface.

The surfactants under consideration are nonionic surfactants owing to the presence of nonionic PEG species, in addition to the huge number of hydroxyl groups attached to the phenyl groups, in their chemical structures as hydrophilic groups. Their chemical structure has no fully positively or negatively charged head groups. The hydrophobic groups are the organic part obtained from the reaction of vanillin or 4-hydroxybenzaldehyde with p-aminobenzoic acid. Figure 2 shows the variation of surface tension vs –log concentration relationships of the synthesized nonionic surfactants (V1–3) for H1–3 in their solutions (see additional data file). The relation showed two characteristic regions: the premicellar region in which the surface tension values decrease with increasing surfactant concentration and the postmicellar region in which the surface tension stays almost constant with increasing concentration of each surfactant [25]. Intersection of the two regions determines the concentration at which the micelles form (the critical micelle concentration, CMC) [26].

Fig. 2
figure 2

Surface tension versus minus log concentration of V1, V2, and V3 Schiff base nonionic surfactants at 25 °C

The PEG chain length has an important effect on the surface tension values of the surfactants in their solutions. Surfactant molecules with shorter PEG chains have lower surface tension values in the solutions compared to the surfactant molecules with longer PEG chains. Surfactants with longer PEG chains (V3 and H3) have the highest surface tension values. In contrast, surfactant molecules with PEG-400 (V1 and H1) have the lowest surface tension values (Fig. 2).

Surfactant molecules with shorter PEG chains (V1, H1) are rapidly and strongly adsorbed at the air–water interface. That is due to the hydrophobicity of their molecules. On the other hand, increasing the PEG chain length to 600 and 1500 g/mol (V2–3, H2–3) increases the surface tension values of the surfactant solutions considerably, compared to V1 and H1 surfactants. The surface tension–concentration profiles show that the surface tension values of the synthesized surfactants are relatively low compared to the conventional nonionic surfactants [27].

The CMC values of the synthesized nonionic surfactants were extracted from Fig. 2 and are listed in Table 1. They ranged between 2.15 and 2.71 mM for derivatives containing PEG-400 chains (V1, H1) and between 2.71 and 5.83 mM for derivatives containing PEG-1500 chains (V3, H3). The main factor influences the CMC values of these surfactants is the PEG chain length within similar series (H1–3 or V1–3). Increasing the PEG chain length from 400 to 600 g/mol has a noticeable influence on the CMC values. Surfactant molecules containing short PEG chains (V1, H1) are more hydrophobic than surfactant molecules with longer PEG chains (V3, H3), which are more hydrophilic [28]. The hydrophobicity of molecules with short PEG chains increases the adsorption of surfactant molecules at the air–water interface, which decreases the CMC values.

Table 1 Surface activity of the synthesized surfactants in their solutions at 25 °C

The side chains attached to the surfactant molecules have a considerable influence on the CMC values. 4-Hydroxybenzaldehyde interacts with the aqueous phase via the formation of two types of hydrogen bonds: the first involves the PEG chain and the second involves the hydroxyl groups of the benzaldehyde ring and tannic acid moiety. On the other hand, vanillin-derived nonionic surfactants have a third type of hydrogen bonding via the methoxy group on the vanillin moiety. As a result, the adsorption of vanillin-derived surfactants is expected to be planar on the aqueous phase (well-arranged molecules at the interface) compared with the 4-hydroxybenzaldehyde-derived surfactants which will be tilted as a result of the adsorption sites being located in one geometrical line (randomly arranged molecules at the interface). The well-arranged vanillin derivative increases its concentration at the interface. As a result, the surface concentration increases which decreases the CMC values (Table 1).

Surfactant molecules in the aqueous medium experience two balanced forces. The first is the repulsion exerted by the polar phase on the hydrophobic chains (due to the hydrophobic effect), and the second is the attraction between the water molecules and the partially charged nonionic chains and the hydroxyl groups of phenyl moieties (due to the hydrophilic effect). The former effect suppresses the adsorption of molecules at the air–water interface, whereas the latter effect increases the solubility of the surfactant molecules in the aqueous bulk via hydrogen bond formation between the water molecules and the electronegative oxygen atoms within PEG chains and hydroxyl groups. The effect of hydrophobicity of surfactant molecules in the solution is overcome by two ways. The first is the adsorption of more hydrophobic surfactant molecules at the air–water interface. The second is the aggregation of surfactant molecules in the bulk solutions to form micelles.

The γ cmc value is defined as the surface tension of the surfactant solution at the CMC [27]. γ cmc illustrates the surface activity of the surfactant solutions at the interface. This value determines the lowest surface tension value which can be achieved by the surfactant solution. Decreasing γ cmc values indicates the high surface activity of the surfactants in their solutions. The lowest γ cmc values were obtained with V1–2 and H1–2; furthermore, vanillin-derived surfactants (V1–3) have higher values than the corresponding 4-hydroxybenzaldehyde derivatives (H1–3) (Table 1). The depression in γ cmc values indicates the extent of surfactant molecules adsorbed at the solution interface.

Effectiveness (π cmc) and Efficiency (Pc 20)

The difference between the surface tension values of doubly distilled water and the surfactant solution at the CMC is defined as the effectiveness (π cmc). π cmc describes the depression in surface tension at surface saturation conditions [28]. π cmc is useful in comparing between surfactants which have similar head groups. Surfactants with higher π cmc values have a greater tendency to adsorb at the air–water interface than ones with lower π cmc values. Comparing π cmc values of V1–3 or H1–3 surfactants in Table 1 reveals that the sequence of surfactants towards adsorption at the interface is in the following order: V1 > V2 > V3 and H1 > H2 > H3.

The efficiency, Pc 20, describes the concentration of surfactant solution which reduces the surface tension of doubly distilled water by 20 mN/m. It is helpful in comparing between surfactants having different head groups. It is clear that the 4-hydroxybenzaldehyde derivatives (H1–3) are more pronounced in decreasing the surface tension than vanillin derivatives (V1–3). Based on π cmc and Pc 20 values, it can be reported that H1, H2, V1, and V2 surfactants have greater tendencies towards adsorption at the air–water interface than H3 and V3 surfactants.

Maximum Surface Concentration (Γ max)

The slope of the premicellar region in the surface tension–concentration profile is called the surface pressure. The surface pressure (∂γ/∂logC) determines the change in the surface tension of the surfactant solution with infinitesimal change in the surfactant concentration. Its value is a direct indication of the adsorption tendency of the surfactant molecules at the air–water interface. Increasing the surface pressure indicates the increasing of the surfactant molecules adsorption tendency at the air–water interface [24, 25, 29]. Data in Table 1 showed that V1, V2, H1, and H2 surfactants, respectively, have higher surface pressures than V3 and H3 surfactants. That reflects the higher tendency of V1, V2, H1, and H2 surfactants towards adsorption at the interface than V3, and H3 surfactants.

The surface pressure values can be used to calculate the maximum surfactant concentration Γ max of different surfactants at the interface of their solutions as follows [27]:

$$\varGamma_{\hbox{max} } = \, (\partial \gamma /\partial \log C)/\left( {2.303nRT} \right)$$

where Γ max is the maximum surface concentration at the saturation condition, n is the number of ionic species in the solution (n = 1 in case of nonionic surfactant), R is the universal gas constant, and T is the absolute temperature; the obtained results are listed in Table 1.

The maximum surface excess is the concentration of surfactant per unit area at the interface. The adsorption of surfactant molecules at the interface is calculated numerically in terms of concentration by Γ max. The values of Γ max in Table 1 vary over a narrow range within similar series and widely within different series. Within similar series, Γ max ranged between 4.39 × 10−10 and 5.93 × 10−10 mol/cm2 for V1–3 and ranged between 3.59 × 10−10 and 4.84 × 10−10 mol/cm2 for H1–3, which indicates the high adsorption tendency of the different surfactants at the interface. The higher surface concentration at the interface is related to the pumping of surfactant molecules to that interface. The adsorption of surfactant molecules at the air–water interface is decreased by increasing the hydrophilicity of the molecules and increased by increasing the hydrophobicity of the chains. On the other hand, higher surface concentration is related to the stability of the formed monolayer at this interface. Vanillin derivatives (V1–3) have lower surface pressure than H1–3 owing to the presence of methoxy groups in their structure. The presence of methoxy groups increases the attachment of V1–3 surfactant molecules to the aqueous phase, which decreases the adsorption of molecules at the interface. At the interface, the adsorbed monolayer of V1–3 surfactant molecules is compact owing to the overlapping between the polar groups in their chemical structure. That compactness is less pronounced in H1–3 surfactant molecules as a result of the presence of only hydroxy groups in their chemical structure. The difference in Γ max values listed in Table 1 is not pronounced, indicating the slight effect of the methoxy group on the adsorption of V1–3 at the interface relative to H1–3 surfactant molecules. The adsorption tendency of the surfactants at the interface increases their applicability in several interfacial applications including emulsification, foaming, wetting, and corrosion inhibition. The synthesized surfactants were expected to adsorb at the metal surface and act as corrosion inhibitors owing to the presence of the various polar groups in their chemical structure. In addition, the phenyl and azomethine groups in their chemical structures can form bonds with the metal surface by overlapping between the π electrons and the p electrons of the iron in carbon steel.

Minimum Surface Area (A min)

The average area occupied per surfactant molecule at the interface at saturation conditions (A min) was calculated using the following formula (N avog is Avogadro’s number) [29]:

$$A_{ \hbox{min} } = \, 1/(G_{ \hbox{max} } .N_{\text{avog}} )$$

Values listed in Table 1 indicate that the surfactant molecules are located in a semiplanar position at the interface [29]. Furthermore, increasing the PEG chain length has a minor effect on the A min values of the different surfactants. The influence of the vanillin and 4-hydroxybenzaldehyde moieties on A min values is more pronounced. Vanillin-derived surfactants V1–3 occupy a smaller area at the interface than the 4-hydroxybenzaldehyde-derived surfactants, H1–3. That can be simply related to the presence of the polar groups in the two moieties. The obtained values of A min were comparable to our previous work for nonionic surfactants based on tannic acid [30]. A min values of five substituted tannic acid nonionic surfactants were comparable to our values when considering one substituent on the tannic acid moiety.

Thermodynamic Properties of the Synthesized Surfactants

The standard free energy of micellization (ΔG mic) is the energy loss in the system due to the transfer of one mole of surfactant molecule to the bulk of the solution during the micellization process and can be calculated using the Gibbs equation as follows [29]:

$$\Delta G_{\text{mic}} = \, 2.303nRT\left( {\log {\text{ CMC}}} \right)$$

where R is the universal gas constant (8.314 kJ/mol) and T is the absolute temperature (K).

The adsorption free energy (ΔG ads) is the energy loss in the system due to the adsorption of surfactant molecules (1 mol) at the air–solution interface and is given using the following equation [29]:

$$\Delta G_{ads} =\Delta G_{mic} {-} \, (0.6 \times \pi_{cmc} \times A_{min} )$$

where ΔG mic is the standard free energy of micellization in kJ mol−1, π cmc is the effectiveness (mN/m), and A min is the average area occupied by a surfactant molecule at the solution interface (nm2).

The thermodynamics of adsorption and micellization processes of the synthesized surfactants were calculated according to the two aforementioned equations [29].

The thermodynamics of both adsorption and micellization processes determine the affinity of surfactant towards adsorption at the interface, or micellization in their solutions. The negative values of ΔG mic and ΔG ads indicate that the adsorption of surfactant molecules at the interface and the micellization in the bulk of the solution occurred spontaneously (Table 2). Furthermore, the narrow difference between these two values indicates the presence of equilibrium between the adsorbed molecules at the interface and the micellized molecules in the bulk. Data in Table 2 show that the free energies of adsorption are more negative than those of micellization. This provides evidence for the preferential tendency of the prepared surfactants towards adsorption at the air–water interface than micellization in the bulk of their solutions (i.e., the predominance of adsorption process over micellization). The thermodynamic evaluation of the adsorption and micellization processes of the different surfactants was performed according to the standard free energies (ΔG ads and ΔG mic) of these two processes, respectively [22].

Table 2 Emulsification, interfacial properties, and thermodynamic parameters of V1–3 and H1–3 surfactants in their solutions at 25 °C

Emulsion Stability

Emulsion formation technology is very important in several applications, especially in cosmetics, drug formulations, and paints. The emulsification by surfactants is one of the most important surface properties at the interface. The emulsification tendency in some cases is important for the formation of stable emulsions, e.g., in solubilization, emulsification processes, cosmetics and drug formulations; whereas, in some applications emulsification is not favorable, e.g., especially in petroleum applications including demulsification and corrosion inhibition. The emulsification powers of the synthesized surfactants were determined as the time required to break down the emulsion formed between surfactant solution and paraffin oil. Table 2 lists the emulsification properties of the synthesized surfactants in the presence of light paraffin oil. The stability of the oil–water emulsions are mainly dependent on the chemical structure of the emulsifier used (surfactant), pH of the medium, and the temperature. The emulsification powers of the surfactants are dependent on the nonionic chain length. The synthesized surfactants showed different responses towards the emulsion stabilization. Surfactants containing short PEG chains (H1 and V1) exhibit moderate emulsion stability ranging between 70.25 and 37.25 min. Surfactants containing longer PEG chains (H2 and V2) exhibit considerably lower emulsion stability of between 2.40 and 3.15 min. The lowest stability of the formed emulsions was obtained in presence of H3 and V3 surfactants. The relatively low stability of emulsion formed using H1–3 and V1–3 was comparable to the emulsions formed by conventional nonionic surfactants, e.g., Tween-20 or Tween-40 [29], which provide stable emulsions for more than 2 days. That behavior predicts the applicability of these surfactants as corrosion inhibitors in oil fields owing to the lack of risk of stable emulsion formation, which is undesirable in the chemicals used there.

Interfacial Tension

Interfacial tension is a property that determines the ability of compounds to locate at the interface between the oil and the water phase. The driving force of surfactant molecules to adsorb at the interface (boundary surfaces) is to decrease the free energy at these boundaries. That decrease can be observed from the interfacial energy values. Interfacial tension is expressed instead of interfacial free energy per unit area. The tendency of surfactant molecules towards accumulation at the interfaces is a unique property of surfactants [31]. The interfacial tension values of the synthesized surfactants (H1–3, V1–3) ranged between 22 and 26 mN/m at 25 °C. The relatively high values of the synthesized surfactants compared to Tween-20 or Tween-40 (12, 9 mN/m) indicate their low tendency to locate at the oil phase. This phenomenon is suitable when evaluating these surfactants in oil and water environments, e.g., corrosion inhibition of petroleum equipment [13, 14, 16]. The presence of water and oil in the same environment risks the formation of stable emulsion when the interfacial tension values of the surfactants are low. In the case of the synthesized surfactants, there is no risk of stable emulsion formation when these compounds are used in different applications. Increasing the hydrophilic chain length (PEG chains) from 9 to 34 units decreases the interfacial tension of vanillin derivatives V1–3 from 26 to 22 mN/m, whereas in the case of H1–3, the interfacial tension values decreased from 26 to 23 mN/m at 25 °C (Table 2).

Corrosion Inhibition Evaluation

Potentiodynamic Polarization Spectroscopy

The current–potential relationship (cathodic and anodic) for carbon steel corrosion in 1 N H2SO4 in the presence of 5000–500 ppm by weight of V1–3 inhibitors at 25 °C is shown in Fig. 3 for H1–3 (see additional data file). The electrochemical polarization parameters of cathodic and anodic Tafel slopes (β c, β a), corrosion current density (i corr), potential of corrosion (E corr), and inhibition efficiency (η%) obtained from this figure are listed in Table 3. The potential of corrosion of the unprotected carbon steel was −492.9 mV compared with the saturated calomel electrode, while the corrosion current recorded a very high value of 1.991 mV. That indicates the high corrosion extent of the carbon steel in the acidic medium with high tendency towards cathodic polarization at 201.5 mV compared to the saturated calomel electrode. The corrosion potential of the carbon steel in the presence of the different inhibitors increased, indicating the protection of the metal surface as a result of the presence of the inhibitors in the medium. The corrosion currents were decreased considerably by the addition of the inhibitors to lower values of 0.208, 0.190, 0.179, 0.297, 0.358, and 0.318 mA cm−2 at 5000 ppm by weight of V1–3 and H1–3, respectively. The values of the corrosion currents were used to determine the surface coverage (θ) of the carbon steel by the inhibitor molecules using the following equation [32]:

$$\theta = \, \left( {i_{\text{corr(uninh)}} - i_{\text{corr(inh)}} } \right)/\left( {i_{\text{corr(uninh)}} } \right)$$

where i corr(uninh) and i corr(inh) are the corrosion current densities in the presence and absence of the different inhibitors. These values were used to determine the corrosion inhibition efficiencies of the different inhibitors at 400 ppm according the following equation [4]:

$$n\% = \, \left[ {\left( {i_{\text{corr(uninh)}} - i_{\text{corr(inh)}} } \right) /\left( {i_{\text{corr(uninh)}} } \right)} \right] \, \times \, 100$$
Fig. 3
figure 3

Polarization curves of carbon steel in the presence of 5000–500 ppm by weight of V1 nonionic surfactant at 25 °C

Table 3 Electrochemical polarization parameters of carbon steel corrosion in the presence of different concentrations of V1–3 and H1–3 nonionic surfactants

At 5000 ppm by weight, the values of i corr in the case of V3 and H3 (0.179, 0.318 mA cm−2) are smaller than those of V1–2 and H1–2 (Table 3). V3 and H3 thus exhibit higher inhibition efficiencies (91.0, 84.3 %) than the other inhibitors in 1 N H2SO4 at 25 °C. It is apparent from the polarization profile that both anodic and cathodic corrosion reactions of carbon steel electrode were inhibited after the addition of the different inhibitors to the acidic solution. Furthermore, the inhibition became more noticeable by increasing the inhibitor concentration from 500 to 5000 ppm by weight. This behavior indicates that the addition of the inhibitors lessens the anodic dissolution of iron and also retards the reduction of hydrogen ions (hydrogen evolution) [32]. The cathodic current–potential curves (Fig. 3) gave rise to parallel lines indicating that the presence of inhibitors did not alter the hydrogen evolution mechanism and the reduction of H+ ions at the carbon steel surface takes place mainly through a charge transfer mechanism [33]. The cathodic current densities decreased dramatically by increasing the inhibitor concentrations, which reveals that the addition of the inhibitors does not change the cathodic hydrogen evolution mechanism. The suppression of the cathodic process can be attributed to the covering of inhibitor monolayer on the cathodic sites of the carbon steel [3436]. In the initial stage of the anodic polarization, the corrosion current densities increased slowly and the anodic polarization was enhanced predominantly with the polarization potential shifting positively. That shows the adsorption rate is higher than the desorption rate of the inhibitor molecules on carbon steel surface, and the adsorption process controls the anodic reaction [37]. The polarization behavior showed similar appearance, which implies that the inhibitor molecules are thoroughly adsorbed from the solution to the carbon steel surface and their inhibition effect is increased by increasing the concentration [9, 38]. Increasing of inhibitor concentration results in a reduction in the corrosion current densities and an increase in η%, which suggests that the protective film adsorbed on the metal surface tends to be more complete at higher inhibitor concentrations. Furthermore, increasing the number of ethylene glycol units in the inhibitors decreased the corrosion current density (i corr) considerably. The inhibition efficiencies increased by increasing the polymerization extent in the following order: V3 > V2 > V1 > H3 > H2 > H1. The inhibitors are classified as cathodic or anodic type when there is a shift in corrosion potential higher than 85 mV compared to the corrosion potential in the absence of inhibitors [9]. However, the displacement of E corr is less than 85 mV for all the studied inhibitors. Therefore, these inhibitors can be classified as mixed-type inhibitors [39, 40]. Mixed-type inhibitors retard both cathodic and anodic reactions of the corrosion process. Moreover, the values of the anodic and cathodic Tafel slopes showed no obvious changes with the addition of the inhibitors. That suggests the adsorption of inhibitor molecules occurs first on the carbon steel surface. This then successively hinders the corrosion process by blocking the reactive sites on the carbon steel surface without changing the corrosion reaction mechanism [4, 22, 41]. The surface coverage values showed an increasing trend with increasing the inhibitor concentration from 500 to 5000 ppm by weight (Table 3). That causes an increase in the adsorbed inhibitor molecules on the metal surface, which increases the inhibition efficiencies of the inhibitors. Increasing the inhibition efficiencies accompanied by increasing the inhibitors concentration can be attributed to the increase of the adsorbed layer thickness [41].

Electrochemical Impedance Spectroscopy (EIS)

Electrochemical impedance spectroscopy (EIS) measurements were used to study the corrosion behaviors of carbon steel in 1 N H2SO4 solution in the absence and the presence of 500–5000 ppm by weight of V1–3 and H1–3 inhibitors (Fig. 4). The charge transfer resistance (R ct) values were calculated on the basis of the differences between impedance values at higher and lower frequencies as follows [40]:

$$C_{\text{dl}} = 1/\omega R_{ct} ,\quad \omega = \, 2\pi f_{\hbox{max} }$$

where ω is the angular frequency (in rad/s) and f max is the maximum frequency.

Fig. 4
figure 4

Electrochemical impedance curves of carbon steel in the presence of 5000–500 ppm by weight of V1 nonionic surfactant at 25 °C

The recorded EIS spectrum for carbon steel in 1 N H2SO4 at 25 °C in the absence and in the presence of 500–5000 ppm by weight of V1–3 and H1–3 nonionic surfactants showed one depressed capacitive loop (illustrated for V1 in Fig. 4). The depressed semicircle with the center under the real axis is attributed to the roughness and inhomogeneities of the metal surface [4244]. Inspection of Fig. 4 reveals that the addition of the inhibitors increases the capacitive loop diameter without affecting their characteristic features. This indicates the strengthening of the formed inhibitive film which is responsible for the inhibition action of these inhibitors. The protective film is formed as a result of adsorption of inhibitor molecules on the carbon steel surface without changing the mechanism of the corrosion process [27]. In fact, the presence of inhibitors enhances the value of the transfer resistance in the acidic solutions [32]. The EIS study confirms that the tested inhibitors are efficient as corrosion-retarding compounds. Table 4 lists the impedance parameters derived from the ESI measurements and shows that the values of R ct increase with increasing inhibitor concentration. This behavior is attributed to the adsorption of V1–3 or H1–3 molecules on the carbon steel surface, which resulted in increasing their corrosion inhibition efficiency in the acidic solution [34]. The impedance diagram showed that the corrosion of carbon steel is mostly controlled by the charge transfer process. The double-layer capacitance, C dl, decreased in the presence of the studied inhibitors. This decrease is due to the increase in the thickness of the electrical double layer and/or the reduction of local dielectric constant, which suggests that the inhibitors achieve their action by the adsorption on the metal–solution interface [45]. Thus, the change in C dl values is due to the gradual replacement of adsorbed water molecules on the carbon steel surface by the inhibitor molecules and consequently decreases the dissolution process of the metal [4648]. The adsorption of these inhibitors on the metal surface includes overlapping between the PEG chains and the positive centers on the metal surface via chemical and/or physical attraction.

Table 4 Electrochemical impedance parameters of carbon steel corrosion in the presence of different concentrations of V1–3 and H1–3 nonionic surfactants

Synthesized Inhibitors Versus Commercial Nonionic Corrosion Inhibitors

Water-soluble nonionic Rosen surfactants (cheap commercial corrosion inhibitors) showed inhibition efficiency against corrosion of carbon steel in 1 N HCl in the range of 73–88 % at high concentrations [49]. Commercial nonionic ethoxylated fatty acid surfactants Co(EO) n (n = 20, 40, and 80) [50] were evaluated as corrosion inhibitors using low carbon mild steel at 25 °C in 0.25 M H2SO4. The efficiencies of these inhibitors ranged between 85 and 90 %. Tween is one of the most common commercial nonionic surfactants which can be used as a corrosion inhibitor. Tween 80, 60, 40, and 20 were tested as inhibitors for corrosion of nickel in 1 M H2SO4 solution [51]. The efficiencies varied depending on the PEG chain length in the range of 89.54–94.36 %. Polysorbate is another type of sugar-based nonionic surfactant used as a corrosion inhibitor. The corrosion inhibition efficiencies of polysobates [52] in HCl medium ranged from 83 to 88 %. Overviewing the obtained corrosion inhibition efficiencies of the synthesized inhibitors in Table 3 revealed that the average efficiencies ranged between 60 and 71.8 % at low concentrations. At higher concentrations, the efficiencies ranged between 98.5 and 91 %. Comparison between the corrosion inhibition efficiencies of the synthesized nonionic surfactants V1–3 and H1–3 and the commercial nonionic corrosion inhibitors showed the satisfactory performance of the former as corrosion inhibitors in acidic media.

Conclusion

The study revealed several points:

  1. 1.

    The surface activities of the synthesized nonionic surfactants depend on their chemical structures.

  2. 2.

    The synthesized surfactants have low emulsification tendency.

  3. 3.

    Thermodynamic data showed that the surfactants tend to adsorb at the solution interface and micellize in bulk of solution spontaneously.

  4. 4.

    Polarization and impedance measurements showed the high efficiency of the synthesized surfactants in acidic medium.

  5. 5.

    The synthesized surfactants exhibit comparable inhibition to commercial nonionic inhibitors.