New insights on the influence of low frequency pulsed current on the characteristics of PEO coatings formed on AZ31B

In this work, anodic oxide layers on the surface of an AZ31 magnesium alloy were obtained by plasma electrolytic oxidation (PEO) process under low frequency pulsed current. For this, electrolytical solutions containing hexamethylenetetramine and sodium fluoride were used. The morphology and chemical composition of formed coatings were examined by scanning electron microscopy (SEM), energy dispersive spectroscopy (EDS), Fourier transform infrared spectroscopy (FTIR) and X-ray diffraction (XRD). Also, salt spray test, hydrogen evolution and electrochemical tests (potentiodynamic polarization and electrochemical impedance spectroscopy) were conducted in order to study the corrosion behavior of the coated samples. It was found that the use of low frequency pulsed current for the PEO process reduces the film porosity and increases its thickness, compared with PEO films obtained by continuous anodization. The effect of the pulsed current signal was also analyzed for a two steps PEO process, observing changes in the morphological characteristics of the coatings which allow a better corrosion according electrochemical tests (short term corrosion measurements). However, long term tests results as hydrogen evolution and salt spray tests, indicated the opposite. Both the film porosity and thickness were affected by either the pulsing of the current or the use of a two-step process.


Introduction
Magnesium is some of the lightest materials on earth, with two thirds of the density of aluminum and two fifths that of titanium [1,2]. This material is 100% recyclable, it has excellent cushioning capacity, is non-toxic, machinable and its alloys are easily moldable allowing complex parts to be manufacture. It is an attractive and profitable alternative to be used on aerospace and automotive industries, and for manufacturing of portable and electronic devices [3,4]. This material has been used in order to reduce the weight of the manufactured products, contributing with the decrease in fuel consumption and consequently or CO 2 emissions [5]. Within the magnesium alloys, the Mg-Al-Zn ones are the most used and studied since they exhibit improved corrosion resistance, better tenacity, good plasticity and resistance to stress in comparison to other magnesium alloys [3,6,7]. However, magnesium and its alloys are highly electronegative affecting its corrosion resistance in humid environments, fresh water, seawater, most organic or inorganic acids and their salts [4,8,9]. Further, the oxide layer formed on the surface of magnesium alloys is not protective since it has a Pilling-Bedworth ratio <1, being porous, incomplete and vulnerable to humid environments [10,11]. For these reasons, a surface treatment of magnesium alloys is almost mandatory in order to improve its corrosion resistance and thereby extend its use to other applications. Among many surface treatments for magnesium and its alloys [12][13][14][15], the development of anodic films on the surface emerge as a fine option. The procedure known as plasma electrolytic oxidation (PEO), allows the development of anodic layers with controlled chemical composition and morphology. In addition, PEO also allows forming coatings with good adhesion, greater thickness, improved hardness and wear resistance in contrast with traditional anodizing [16]. The PEO process and the characteristics obtained in the anodic film, have been widely explored [16][17][18] as well as the description of the mechanism of pore formation [18] and the stages taking place during the formation of a PEO coating [19]. It is recommended to avoid the occurrence of high energy sparks (orange-red sparks), in order to obtain coatings with fewer defects [16,20]. These defects are of various types: cracks, pores, incomplete discharges, amorphous residues, among others [21].
In order to reduce the possibility of reaching these high energy conditions and consequently to mitigate the formation of defects, different methods have been reported in the literature, which include the use of additives to electrolyte and the combination of various electrical parameters. Bai et al [22] found that the addition of hexamethylenetetramine as an additive to a silicate-based electrolyte could decrease the thermal stress of the coating and in turn decrease the pore size and cracks. Other authors [23,24] have indicated that the use of NaF as an additive could help to form more compact, uniform and thick layers compared to a silicate-based electrolyte alone which could increase the resistance to corrosion, due the formation of magnesium fluoride during the anodizing process which is thermodynamically more stable than MgO and Mg(OH) 2 . Echeverry-Rendon et al [25] they have also used hexamethylenetetramine and NaF as additive in the PEO process on commercially pure magnesium.
Also, it was found that a two-step PEO process could improve the final microstructural, mechanical and electrochemical properties of anodic films. Feryar et al [26] informed that with the two-step coating process, the corrosion resistance of the AZ31 alloys significant improved. Kang et al [27] fabricated an oxide layer on AZ91 alloy sample treated by two-step PEO coating, where the initial coating was made in a phosphate alkaline electrolyte and the second step with an acid electrolyte containing K 2 ZrF 6 and they suggested high improvement in structural properties of the coatings by this method. Tsunekawa et al [28] reported the formation of wearresistant and adhesive ceramic coatings, with low porosity on Ti15V3Al3Cr3Sn by two-step plasma electrolytic oxidation (PEO), the first carried out in an alkaline aluminate electrolyte and the second in an acid electrolyte containing both phosphoric acid and sulfuric acid.
Another method is the use of pulsed current; Raj et al [29] reported that the use of a pulsed anodized process on aluminum yields better quality oxide film than that of the direct current anodized process. Deacon et al [30] indicated that the use of pulses at a low frequency for the anodizing process could increase productivity, reduce the consumption of energy in the process up to 30% and decrease the time of the process by 50%. On the other hand, Xianghua et al [31] have indicated that the anodized process at low frequency pulse produced rough and thick coatings, with large pores and cracks. In contrast, an anodic layer obtained at high pulse frequencies, produce thin coatings with more quantity of smaller size porous and better corrosion resistance. Similar results were found by Hwang et al [32]; they indicated that both the intensity of the discharge and the thickness of the coatings are inversely proportional to the pulse frequency. Additionally, they concluded that high pulse frequencies on anodization process produced more MgO on the surface of the coating, which makes it more compact and resistant to corrosion. Srinivasan et al [33] also found improvements in the structural properties of the coatings developed at high frequencies; however, they reported that the coatings made at low frequencies had better behavior against corrosion. In turn, Alabbasi et al [34] indicated that the use of the constant pulsed current can decrease the porosity of the PEO coating and improves its behavior against pitting corrosion. Bononi et al [35] found that the use of high frequency pulsed current could increase the defects of PEO coatings, and could decrease the thickness of the barrier layer and destabilize it, decreasing the electrical resistance of the coating. Other authors indicated that the use of high current densities increases the thickness of the film and provides a surface with bulges and smooth areas [36,37]. Conversely, low current densities produced more compact films with fewer defects [20]. In addition, the mode of current application has a relevant impact on the morphology of the coating where unipolar currents produce porous and cracked coatings while bipolar currents result in coatings with low porosity and no cracks, but with low growth rates [38]. Additionally, low duty cycles produce high breaking voltages and high final voltages, promoting the formation of coatings with greater thickness and higher porosity but a smaller pore size, in contrast to high duty cycles [16,39]. Moreover, the duration of the PEO process is proportional to the roughness and porosity. Thus, protracted periods of times produce rough and porous coatings [38]. The formation of PEO coatings on magnesium alloys is a complex process which is influenced for divers parameters, such as: power voltage, current density, chemical composition of the electrolyte [40], the type of wave, work cycle, frequency, the type of voltage, time, among others. According to the above findings, it is still under discussion, the effect of some of those variables on the anodic coating.
The aim of this work was to evaluate the effect of very a low frequency pulse current in the formation of PEO anodic oxide layers on AZ31 magnesium, looking to contribute to the understanding of the effect of this parameter on the morphology and corrosion resistance of the anodic film. In addition, comparison of short term corrosion tests and long term assays is presented in the present work; evaluation of pulsed PEO on Mg alloys is scarce in the literature. Finally, the influence of a two-step process on the pulsed PEO process was of analyzed here. The morphological and chemical composition of PEO coatings obtained both with pulsed and continuous current signals were studied; porosity, pore size and film thickness were assessed by SEM whilst the chemical composition by EDS, XRD and FTIR. The corrosion resistance of the coatings was evaluated using different techniques such as hydrogen evolution test, saline fog test, potentiodynamic polarization test (PP) and electrochemical impedance spectroscopy (EIS).

Experimental
2.1. Preparation of the PEO films Specimens of AZ31B magnesium alloy (Al 2.9%, Zn 0.82%, Mn 0.34% bal. Mg (wt%)) were cut from sheets to form coupons of dimensions of 10×10×1 mm. The samples were mechanically polished with waterproof abrasive SiC paper up to # 1500 grit, then degreased with acetone, washed with distilled water in an ultrasonic bath during 15 min and dried in a warm air stream. The anodizing process was carried out in a 1000 ml stainlesssteel (SS) beaker, which was immersed in a cooled water bath; the SS beaker was used as cathode. The electrolytic bath was vigorously stirred at ∼400 rpm during the PEO process in order to maintain it at a uniform temperature of ∼25°C. The anodic coatings were obtained under galvanostatic mode by using a Matsusada VoL500-20 DC power supply and applying a current density of 62.33 mA cm −2 . The composition of the PEO electrolytic solutions and the process parameters are given in table 1.
To simulate the pulses of current at very low frequency, an interruption in the current flow was made during the anodization process, with an 87% duty ratio and an approximate frequency of 4.35 mHz. The calculations of the duty ratio (R) and the frequency ( f ) were made using the equations indicated by Qian et al [41]: Where, t 1 is the anodizing time, in this case 200 s, while t 2 is the time of breaking off, in this case 30 s. Choi et al [42] suggested that the values for duty ratio R should be between 83% and 98%. t 2 was 30 s in order to obtain an R value in this range and for better control of the process. Initially, PEO coatings in a single stage were prepared, one with pulsed current, labeled as 'Single Step Pulsed Current (1PC)', and other one by the application of direct current, labeled 'Single Step Direct Current (1DC)', during 1000 s. Then, two coatings, 'Two Step Direct Current (2DC)' and 'Two Step Pulsed Current (2PC)', were obtained by a two-stage PEO process made by direct current and low frequency pulsed current, respectively. For both samples, the first step was performed in an electrolyte containing NaF during 200 s, and the second one formed in an electrolyte containing (CH 2 ) 6 N 4 , for 400 s. This second step has been reported to reduce the pore size of the coatings [38].

Characterization of the PEO films
A JEOL JSM 6490 LV scanning electron microscope (SEM) was used to study the morphology of the coatings in top and cross-section views. Cross-sections were prepared metallographically, polishing with 0.3 μm alumina. The average porosity and coating thickness was determined by SEM images using ImageJ software [43]. The phase composition of the coatings was investigated by x-ray diffraction (XRD) using a PANalytical 2012 diffractometer with Cu Kα radiation. The data were recorded over 2θ range of 10°-90°, with a step size of 0.026°a nd a scan step time of 46.7 s. Fourier-transform infrared spectroscopy (FTIR) measurements were analyzed using a Shimadzu IRTracer-100 spectrometer with the wave number (cm −1 ) ranging from 400 to 4000 at 24step scan.

Corrosion tests 2.3.1. Electrochemical measurements
The corrosion tests were performed in naturally aerated 3.5 wt% sodium chloride solution at room temperature using specimens with an exposed area of ∼0.1964 cm 2 . Potenciodynamic polarization (PP) and electrochemical impedance spectroscopy (EIS) measurements were made using an IM6 Zahner Elektrikn potentiostatgalvanostat, connected to a three-electrode cell; the working electrode was the test material, with an Ag/AgCl electrode as the reference electrode and a platinum mesh as the counter electrode. The potenciodynamic polarization curves were generated from −300 mV of cathodic overpotential to 300 mV of anodic overpotential with respect to the open circuit potential (OCP), using a scan rate of 0.5 mV s −1 . Before initiating the electrochemical measurements, the OCP was monitored for approximately 30 min to achieve a constant value [44]. The EIS measurements were performed at open circuit potential using a perturbation amplitude of 10 mV (rms) and a frequency range of 10 mHz to 1000 Hz during 3 days of immersion with sampling times of 0.5, 3, 24 Table 1. Electrolyte composition and electrical parameters used to obtain the anodic coatings. In all cases a current density of 62.33 mA·cm −2 was used.

Sample ID Type PEO
Step

Hydrogen evolution tests
Specimens of 2.4 cm 2 were placed within a beaker, suspended with nylon without touching any surface in 100 ml of a solution containing NaCl 3.5 wt% at room temperature. The setup of the test was made according to previous works [45,46]. The corrosion rate P (mg cm −2 d −1 ), was calculated using the following equation proposed by Mingo et al [47]:

H2
Where VH 2 is the volume of hydrogen gas evolved in ml, A is the exposed area in cm 2 and t is the immersion time in days. Hydrogen evolution measurements were made by triplicate, with the average values of the individual measurements presented in the results.

Salt spray test
The salt spray test was carried during 7 days, using a salt spray cabinet Q-LAB Q-FOG/SSP600 according to the standard ASTM B117 [48]. The salt spray atmosphere used an aqueous solution of NaCl 5 wt% with neutral pH, which was atomized keeping an air pressure in the range 70-170 kN m −2 and the temperature at 35°C. After testing, the samples were rinsed with distilled water and then dried with a warm air stream. To evaluate the corrosion of the samples, the surface appearance of specimens after exposure to salt spray tests was analyzed according to the standard ASTM D610-08 [49]. Following this standard, and according to the fraction of surface area affected by corrosion, a score was given. A high score corresponds to low corrosion attack, that is to say a high corrosion resistance [44]. The surface areas affected by corrosion were measured with the ImageJ software using a scanned image of each surface. Salt spray evaluation was made in triplicate, with the average values of the individual measurements presented in the results.

Results and discussion
3.1. Variation of voltage versus time Figure 1 displays the voltage-time responses recorded during galvanostatic PEO anodizing of AZ31B magnesium alloys at the different conditions listed in table 1. For the clarity of the readers, it is important to mention that the voltage-time responses for galvanostatic PEO anodizing of magnesium alloys exhibit two inflection points [19]. The first one is associated with the breakdown potential, and the second one is the critical potential. The breakdown potential is the voltage at which the process changes from conventional anodizing to spark anodizing. While the critical potential is the voltage at which the process reaches both an approximately constant value and a steady state sparking. For samples 1DC and 1PC, figure 1(a) shows that the breakdown voltage was at about 120 V and 14 s of the PEO process. Between 37 and 240 s, white sparks were clearly visible all over the sample surface. The critical voltage, was evident at around 378 V. Then, voltage values were approximately constant around 380 V and the presence of sparks was less evident changing its color from white to orange. The final voltages for 1DC and 1PC were 401 and 421 V, respectively. The higher voltage value for 1PC sample indicates the formation of either a thicker film, a film with higher electrical resistance or the combination of both [32,33]. The two-step process was carried out in order to analyze the effect of an existing anodic film on the surface before applying the pulsed current PEO process. Figure 1(b) shows voltage-time responses for the two-step PEO process, both with pulsed current and direct current. The plot for the sample obtained in NaF containing electrolyte revealed a breakdown voltage of about 121 V at just around 6.5 s, followed by a voltage increase up to around 210 V during the first 45 s of processing and then, large fluctuations of the voltage until the end of the process were evident. Also, it was easily observed that voltages developed during anodizing were ∼50% lower than that of anodizing in an electrolyte containing hexamethylenetetramine (2DC and 2PC ( figure 1(b))). This behavior was related to the lower conductivity (21.8 mS cm −1 , see table 1) of the electrolyte. Regarding 2DC or 2PC samples ( figure 1(b)), similar breakdown, critical and final voltages were observed being 266 V, 378 V and 398 V, respectively. As expected, coatings produced by two-steps PEO processes ( figure 1(b)) achieved breakdown voltages 30% faster than that produced by single-step PEO processes ( figure 1(a)). Such a difference is certainly due to the existence of the anodic coating formed in the electrolyte containing NaF, which appears to be stable in the hexamethylenetetramine electrolyte [17]. Finally, it is important to mention that no matter if the samples were previously anodized in the electrolyte containing NaF or not, the voltage-time response curve of AZ31B magnesium alloy anodized in an electrolyte containing hexamethylenetetramine was quite stable (figure 1). Thus, the nature of the electrolyte was the main responsible of inducing the observed oscillations in the voltage-time response curve during the formation of the anodic film in NaF. Furthermore, in any case, pulsed current at low frequency do not significantly affected the voltage-time response curves since voltages followed the same trend after each pulse. However, this current mode did affect the morphology and porosity of the anodic layers, as shown below. Comparing the results for coatings produced by a single step (1DC and 1PC (figure 1(a))) with those formed by a two-step process (2DC and 2PC ( figure 1(b))), it was observed that despite the existence of the film formed in NaF, the final voltage was very similar (∼400 V) but there was a big variation in the breakdown voltage and the maximum time of anodizing, before the failure of the coating. For the singlestep samples, breakdown occurred at just 120 V, well below the ∼266 V obtained for the two-steps coatings. On the other hand, PEO anodizing for the one-step samples was possible to be carried out above 1000 s, whereas for the two-steps samples, anodizing above just 400 s induced extensive coating failure. No variation on these matters was observed due to use of the pulsed current signal, except for a slight increment in the final voltage for the 1PC sample compared to 1DC.

Morphology, porosity and chemical composition of PEO anodic layers
The visual observations, all coated samples were of a uniform, dark grey, matte appearance with no signs of discontinuities or cracks. The figure 2 shows the scanning electron micrographs of AZ31B magnesium alloy following a PEO anodizing process in the electrolytes listed in table 1. Images of the anodic layers are shown in plan-view and in cross-section. EDX elemental microanalysis and the visual appearances of coatings are shown as well.
Chemical composition, morphological characteristics and the percentage area distribution of pore size of PEO anodic layers analyzed through the ImageJ software, are presented in tables 2-4, respectively. It was observed that the obtained PEO anodic coatings consisted of a porous layer with an irregular interface and a barrier film less than 1 μm thick, dense and adhered to the metal substrate. Then, a less compact intermediate layer with few pores was found and finally, a porous external layer with craters on the top, which is in good agreement with the reported by other authors [15,19,48]. From both, SEM images and the data reported on table 3, it was clearly evidenced that 1DC and 2DC samples exhibited the greater porosity and lower thickness while 1PC and 2PC samples showed a lower amount of surface porosity and an increased thickness, in agreement with other reports [28,29]. The surface of 1PC sample revealed a lesser number of pores in contrast with that of 1DC sample, suggesting that the internal porosity of coatings was affected by the interruption of the PEO process. Pore size distribution presented in table 4, indicated that 1PC sample had an average porosity of 5.77%, which was smaller than 1DC coating. Therefore, despite employing a quite low frequency pulsed current, it induce decrease in the porosity of the coatings similar to reports at higher frequencies [34]. This was evident for both the 1PC and 2PC samples, disregarding the existence of the NaF coating on the surface for 2PC.
On the other hand, pore size distribution for 2PC sample was slightly more concentrated towards smaller pore sizes than that of 2DC coating (see table 4). Regarding Feret diameter, it was found that lower values of this parameter were obtained when an interrupted PEO process was employed. According to Hussein et al 50 ., the PEO process has three types of discharges: type B is the highest energy and the discharges are produced between the oxide-metal interface whilst A and C type discharges are, in respective order, less energetic and are produced between the electrolyte and the oxide. C-type discharges are produced inside the pores of the layer, which are responsible of the morphology of the coating. Therefore, type A and B discharges, which are more energetic than C-type, are associated with larger pores. It is believed that A and B type discharges are rarely presented during two step PEO process; discharge channels must be the main PEO reaction areas during the second step of PEO and therefore, the control of the discharges and the morphology of the final coating, is given by the porous structure resulting from the first step [50], see coatings formation mechanism in figure 3. In addition, the lesser  defective structures of 2PC and 2DC coatings could also be attributed to the presence of fluorides in the electrolyte during the first step, since it is well known that the existence of fluorinated species during PEO anodizing of magnesium alloys enables the occurrence of in-situ sealing of pores as explained elsewhere [19,51,52]. Hence, the decrease in pore size of 2PC is highly related to the use of pulsed current. In addition, other variables such as a shorter PEO process (a reduction from 1000 to 400 s) or a two-step PEO process (the pore size of 1PC and 2DC are very close to each other) influence pore size to a lesser extent. Furthermore, the use of a pulsed electric current allows (i) the recovery of the double electric layer, (ii) a decrease in the polarization of the anode and (iii) a cooling period between each current flow interval. Those benefits, known as 'recovery effect', are achieved by the current interruption in an anodizing process [28,29,34]. In addition, the lower the film porosity the lower the surface roughness, which might have an additional contribution to the corrosion resistance of the layers [42]. Cross-sectional images (figure 2) revealed that the barrier layer of 1DC coating was slightly greater than that produced by five steps (1PC) with a 1.23±0.12 μm and 0.99±0.05 μm, respectively. Such a difference in thickness suggested that the pulsed PEO process affects the growth rate of the barrier layer; this is in agreement with the report of Bononi et al [35]. Conversely, the thickness of the barrier layer for 2DC and 2PC coatings appears to be similar, indicating that the formation of the barrier layer was more related with the first PEO -0.10 -- Figure 3. The figure represents a voltage versus time PEO curve. The dotted red line represents a continuous PEO process, where the coating presents during the entire time of the process, type A, B and C discharges. While the blue curve represents a PEO process by pulses, as can be seen, before the first pulse there are discharges Type A, B and C, after the first pulse, the Type C discharges are basically responsible for the formation of the coating.
process in NaF solution. Thus, the use of a pulsed PEO process clearly alters the morphological characteristics of anodic coatings developed on the surface of AZ31B magnesium alloys. This could be explained by the fact that when an anodic coating is obtained by a pulsed PEO process, short-lived micro discharges take place at the discharge channels formed in previous steps, resulting in the reduction of coating porosity.
Regarding the chemical composition of the anodic layers (see table 2), signals of O, Mg, Al, Si, Na and K were disclosed by EDX surface analysis for all coatings, with an additional F signal for 2PC (42, 9 O wt%) and 2DC from the electrolytic solution containing NaF used during the first stage. In addition, there were some differences in the amount of Si, Na and K present, with 1DC coating showing higher amounts and suggesting that applying the electric field continuously for longer periods favors the incorporation of these elements into the anodic film. Then, the use of a pulsed current signal appears to induce lower introduction of electrolyte species into the anodic film. XRD patterns and FTIR spectra obtained for the various samples are presented in figure 4. In the XRD patterns, peaks for Mg, MgSiO 3 and MgO were evident for all specimens; the strong peak located at 35°was attributed to Mg due to a reflection from the substrate [53]. Compounds containing Na, Al and K, which were revealed by EDS, were either not present or not identified by XRD. This may be related to the small amount of such elements. The presence of diffraction peaks corresponding to MgF 2 were neither detected in the samples pretreated in NaF, this is in a good agreement with the reported by Lin et al [23]. However, this could be related to the small amount of fluorine incorporated to the anodic coating. In the FTIR spectra, a band at around 588-694 cm −1 attributed to the metal-oxygen bending vibration of MgO was evident [36,37]. In addition, the band at 806 cm −1 was associated with stretching vibrations of Si−O bond in a magnesium silicate compound [54]. The bands observed between 518-400 cm −1 were attributed to Si-O and Mg-O bands, according to the literature [39]. These spectra did not reveal the presence of any hydroxide material, which was coherent with the chemical composition obtained from XRD analysis. Furthermore, high temperatures values during PEO might generate the conditions to transform Mg(OH) 2 into MgO, to finally only obtain a coating formed by MgO and Mg 2 SiO 4 [55]. Similar to other valve metals, formation of anodic oxide films on magnesium alloys is given by outward diffusion of Mg 2+ ions and inward diffusion of different anions, in this case OH − , SiO 3 −2 , O −2 [56]. Considering the results of XRD and FTIR, there was not any effect of neither pulsing the  Figure 5 shows the potentiodynamic polarization curves of coatings formed on AZ31B magnesium alloy following a PEO anodizing process according to the described in table 1. The potentiodynamic polarization curve for the bare magnesium alloy was also included. Table 5 exhibits the electrochemical parameters calculated from the potentiodynamic polarization curves. The corrosion current density, J corr (A·cm −2 ) was estimated by Tafel extrapolation of the cathodic branches of polarization curves. J corr was related to the average corrosion rate P i (mm·y −1 ) using the following expression [45,46]:

Corrosion tests
As expected, uncoated AZ31 magnesium alloy presented a high negative potential at −1.563 V and a high corrosion current density of 5.6×10 −5 A cm −2 ; this due to its high reactivity in aqueous and chloride media [4]. All the coated samples exhibited less negative corrosion potential than the uncoated substrate, indicating the presence of a resistive layer that reduces the electrochemical activity of the material. The J corr values of the coated samples were lower than the result obtained for the bare substrate and the reduction in the corrosion rate was related with the conditions of coating formation and with the ability of the coating to reduce the electrolyte permeation. This means that the reduction of the corrosion rates should be related to the increased thickness and low porosity of the coating [60]. The 2DC was the only sample that showed a passivation behavior in the anodic branch of the polarization curve, however, its corrosion rate was larger than that exhibited by the 2PC sample; according to the corrosion rates (table 5) obtained by potentiodynamic polarization tests for the different coatings in descending order were 1DC, 1PC, 2DC and 2PC. This behavior is coherent with the results of morphology and porosity of the anodic films. A more compact structure might reduce the transport of water  and aggressive Cl − ions through the coating [60]. Hence, the presence of larger pores on the surface of the PEO coatings increases the area of the effective surface as well as the tendency of the corrosive medium to enter the pores which allows a faster penetration of the corrosive medium into the PEO coating and then into the substrate. This is the reason why according electrochemical tests, the 1DC sample exhibits less corrosion resistance [61], while the 2PC sample has the smallest size pore and the best corrosion resistance. Furthermore, it is observed how both the pulsed current and the two-step process, leads to lower corrosion rates of the anodic films on the AZ31 alloy. figure 6 shows the Nyquist diagrams of EIS experiments for all samples performed at different immersion times. In general, the samples displayed two coupled capacitive loops at high and low frequencies corresponding to two electrochemical phenomena with different time constants. The 1DC sample was the only one that exhibited inductive loops at low frequencies, in addition to those capacitive loops observed at higher frequencies.
The inductive loops at low frequencies are normally related to dissolution of the metal in a corrosion system, also this phenomena is attributed to the relaxation of adsorbed species, such as Mg 2+ or MgOH + [62,63]. The capacitive loop observed at high frequencies is related to the charge transfer resistance in parallel combination with the relaxation of the electrical double-layer; while the capacitive loop at low frequencies is relate to corrosion product formation [4]. It was observed that the size of both capacitive loops for all the samples, except for 2DC, was reduced with the increase of test time. This indicates that those coatings are permeable to the electrolyte, while the protective capacity of the 2DC coating was improved during the test, and the rate of electrolyte permeation was dependent on the coating type. In order to make a convenient analysis of the impedance results, it was considered that the diameter of the first capacitive loop, observed at high frequencies, could be related to the charge transfer resistance of the substrate and the evolution of that loop was due to the formation of corrosion products on the metal/electrolyte interface during the immersion time [62,64]. Some authors have indicated that is common in some magnesium alloys to observe an increase in the capacitive loop with immersion time associated with the diminishing or vanishing of the inductive loop suggesting an improvement of the protection of the surface by the corrosion products [65]. The diameter of this loop was labeled as R f ., according to Delgado et al [63] for Mg-Al alloys, the occurrence the first capacitive semicircle to  high frequencies is linked with the charge transfer reaction of the alloy with a partial protective oxide/hydroxide layer formed as corrosion product in the test solution. In addition, the diameter of the second capacitive loop observed at low frequencies could be related to the polarization resistance (R p ) of the anodic coating or of the bare substrate, according to the case. Obviously, the evolution of the second capacitive loop with the immersion time must be related to the electrolyte penetration into the coating. Considering that, exist a relationship between the time evolution of the capacitive loops diameter and the occurrence of corrosion processes [63], the evaluation of R f and R p at different immersion times were made directly from the impedance diagrams by measurement of the diameters of the capacitive loops at high and low frequencies, respectively. Their values are shown in table 6. As was already commented, all coatings except the 2DC, exhibited decrease of the impedance values during the immersion test. As can be seen in table 6, the values of R f and R p of all samples, in general terms, diminish with immersion time. Conversely, the 2DC sample showed increase of the R f and R p , during the immersion test, indicating a reinforcement of the protective action of the anodic coating. This probably due to a passivation phenomenon of the sample, which was also observed during the potentiodynamic polarization test. With the available results, it is not possible to explain the passivation mechanism for 2DC during the electrochemical tests. However, it may be possible to be related to the presence of the anodic layer developed during stage 1 (anodized in NaF containing electrolyte), since as explained before, the formation of the barrier layer was more related with the PEO process in the NaF containing solution. Moreover, in agreement with this, a detailed inspection of the EIS results for 2PC coating (also anodized in NaF solution), revealed a slight reinforcement of the protection of the coating at the initial stage of the immersion test (3 h), as indicated the increment of the R f and R p values (see figure 6 and table 6).
As expected, and according to the potentiodynamic polarization measurements, the substrate exhibited the lowest values of R f and R p . The 1PC coated sample initially exhibited the highest values of R f and R p , although in the end of the test (72 h) it showed low values of resistance. The samples 2DC and 2PC exhibited intermediate values of resistances, around of 10 3 ohm·cm −2 ; however, the former showed reinforcement of the corrosion protection of the coating by passivation phenomenon and the R f and R p values were superior to all other samples in the end of the test (72 h), as was explained before.
It is important to mention that short-term corrosion resistance measurements (i.e. electrochemical measurements) may lead to confusing conclusions about the behavior of magnesium alloys [63], since these alloys exhibit a special electrochemical phenomenon known as the negative difference effect (NDE) and this increases with the content of Al in the Mg alloy [66]. This effect could introduce significant errors into corrosion rate measurements when using electrochemical techniques. Magnesium and its alloys has an abnormal polarization behavior where the hydrogen evolution rate increases during anodic polarization [46], being this opposite to the expected behavior according to the general electrochemical theory [67]. Therefore, the estimation of corrosion current density simply based on a polarization curve could be unreliable [46], since the NDE distorts the normal development of polarization curves. The measurement of the corrosion rate through hydrogen evolution collection is a more reliable method. Theoretically, the measurement of the hydrogen amount evolved is equal to the measurement of magnesium dissolved [46]. Hence, by monitoring the rate of volume change during the measurement of hydrogen evolution, the corrosion process of the specimen may be recorded [46]. Figure 7 shows the corrosion rates derived from hydrogen evolution tests of all the samples. It was evident that the corrosion rate of the bare substrate was much larger than the coated samples, as expected. Accordingly, the anodic layers obtained in this study, do confer corrosion protection to AZ31B magnesium alloy. In the beginning of immersion time, 1DC coating exhibited a greater corrosion rate compared to other treatments. However, for long-term immersion (two months), the corrosion rate of 1DC decreased and tended to stabilize while that of the other anodic layers increased. This indicates, that neither a low frequency pulsed current method (sample 1PC) nor formation of a previous coating (2DC and 2PC samples), provides better protection to the AZ31 substrate in this immersion conditions. This result being in clear disagreement with the electrochemical polarization test results. This could be explained by the nature of the measuring tests, electrochemical assays provides an instant (an in this case short term) while hydrogen evolution gives an accumulative, long term result.
It was also observed that anodic coatings developed by pulsed current PEO process (i.e. 1PC nor 2PC) showed an increase in the corrosion rate after around 20 days of immersion. It is important to highlight that the hydrogen evolution results obtained from 5 to 15 days of immersion were in good agreement with the electrochemical tests since both techniques indicates that 1DC was the more active sample of all. However, in the long-term, there was no good correspondence between results of hydrogen evolution and electrochemical tests, where 1DC showed a much lower and stable corrosion rate than the other samples. Regarding hydrogen evolution results, the best corrosion resistance was determined for sample 1DC, which has larger porosity and larger pore size compared to those of 2PC. A possible contribution to the improved performance of 1DC coating might be that its barrier layer was about 30% thicker than 1PC; however, this difference do not seem to be large enough to produce such a drastic corrosion behavior. Unexpectedly, 1DC has a much larger porosity area (about 3 times than the others) and the bigger pore diameter (nearly twice the other coatings). These two factors, might be inducing some sort of 'passivation', due to formation of a thick enough and uniform corrosion products layer (Mg(OH) 2 ) both underneath the anodic film and inside the pores. This layer acts as a barrier protecting the substrate from the electrolyte attack; however, it needs some time to build up. In the case of the other coatings, with much lower porosity and pore size, the process must be taking place less uniformly on the surface, leading to more localized attack, which after a nucleation period makes the corrosion rate to increase with time (See figure 7). Figure 8 shows scanning electron micrographs (secondary electrons) of the sample surfaces after the hydrogen evolution tests. Plan and cross-sectional views are displayed. Micrographs correspond to 60 days of immersion in a 3.5% NaCl solution. Cracks can be observed on the surface and in the cross section of all anodic layers. Such cracks may be due to a combined action of the following factors: (i) internal stresses generated by corrosion products, (ii) metallographic preparation of samples and (iii) high vacuum into the SEM chamber. Nevertheless, it was observed that the anodic coating that contains the least amount of cracks corresponds to 1DC. In addition, pores were less evident in the surface of the anodic coatings developed by an interrupted PEO process (i.e. 1PC and 2PC). Cross sections revealed, in all cases, that a relatively thick corrosion products layer formed beneath the anodic film, which most probably was composed mainly of Mg(OH) 2 , as widely reported. Figure 9 shows scanning electron micrographs (secondary electrons) after salt spray tests of coatings formed on AZ31B magnesium alloy following a PEO anodizing process in the electrolytes listed in table 1. Plan view and visual appearances are displayed. These images correspond to 7 days of exposure to the salt spray test conditions. The surface area fraction affected by corrosion attack and their corresponding scores and visual example scores according to ASTM D610-08 [49] are listed in table 7. From the coatings appearances, corrosion was concentrated in a few localized areas of the samples (see black arrows in figure 9). From the results in table 6, it was found that the best corrosion behavior was shown by 1DC and 1PC, although all coatings appear to be protective under these test conditions. An inspection of SEM images in figure 9, reveals that all anodic coatings presented an apparently much lower porosity compared with the un-exposed surface (see figure 2); this must be certainly due to formation of corrosion products (mainly Mg(OH) 2 ) on the coating surface and inside the pores. These results are in good agreement with the hydrogen evolution tests and the better performance of both 1DC and 1PC could be related to the increased thickness exhibited by these two coatings (See figure 2). In any case, the results obtained after the salt spray test show that the coatings obtained in this work are as good or in most cases better than the reports of the literature, as discussed next. Mingo et al [44] formed different PEO coatings over AZ91 alloy using a silicate electrolyte with and without NaF additions. These coatings were later sealed in three different solutions containing Ce, Sn and octodecylphosphate acid (ODP). The scores obtained after 7 days exposure to the salt spray chamber conditions, were below 8 for most cases, this value was only reached for samples anodized in presence of NaF and sealed either in the Ce or ODP solutions. Einkhah et al [26] obtained two different coatings on AZ31 alloy, one processed by a two-step in which the surface was first treated in a phosphate alkaline electrolyte and then in an acid electrolyte containing K 2 ZrF 6 . The other coating was obtained by anodizing in the alkaline solution with additions of K 2 ZrF 6 . Salt spray test results allowed the authors to conclude that the two-step coating had higher corrosion resistance. The samples were exposed to 7 days in the test chamber and, in both cases, it showed more severe localized attack than in the present study. Arrabal et al [18] produced PEO coatings on AZ31 using pulsed current and a solution containing both silicate and fluoride ions; after 7 days of salt spray testing, the samples showed very visible pitting corrosion attack.
Li et al [68] anodized AZ91D samples in a silicate solution with additions of silica sol and exposed to a salt spray chamber environment. They recorded the time of formation of pitting on the surface and found that in the best case, when adding 10% silica sol, it lasted just above 12 h. Mori et al [69] used silicate-phosphate mixtures to anodize samples of AZ31B, analyzing the effect of changing the silicate to phosphate ratio. They found that for mixtures with phosphate contents above 50%, strong discoloration of the coatings was observed. In contrast for coatings obtained in electrolytes with low phosphate ratios (i.e. 5% and less) local corrosion was readily observed even at after just 24 h of testing. The better corrosion resistance was obtained for the coatings formed in an electrolyte with a phosphate:silicate ratio of 20:80; however, even for this case some pits were already observed after 24 h of exposure. Considering the results of the salt spray test, low frequency pulsed anodizing although affecting the coating morphology do no change its corrosion resistance the harsh environment. On the other hand, the corrosion resistance provided by the anodic film is mainly dependent on the thickness of the film, as thicker films (1DC and 1PC) performed better than thinner anodic layers obtained by a two-step process (2DC and 2PC).

Conclusion
Anodic oxide layers on the surface of an AZ31 magnesium alloy were obtained by plasma electrolytic oxidation (PEO) process under direct and low frequency pulsed current. It was confirmed that when the anodizing time increases the surface defects of PEO coatings also increases, with the occurrence of high energy sparks producing large short-lived micro discharges, which melt the anodic material and form pores. In addition, anodic layers with less surface porosity are obtained by means of a pulsed PEO process since sparks occur at the same locations as in the previous steps, and no new discharge channels are created. It was evidenced that at short-term according electrochemical tests, the corrosion rate of anodic coatings formed using a pulsed current PEO process decreases; however, corrosion rate increases in long-term exposures, where samples were put on immersion in 3.5% NaCl solution for two months. It can be concluded that the porous structure obtained during the continuous process provides better corrosion resistance for long term immersion conditions and the  thickness of the anodic film is critic for obtaining better corrosion performance in salt spray conditions. There was no good correspondence between results of hydrogen evolution and electrochemical tests in the long-term.

ORCID iDs
L