## 3 Results and Discussion
### Corrosion Behaviors  
The corrosion behaviors were firstly investigated by the potentiodynamic polarization and the results are shown in Figure 4. The corresponding corrosion parameters are shown in Table 2. Generally speaking, corrosion potential (\(E_{\text{corr}}\)) reflects the corrosion tendency while corrosion current density (\(i_{\text{corr}}\)) represents the corrosion rate. Under the same conditions, the sample with larger corrosion potential is generally more difficult to corrode than the sample with lower corrosion potential. As shown in Figure 4 and Table 2, when compared to the chemical treatment substrates, the pristine magnesium alloy showed the lowest corrosion potential (\(-1.57\) V) and the largest corrosion current density (37.26 \(\mu\)A/cm\({}^{2}\)), suggesting that the unmodified magnesium alloy can easily corrode in SBF, and its corrosion rate was the largest. After chemical surface modification, the corrosion potential shifted to \(-1.174\) V (Mg-OH) and \(-1.128\) V (Mg-HF), respectively, indicating that both chemical surface modification methods can reduce the corrosion tendency of magnesium alloy. It was considered that the chemical conversion layers were dense and stable and their microstructure were favorable  
Figure 3: The water contact angles of different samples. Five parallel samples were measured and the values were averaged. The data were expressed as mean \(\pm\) standard deviation (SD). The value of Mg–OH was significantly lower (\(p<0.05\)) than that of the pristine magnesium alloy, while the water contact angle of Mg–HF was significantly larger (\(p<0.05\)) than that of the pristine magnesium alloy. for the improvement of the corrosion resistance. On the other side, as shown in Table 2, the corrosion current densities were reduced to 2.05 \(\mu\)A/cm\({}^{2}\) (Mg-OH) and 0.68 \(\mu\)A/cm\({}^{2}\) (Mg-HF) after surface modification and these values were significantly lower than that of the pristine magnesium alloy (37.26 \(\mu\)A/cm\({}^{2}\)), demonstrating that the chemical surface modification can significantly enhance the corrosion resistance of magnesium alloy. According to the previous FTIR and XPS results, the newly formed chemical conversion layers (Mg(OH)\({}_{2}\) or MgF\({}_{2}\)) replaced the loosely native oxide layer on the magnesium alloy substrate, which provide the barriers to isolate the corrosion medium from the magnesium substrate, and therefore leading to better corrosion resistance. In addition, it can be seen from Figure 4 and Table 2 that Mg-HF showed better corrosion resistance than Mg-OH because the former had relative larger corrosion potential and smaller corrosion current density. As shown in Figure 5, the surface of the substrate treated by HF showed the relatively smooth morphology while the morphology of Mg-OH was relatively rough. The rough surface can increase the contact area with corrosion medium, consequently leading to smaller corrosion resistance than that of Mg-HF. In addition, the dense microstructure of magnesium fluoride may also contribute to the enhanced corrosion resistance. On the other side, it is well known that the fluoride element generally exhibits hydrophobicity. The magnesium fluoride layer can not only resist the substrate from the corrosion medium but also provide a hydrophobic surface to prevent the corrosion ions from penetrating into the magnesium substrate, leading to the enhanced corrosion resistance. \begin{table}
\begin{tabular}{c c c} \hline \hline
**Samples** & \(\mathbf{E_{\text{corr}}}\) **(V)** & \(\mathbf{i_{\text{corr}}}\) **(A**\(\cdot\)**cm\({}^{-2}\))** \\ \hline AZ31B & \(-1.570\) & \(3.726\times 10^{-5}\) \\ Mg-OH & \(-1.174\) & \(2.052\times 10^{-6}\) \\ Mg-HF & \(-1.128\) & \(6.821\times 10^{-7}\) \\ \hline \hline \end{tabular}
\end{table} 
Table 2: The corrosion potentials and corrosion current densities of different samples.