1 Introduction

Martensitic stainless steels are commonly used in oil and gas industry. They possess good mechanical and corrosion resistance properties with lower production costs compared to duplex stainless steels [1]. These high-performance attributes allow them to be used in a large range of conditions including severe environments. In some cases, however, martensitic stainless steels such as EN 1.4542, also known as 17-4 PH, present failure in service [2]. These failures are, as expected, dependent on the environment aggressiveness. For instance, the EN 1.4418 grade presents a well-defined and protective passive behavior in sour media with pH value larger than 4 [3,4,5,6,7,8]. On the other hand, at lower pH, passivity is hindered, corrosion products are formed and failures can occur. The use of organic corrosion inhibitors is a common practice for fighting corrosion due to their ability to form coordinate covalent bonds with underlying metal [9, 10]. However, due to serious environmental concerns, viability, price, toxicity, etc., there has been a lot of research on the use of the naturally occurring compounds obtained from plant seeds, roots or flowers, which are called “green inhibitors” [11,12,13,14,15,16,17,18]. In particular, compounds synthesized from the fatty acids contained in different seeds have also been subject of research since compounds with good corrosion inhibition properties have been discovered [19,20,21]. For instance, an amide type of corrosion inhibitor extracted from the fatty acids contained in the coffee bagasse was used for the corrosion inhibition of Cu in 3% NaCl solution obtaining corrosion efficiency values as high as 95% which increased with its concentration but decreased with the testing temperature [20]. In another research work, Salinas-Solano obtained an imidazoline from the fatty oils contained in the wasted rice bran to be used as CO2-corrosion inhibitor for 1018 carbon steel, resulting in its efficiency increasing with its concentration up to 5 ppm of inhibitor and decreasing with a further increase in the inhibitor concentration [21]. In this sense, the goal of this research work is to evaluate a nonionic Gemini surfactant extracted from the fatty oil contained in the palm oil to be used as corrosion inhibitor for a supermartensitic stainless steel exposed to an H2S-containing environment under hydrodynamic conditions.

2 Experimental Procedure

2.1 Testing Material

Material evaluated in this research work includes a UNS S41425-type supermartensitic stainless steel containing 13.5 wt% Cr, 4.7 Ni, 1.7 Mo, 0.75 Mn, 0.3 Si, 0.02 C, 0.0003 S, 0.016 P, 0.07 Cu and 0.07 N. Coupon bars having 6.00 mm in diameter were encapsulated in a polymeric resin and abraded with 600 grade emery paper, washed and rinsed with acetone, and used as working electrodes in a rotating disc electrode. The tests were carried out at rotating speeds of 0, 100, 500, 1000 and 2000 rpm as given in Table 1. As can be seen from Table 1, the type of flux is laminar at 0 and 100 rpm, but it is turbulent at rotating speeds of 500, 1000 and 2000 rpm.

Table 1 Effect of rotating speed on the Reynolds number, shear stress and type of flux

2.2 Testing Solution

As corrosive environment, a 5.0 wt% NaCl (99%) + 2.5% Acetic acid (99%) + 10−6 M sodium thiosulphate (Na2S2O3)(99%) from Sigma Aldrich at 50 °C was used as recommended elsewhere [22,23,24,25,26]. For this, a solution containing 500 ml of water + 25 g NaCl + 2.5 g Acetic acid was prepared; after this, nitrogen gas was bubbled during one hour and then 0.079 g Na2S2O3 was added as given in [23, 24]. According to [25], S2O32− is reduced to H2S by the electrons coming from the oxidation of the steel. The synthesis of Gemini surfactants from palm oil was performed in two steps as showed in Fig. 1. Both reagents, 4,5-Imidazoledicarboxylic acid (99%) and N-(2-hydroxyethyl) aminoethylamine (98%) were purchased from Sigma Aldrich. The palm oil used was industrial-grade Olefins, 99%. The toluene solvent, 99%, was acquired from Meyer. First, the palm oil was transformed in fatty amide through the aminolysis direct of oil. The mixture of fatty amides was washed with brine and the fatty solid was dried in vacuum. In the second step, the fatty amide (2 mol) was condensed with 4, 5-Imidazoledicarboxylic acid (1 mol), in toluene (seven parts) at reflux. Employed doses were 0, 5, 10, 25, 50 and 100 ppm.

Fig. 1
figure 1

Synthesis of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate. R = alkyl chains of fatty acids contained in palm oil

2.3 Electrochemical Techniques

Employed electrochemical techniques in this work include potentiodynamic polarization curves, linear polarization resistance (LPR) and electrochemical impedance spectroscopy (EIS) measurements. For this purpose, an electrochemical cell made out of glass with three electrodes was used. As reference, a saturated calomel electrode (SCE) was used, while as auxiliary electrode, a graphite rode was chosen. Before starting the experiments, the open circuit potential value (OCP) was monitored and waited until it reached a steady-state value, normally 60 min. For polarization curves, specimen was catholically polarized 1000 mV with respect to the free corrosion potential value, Ecorr, and scanning started towards the anodic direction at a sweep rate of 60 mV/min, and it ended in a potential value 1000 mV more anodic than Ecorr. Corrosion current density values, Icorr, were calculated by using Tafel extrapolation. For the LPR experiments, specimens were polarized ± 15 mV around Ecorr at a sweep rate of 60 mV/min every 60 min during 24 h. Finally, for the EIS tests, these were done at the Ecorr value and applying a signal of ± 15 mV peak-to-peak in a frequency interval between 0.05 and 20,000 Hz. Corroded specimens were observed in a scanning electronic microscope, whereas microchemical analysis was performed with an X-ray energy dispersive (EDS) analyzer.

3 Results and Discussion

3.1 Static Conditions

Polarization curves for UNS S41425-type supermartensitic stainless steel in the H2S-containing solution with different concentrations of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate is given in Fig. 2. In absence of inhibitor, polarization curve describe an active–passive behavior, where the anodic current density increases as the anodic potential increases, until it reaches a critical value and remains more or less constant for potential values between − 300 and − 200 mV were it suddenly decreases and a passive zone is formed. As soon as the inhibitor was added, the Ecorr value shifted in the noble direction for approximately 100 mV, remaining more or less constant regardless of the inhibitor concentration; additionally, the anodic current density decreased, reaching its lowest value in an inhibitor concentration of 25 ppm, as can be seen in Table 2. In this table, inhibitor efficiency value, I.E., was calculated by using the following expression:

$${\text{I.E.}} = \frac{{I_{{{\text{corr}}}} - I_{{\text{corr/inh}}} }}{{I_{{{\text{corr}}}} }} \times 100,$$
(1)
Fig. 2
figure 2

Effect of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate concentration in the polarization curves for UNS S41425-type supermartensitic stainless steel in an H2S-containing 5% NaCl solution at 50 °C under stagnant conditions

Table 2 Electrochemical parameters obtained from polarization curves under stagnant conditions

where Icorr and Icorr/inh are the corrosion current density values obtained in the absence and presence of the inhibitor, respectively. On the other hand, the steel surface area covered by the inhibitor, θ, was calculated by dividing the inhibitor efficiency by 100. In the presence of the inhibitor, the steel displayed an active–passive behavior, and the passivation current density was decreased as the inhibitor concentration increased, reaching its lowest value when 50 ppm of inhibitor was added. From Table 2, it can be seen that both inhibitor efficiency and θ reached their maximum values with the application of 25 ppm of inhibitor, which indicates that the decrease in the Icorr value is due to the inhibitor adsorption onto the steel surface. Cathodic current density, which is mainly due to hydrogen evolution reaction, is also decreased by the presence of inhibitor. Both anodic and cathodic Tafel slopes were affected, but in a more significant manner the cathodic one, indicating that this inhibitor affected both anodic steel dissolution and cathodic reactions.

When iron and steel are corroded in an H2S-containing environment, anodic dissolution of iron is enhanced by the presence of H2S, where sulfur maintains the steel metal in the active state or stimulates the breakdown of the passive film by chloride, with the formation of corrosion product such as iron sulfide, FeS; however, there are many different kinds of iron sulfide compounds with different corrosion properties, and it has been suggested that, depending upon the environmental features, these corrosion products can have a similar effect to that of the passive films formed on top of stainless steels, decreasing the corrosion rate [27, 28]. Due to the presence of other alloying elements such as Cr, Mn and Ni, it is expected to have some nickel, manganese and chromium sulfides in addition to iron sulfide. However, chromium sulfides are thermodynamically unstable [28], and instead of chromium sulfides, a layer of chromic oxide is expected, which might be the responsible for the passive behavior [29, 30]. Additionally, when pure chromium was tested in H2S-containing environment, it was found that H2S cannot break down the passive layer formed on top of pure Cr [31]. When the inhibitor is added, iron ions can react with it to form protective films capable of reducing the corrosion rate of underlying metal as observed in the polarization curves shown in Fig. 1.

Nyquist diagrams for UNS S41425-type supermartensitic stainless steel in the H2S-containing solution with different concentrations of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate are given in Fig. 3. It can be seen that, regardless of the inhibitor concentration, data display a single capacitive semicircle at all frequency values, indicating that the corrosion mechanism remained unchanged with the presence of the inhibitor. Semicircle diameter increased with the inhibitor concentration, reaching it highest value with additions of 25 and 50 ppm, and it decreased when the inhibitor increased up to 100 ppm. The semicircle diameter is associated to the charge transfer resistance value, Rct, which, according to the Stern–Geary equation, is inversely proportional to the Icorr value. Thus, the largest Rct value, and thus the lowest corrosion current density value, was found when 25 ppm and 50 ppm of inhibitor were injected into the system. This way, when tests were performed at different rotating speeds, the inhibitor dosses employed was 25 ppm, since it was found, in both polarization and EIS experiments to be the optimum inhibitor concentration.

Fig. 3
figure 3

Effect of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate concentration in the Nyquist diagrams for UNS S41425-type supermartensitic stainless steel in an H2S-containing 5% NaCl solution at 50 °C under stagnant conditions

3.2 Hydrodynamic Conditions

The effect of rotating speed in the open circuit potential value (OCP) with time for UNS S41425-type supermartensitic stainless steel in the uninhibited H2S-containing solution is given in Fig. 4. This figure shows that under static conditions, the OCP value shifted towards more active values as time elapsed, due to a dissolution of any protective film formed on top of the steel. Under dynamic conditions, regardless of the rotating speed, the OCP value shifted monotonically towards nobler values, reaching steady-state values much nobler than those obtained under static conditions, which is due to the formation of a protective corrosion product film. In the presence of 25 ppm of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate, Fig. 5, regardless of the rotating speed, after an initial shift towards more active values, which is more evident under stagnant conditions, the OCP value went in the noble direction, which is due to the formation of protective corrosion products formed by metal ions and the inhibitor. The initial shift towards the active direction is due to the dissolution of any pre-existing film.

Fig. 4
figure 4

Effect of rotating speed in the OCP value UNS S41425-type supermartensitic stainless steel in an uninhibited H2S-containing 5% NaCl solution at 50 °C

Fig. 5
figure 5

Effect of rotating speed in the OCP value UNS S41425-type supermartensitic stainless steel in an H2S-containing 5% NaCl solution at 50 °C containing 25 ppm of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate

The effects of rotating speed on the polarization curves for UNS S41425-type supermartensitic stainless steel in the H2S-containing solution with 0 and 25 ppm of inhibitor are given in Figs. 6 and 7, respectively. Electrochemical parameters obtained from these curves such as Ecorr and Icorr values are given in Table 3. For the uninhibited solution, it is very clear that the presence of a passive layer formed on top of the steel was displayed regardless of the rotating speed, which indicates that this layer is strongly adhered to the steel surface. The Ecorr value shifted towards nobler values under hydrodynamic conditions increased and remained close to a constant value regardless of the rotating speed as shown in Table 3; however, the Icorr and passivating current density values increased as the rotating speed increased. This is because reactants from the bulk solution are moved faster towards the steel metal. Anodic dissolution of iron in an H2S-containing environment includes the diffusion of H2S from the bulk solution towards the metal to form iron sulfide, FeS, which dissolves in Fe(HS)+ and HS with the final departure of Fe(HS)+ from the steel substrate. As the rotating speed increases, the mass transfer of the above given species is enhanced, thus enhancing the metal dissolution reaction. In fact, on the cathodic branch of the curve, a limit current density, ILIM, is found, and it increased with the rotating speed.

Fig. 6
figure 6

Effect of rotating speed in the polarization curves of UNS S41425-type supermartensitic stainless steel in an uninhibited H2S-containing 5% NaCl solution

Fig. 7
figure 7

Effect of rotating speed in the polarization curves of UNS S41425-type supermartensitic stainless steel in an H2S-containing 5% NaCl solution at 50 °C containing 25 ppm of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate

Table 3 Effect of rotating speed in the Ecorr and Icorr values in the absence and presence of 25 ppm of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate

On the other hand, in the presence of the inhibitor, Fig. 7, a similar behavior to that observed in the absence of the inhibitor is observed, since the steel displayed an active–passive behavior regardless of the rotating speed. The Ecorr value was practically unaffected; however, the Icorr and passivating current density values increased as the rotating speed increases, see Table 3. On the cathodic branch, a limit current density value was not found. In fact, for a rotating cylinder electrode, the relationship between ILIM and the rotating speed is given by

$$I_{{{\text{Lim}}}} = 0.0791n{\text{F}}Cd^{ - 0.3} \nu^{ - 0.344} D^{0.644} u^{0.7},$$
(2)

where n is the number of involved electrons in the reaction, F the Faraday´s constant, C the concentration of involved species, d the diameter of the rotating cylinder electrode, \(\nu\) the fluid kinematic viscosity, D the diffusion coefficient and u the electrode peripheral velocity. As shown in Fig. 8, a straight line is obtained in a plot of ILIM versus u0.7 for the uninhibited solution, indicating a diffusion controlled corrosion process on these conditions. In this case, the protective layer is formed between by the inhibitor, to form a layer of corrosion products which is adsorbed on top of the steel according to the following reaction:

$${\text{Inh}}_{{\left( {{\text{sol}}} \right)}} + {\text{H}}_{2} {\text{O}}_{{\left( {{\text{ads}}} \right)}} \leftrightarrow {\text{Inh}}_{{\left( {{\text{ads}}} \right)}} + {\text{H}}_{2} {\text{O}}_{{\left( {{\text{sol}}} \right)}},$$
(3)
Fig. 8
figure 8

Variation of the cathodic limit current density (ILim) as a function of the peripheral electrode velocity (u) to the power 0.7 for uninhibited solution

where Inh(sol) and Inh(ads) are the inhibitor added in the aqueous solution and adsorbed on the metal surface, respectively. As the rotating speed increases, the mass transfer of Inh(sol) is enhanced, with a decrease in the corrosion rate, but the adsorbed inhibitor on the metal surface, Inh(ads), can be detached away from the steel substrate also, with an increase in the corrosion rate. The later effect, i.e., the detachment of the adsorbed film onto the steel, seems to explain the increase in the corrosion and passivating current density values with an increase in the rotating speed.

The variation of the polarization resistance value, Rp, with time UNS S41425-type supermartensitic stainless steel in the uninhibited H2S-containing solution is shown in Fig. 9. In all cases, regardless of the rotating speed, the Rp values decrease as time elapses. Since the Rp and Icorr values are inversely proportional, a decrease in Rp indicates an increase in Icorr and thus, the increase in the rotating speed brings an increase in the corrosion rate due to an enhancement on the reactant mass transfer as explained above. On the other hand, for inhibited solution, Fig. 10, the Rp value under stagnant conditions increases as time elapses, reaching a maximum value and decreasing after this time. The increase in the Rp value is due to an increase of the metal surface area covered by the inhibitor formed film, as shown by the θ value in Table 2, whereas its decrease is due to a detachment of this film from the steel surface. On the other hand, as the rotating speed increased, the Rp value decreased as compared to that value obtained under stagnant conditions. This is, as explained above, due to a detachment of the inhibitor formed film by the high shear stresses developed at high rotating speed values, as shown in Table 2 and also due to the reactants increased mass transfer as the inhibitor efficiency is not 100%.

Fig. 9
figure 9

Effect of rotating speed in the Rp value for UNS S41425-type supermartensitic stainless steel in an uninhibited H2S-containing 5% NaCl solution at 50 °C

Fig. 10
figure 10

Effect of rotating speed in the Rp value for UNS S41425-type supermartensitic stainless steel in an H2S-containing 5% NaCl solution at 50 °C containing 25 ppm of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate

The effect of rotating speed on the EIS data for UNS S41425-type supermartensitic stainless steel in the uninhibited H2S-containing solution is shown in Fig. 11 Nyquist data under stagnant conditions, Fig. 10a, describe a single capacitive-like semicircle, with its center in the real axis at all frequency values, indicating a corrosion control by the charge transfer from the metal to the solution through the double electrochemical layer. Very similar results were reported for 18 Ni 300 grade maraging steel exposed to a 0.6 M NaCl solution containing 1 mmol−1 H2S and saturated with CO2 gas [32]. However, when the rotating speed increased, Nyquist data displayed a capacitive-like semicircle at high and intermediate frequency values followed by a straight line at lower frequencies, indicating that the corrosion process is under a mixed transfer control, i.e., under charge transfer and mass transfer control mechanism [33]. Similar results were reported by Arzola when API X-70 pipeline steel was exposed to a 3% NaCl solution containing 100, 650 and 2500 ppm of H2S at 20 °C [34]. Additionally, similar results were reported for pure iron exposed to a H2S-saturated 3.5% NaCl solution at 24 °C [35]. As explained above, this mass transfer process involves the diffusion of H2S from the bulk solution towards the metal to form iron sulfide, FeS, which dissolves in Fe(HS)+ and HS with the final departure of Fe(HS)+ from the steel surface. The capacitive semicircle diameter under hydrodynamic conditions, Rct, was marginally affected by the rotating speed and was lower than that obtained under stagnant conditions, indicating an increase in the corrosion rate when the rotating speed increased. Bode diagrams, on the other hand, Fig. 10b, shows a decrease in the modulus as the rotating speed increases, whereas the phase angle data indicate the presence of one peak only, and thus, only one time constant, with the phase angle decreasing as the rotating speed increases.

Fig. 11
figure 11

Effect of rotating speed in the a Nyquist and b Bode diagrams for UNS S41425-type supermartensitic stainless steel in an uninhibited H2S-containing 5% NaCl solution at 50 °C

Nyquist and Bode diagrams at different rotating speeds for UNS S41425-type supermartensitic stainless steel in the H2S-containing solution containing 25 ppm of inhibitor are shown in Fig. 12. It can be seen from this figure that Nyquist diagram displays, regardless of the rotating speed, one single capacitive like at all frequency values, indicating a single corrosion mechanism at all rotating speeds, Fig. 12a. The semicircle diameter decreased as the rotating speed increased, with an increase in the rotating speed. On the other hand, Bode diagrams in the impedance mode, Fig. 12b, show a decrease in the impedance value as the rotating speed increases. The phase angle diagrams show the presence of two peaks, and thus, two time constants, which correspond to the double electrochemical layer and to the film-formed inhibitor, respectively; the phase angle reached its maximum value under stagnant conditions, and it decreased with an increase in the rotating speed. It is a common practice for the use of electric circuits as those shown in Fig. 13 to represent the redox process that is occurring during a corrosion process [33]. In these circuits, Rs represents the resistance of the solution, Rct, the resistance of the double electrochemical layer or charge transfer resistance, Cdl its capacitance, Rf the corrosion product film resistance, Cf its capacitance and W a Warburg element, taking into account the diffusion or mass transfer process, where the diffusion layer has a resistance given by Rw. In practice, semicircles as those shown in Figs. 11 and 12 are far from perfect, and they are depressed due to imperfections at the metal surfaces such as scratches and surface roughness and ideal capacitances are replaced by constant phase elements, CPE, taking these effects into account [36, 37]. The impedance, Z, of a CPE is given by

$$Z_{{{\text{CPE}}}} = \frac{1}{{Y_{0} \left( {j\omega } \right)^{n} }},$$
(4)
Fig. 12
figure 12

Effect of rotating speed in the a Nyquist and b Bode diagrams for UNS S41425-type supermartensitic stainless steel in an H2S-containing 5% NaCl solution at 50 °C containing 25 ppm of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate

Fig. 13
figure 13

Electric circuits used to fit EIS data for UNS S41425-type supermartensitic stainless steel in an H2S-containing 5% NaCl solution at 50 °C containing a 0 ppm of inhibitor at 0 rpm, b 0 ppm of inhibitor at different rotating speeds, and c 25 ppm of inhibitor at different rotating speeds

where Y0 is the magnitude of the CPE or admittance, \(j\) is the imaginary unit, \(\upomega\) is the angular frequency (\(\omega =2\uppi f\), where \(f\) is the AC frequency), and n is the CPE exponent which provides some surface parameters such as roughness [36].

Parameters used to fit the EIS data in both uninhibited and inhibited solution are given in Tables 4 and 5, respectively. In the uninhibited solution, Table 4, the effect of a diffusion controlled process is observed under hydrodynamic conditions by the existence of a diffusion layer with a resistance given by Rw with a value which remained virtually unaffected by the rotating speed, oscillating within 42 and 50 Ω cm−2. The charge transfer resistance value, Rct, however, decreased with the rotating speed, with an increase in the corrosion rate, whereas the admittance value for the double layer, Ydl, increased. In the inhibited solution, Table 5, the resistance values of the film formed on top of steel were higher than the charge transfer resistance values, indicating that the corrosion resistance of the steel is given by the film formed in the presence of the inhibitor. The sum of all the resistance values across the metal/electrolyte interface, Rf, Rct, and Rs, gives the polarization resistance value, Rp, which is inversely proportional to the Icorr value through the Stern–Geary equation. It can be seen from Table 5 that both Rf and Rct values decrease with an increase in the rotating speed, bringing an increase in the corrosion rate, due to the detachment of the protective film formed by the inhibitor from the steel surface.

Table 4 Electrochemical parameters to fit EIS data in the uninhibited solution
Table 5 Electrochemical parameters to fit EIS data in the solution containing 25 ppm of bis(2-((2-palmitoamidoetil) amino) etil) 1H-imidazol-4,5-dicarboxilate

Micrographs of UNS S41425-type supermartensitic stainless steel in the H2S-containing solution containing 0 and 25 ppm of inhibitor under stagnant conditions are shown in Fig. 14, whereas microchemical analysis of the corrosion product layer is given in Table 6. It can be seen that in both cases there is a thick porous, cracked, layer of corrosion products. The layer of corrosion products formed on top of steel corroded in the uninhibited solution contains a big amount of microporous and cracks, places which form paths for the surrounding corrosive electrolyte penetrates and corrode the underlying metal. On the other hand, the film formed on top of the steel corroded in the presence of inhibitor is much more compact than that formed in the uninhibited solution, without evidence of microporous. However, the presence of cracks is still evident, which form paths for the electrolyte to penetrate and corrode the underlying metal, explaining why the inhibitor efficiency is lower than 100%. Chemical analysis shown in Table 6 shows the presence of alloying elements such as Fe, Cr, Ni, C and Mn together with O and S suggesting the formation of both oxides and sulfides. However, chromium sulfides are thermodynamically unstable [28]; instead of chromium sulfides, a layer of chromic oxide is expected, which might be the responsible for the passive behavior [29, 30]. In addition to this, in a study done with 18 Ni 300 grade maraging steel in a 3.5 NaCl solution containing both H2S and CO2, the formation of FeCO3, Fe2O3, FeS2, FeSO4, NiO, Ni(OH)2, NiS, NiSO4, MoO2, MoO3 and MoS2 was reported [38, 39]. Thus, the presence of chromium sulfides does not seem to be possible in this case, and due to the presence of Mn in our alloy, the formation of manganese sulfides is possible. This formed film on top of the UNS S41425-type supermartensitic stainless steel seems to be the responsible of the passive behavior observed in polarization curves, Figs. 6 and 7. However, when the steel was under hydrodynamic conditions, specimens did not show evidence of any formed corrosion product layer as it can be seen in micrographs shown in Fig. 15. As explained above, this might be due to the high shear stresses developed when the steel is exposed to hydrodynamic conditions, which detach any formed film on top of the steel surface. In these micrographs, it is clearly seen the type of localized type of attack that the steel was subjected to. The absence of such a film must be the reason of the increase in the corrosion rate as shown by the Rp and EIS results, Figs. 10 and 11.

Fig. 14
figure 14

SEM micrographs of UNS S41425-type supermartensitic stainless steel in an H2S-containing 5% NaCl solution at 50 °C containing a 0 ppm and b 25 ppm of inhibitor at 0 rpm

Table 6 EDS analysis of corrosion product layer
Fig. 15
figure 15

SEM micrographs of UNS S41425-type supermartensitic stainless steel in an H2S-containing 5% NaCl solution at 50 °C containing 25 ppm of inhibitor at a 100, b 500, c 1000 and d 2000 rpm

4 Conclusions

A nonionic Gemini surfactant obtained from palm oil has been used as corrosion inhibitor of UNS S41425-type supermartensitic stainless steel in an H2S-containing environment under hydrodynamic conditions at 50 °C. Under stagnant conditions, it decreased the Icorr value for more than two orders of magnitude, behaving as a mixed type of inhibitor. Under hydrodynamic conditions, the corrosion rate increased with an increase in the rotating speed regardless the presence of inhibitor. This is because by increasing the rotating speed, both the reactants and inhibitor mass transfer were enhanced. In addition to this, the corrosion process was affected also, since it changed from a charge transfer control to a mass transfer control. The presence of a passive layer was unaffected by increasing the rotating speed.