Preparation and Characterization of Porous Magnesium Alloys in Biomedical Applications