Simultaneous Localization and Calibration for Electromagnetic Tracking Systems