IGRF Magnetic Field

Compute IGRF mean earth magnetic field

You are now following this Submission

MATLAB implementation of IGRF11 fortran code as function for calculating Earth mean magnetic field. Implementation has been modified to default to GPS reference coordinates with output B components North, East, and Vertical. Spherical harmonic coefficients are derived from downloaded Excel file.
http://www.ngdc.noaa.gov/IAGA/vmod/igrf.html

Screenshot created by Demo_igrf11syn

Cite As

Charles Rino (2026). IGRF Magnetic Field (https://uk.mathworks.com/matlabcentral/fileexchange/28874-igrf-magnetic-field), MATLAB Central File Exchange. Retrieved .

General Information

MATLAB Release Compatibility

  • Compatible with any release

Platform Compatibility

  • Windows
  • macOS
  • Linux
Version Published Release Notes Action
1.2.0.0

date fdate variable conflict fixed.

1.1.0.0

Error noted by Mark Shore for fyear>=2000 fixed. GHcoefficients.mat version of spherical harmonic coefficients added. Code checked against results kindly provided by Mark Shore.

1.0.0.0