Macromagnetic Calculation of the Magnetization of a Deformed Ferromagnet