Magnetic Field Correction Methods for Hybrid Permanent Magnet and Superconducting Undulators