Motion of the heliospheric termination shock: 4. MHD effects