added x_mag to body. Not sure if derivatives are correct though