Main Content

Spherical Harmonic Gravity Model

Implement spherical harmonic representation of planetary gravity

  • Spherical Harmonic Gravity Model block

Libraries:
Aerospace Blockset / Environment / Gravity

Description

The Spherical Harmonic Gravity Model block implements the mathematical representation of spherical harmonic planetary gravity based on planetary gravitational potential. It provides a convenient way to describe a planet gravitational field outside of its surface in spherical harmonic expansion.

You can use spherical harmonics to modify the magnitude and direction of spherical gravity (-GM/r2). The most significant or largest spherical harmonic term is the second degree zonal harmonic, J2, which accounts for oblateness of a planet.

Use this block if you want more accurate gravity values than spherical gravity models. For example, nonatmospheric flight applications might require higher accuracy.

Limitations

  • The block excludes the centrifugal effects of planetary rotation, and the effects of a precessing reference frame.

  • Spherical harmonic gravity model is valid for radial positions greater than the planet equatorial radius. Minor errors might occur for radial positions near or at the planetary surface. The spherical harmonic gravity model is not valid for radial positions less than the planetary surface.

Ports

Input

expand all

Fixed-frame coordinates from center of planet, specified as an N-by-3 matrix, in selected units. Each row of the matrix is a separate position to calculate. The z-axis is positive toward the North Pole. If Central body model has a value of EGM2008 or EGM96, this matrix contains Earth-centered Earth-fixed (ECEF) coordinates.

When inputting a large fixed-frame matrix and a high degree value, you might receive an out-of-memory error. For more information about avoiding out-of-memory errors in the MATLAB® environment, see Resolve “Out of Memory” Errors.

When inputting a large fixed-frame matrix, you might receive a maximum matrix size limitation. To determine the largest matrix or array that you can create in the MATLAB environment for your platform, see Performance and Memory.

Data Types: double

Output

expand all

Array of gravity values in the x-axis, y-axis, and z-axis of the fixed-frame coordinates, in selected length units per second squared. Each row of the matrix returns the calculated gravity vector for the corresponding row in the input matrix.

Data Types: double

Parameters

expand all

Input and output units, specified as:

Units

Input

Output

Metric (MKS)

Meters (m)

Meters/sec2 (m/s2)

English

Feet (ft)

Feet/sec2 (ft/s2)

Programmatic Use

Block Parameter: units
Type: character vector
Values: 'Metric (MKS)' | 'English'
Default: 'Metric (MKS)'

Out-of-range input behavior, specified as:

ValueDescription

None

No action.

Warning

Warning in the Diagnostic Viewer, model simulation continues.

Error

MATLAB returns an exception, model simulation stops.

The spherical harmonic gravity model is invalid for radial positions less than the planetary surface. The Spherical Harmonic Gravity Model block accepts out of range radial position inputs (less than planetary equatorial radius) when Action for out-of-range input is set to None or Warning. However, the block output might not be accurate or reliable.

Programmatic Use

Block Parameter: action
Type: character vector
Values: 'None' | 'Warning' | 'Error'
Default: 'Warning'

Planetary model, specified as:

Central body modelNotes
EGM2008

Earth — Is the latest Earth spherical harmonic gravitational model from National Geospatial-Intelligence Agency (NGA). This block provides the WGS-84 version of this gravitational model. You can use the EGM96 planetary model if you need to use the older standard for Earth.

EGM96 Earth
LP100K

Moon — Is best for lunar orbit determination based upon computational time required to compute orbits. This planet model was created in approximately the same year as LP165P with similar data.

LP165P

Moon — Is best for extended lunar mission orbit accuracy. This planet model was created in approximately the same year as LP100K with similar data.

GMM2B

Mars

Custom

Enables you to specify your own planetary model. This option enables the Central body MAT-file parameter.

EIGENGL04C

Earth — Supports the gravity field model, EIGEN-GL04C (http://icgem.gfz-potsdam.de/tom_longtime). This model is an upgrade to EIGEN-CG03C.

For more information on the fixed-frame coordinate system for the central bodies, see Algorithms.

When defining your own planetary model, the Degree parameter is limited to the maximum value for int16. When inputting a large degree, you might receive an out-of-memory error. For more information about avoiding out-of-memory errors in the MATLAB environment, see Resolve “Out of Memory” Errors.

Dependencies

Setting this parameter to Custom enables Central body MAT-file.

Programmatic Use

Block Parameter: ptype
Type: character vector
Values: 'EGM2008' | 'EGM96' | 'LP100K' | 'LP165P' | 'GMM2B' | 'Custom' | 'EIGENGL04C'
Default: 'EGM2008'

Degree of harmonic model, specified as a scalar:

Central body modelRecommended DegreeMaximum Degree

EGM2008

120

2159

EGM96

70

360

LP100K

60

100

LP165P

60

165

GMM2B

60

80

EIGENGL04C

70

360

Programmatic Use

Block Parameter: degree
Type: character vector
Values: scalar
Default: '120'

Central body MAT-file that contains definitions for a custom planetary model. The aerogmm2b.mat file in Aerospace Blockset™ is the default MAT-file for a custom planetary model.

This file must contain:

VariableDescription
Re

Scalar of planet equatorial radius in meters (m).

GM

Scalar of planetary gravitational parameter in meters cubed per second squared (m3/s2)

degree

Scalar of maximum degree.

C

(degree+1)-by-(degree+1) matrix containing normalized spherical harmonic coefficients matrix, C.

S

(degree+1)-by-(degree+1) matrix containing normalized spherical harmonic coefficients matrix, S.

When using a large value for Degree, you might receive an out-of-memory error. For more information about avoiding out-of-memory errors in the MATLAB environment, see Resolve “Out of Memory” Errors.

Dependencies

To enable this parameter, set Central body model to Custom.

Programmatic Use

Block Parameter: datafile
Type: character vector
Values: 'aerogmm2b.mat' | MAT-file
Default: 'aerogmm2b.mat'

Algorithms

The Spherical Harmonic Gravity block works in the fixed-frame coordinate system for the central bodies:

  • Earth — The fixed-frame coordinate system is the Earth-centered Earth-fixed (ECEF) coordinate system.

  • Moon — The fixed-frame coordinate system is the Principal Axis system (PA), the orientation specified by JPL planetary ephemeris DE403.

  • Mars — The fixed-frame coordinate system is defined by the directions of the poles of rotation and prime meridians defined in [14].

References

[1] Gottlieb, Robert G., "Fast Gravity, Gravity Partials, Normalized Gravity, Gravity Gradient Torque and Magnetic Field: Derivation, Code and Data." NASA-CR-188243. Houston, TX: NASA Lyndon B. Johnson Space Center, February 1993.

[2] Vallado, David. Fundamentals of Astrodynamics and Applications. New York: McGraw-Hill, 1997.

[3] "Department of Defense World Geodetic System 1984, Its Definition and Relationship with Local Geodetic Systems." NIMA TR8350.2.

[4] Konopliv, A.S., W. Asmar, E. Carranza, W.L. Sjogren, and D.N. Yuan. "Recent Gravity Models as a Result of the Lunar Prospector Mission," Icarus, 150, no. 1 (2001): 1–18.

[5] Lemoine, F. G., D. E. Smith, D.D. Rowlands, M.T. Zuber, G. A. Neumann, and D. S. Chinn. "An Improved Solution of the Gravity Field of Mars (GMM-2B) from Mars Global Surveyor". Journal Of Geophysical Research 106, np E10 (October 25, 2001): pp 23359-23376.

[6] Kenyon S., J. Factor, N. Pavlis, and S. Holmes. "Towards the Next Earth Gravitational Model." Society of Exploration Geophysicists 77th Annual Meeting, San Antonio, TX, September 23–28, 2007.

[7] Pavlis, N.K., S.A. Holmes, S.C. Kenyon, and J.K. Factor, "An Earth Gravitational Model to Degree 2160: EGM2008." Presented at the 2008 General Assembly of the European Geosciences Union, Vienna, Austria, April 13–18, 2008.

[8] Grueber, T., and A. Köhl. "Validation of the EGM2008 Gravity Field with GPS-Leveling and Oceanographic Analyses." Presented at the IAG International Symposium on Gravity, Geoid & Earth Observation 2008, Chania, Greece, June 23–27, 2008.

[9] Förste, C., Flechtner et al, "A Mean Global Gravity Field Model From the Combination of Satellite Mission and Altimetry/Gravmetry Surface Data - EIGEN-GL04C." Geophysical Research Abstracts 8, 03462, 2006.

[10] Hill, K. A. "Autonomous Navigation in Libration Point Orbits." Doctoral dissertation, University of Colorado, Boulder. 2007.

[11] Colombo, Oscar L. "Numerical Methods for Harmonic Analysis on the Sphere." Reports of the Department of Geodetic Science, Report No. 310, The Ohio State University, Columbus, OH., March 1981.

[12] Colombo, Oscar L. "The Global Mapping of Gravity with Two Satellites." Netherlands Geodetic Commission 7, no 3, Delft, The Netherlands, 1984., Reports of the Department of Geodetic Science. Report No. 310. Columbus: Ohio State University, March 1981.

[13] Jones, Brandon A. "Efficient Models for the Evaluation and Estimation of the Gravity Field." Doctoral dissertation, University of Colorado, Boulder. 2010.

[14] Report of the IAU/IAG Working Group on cartographic coordinates and rotational elements: 1991.

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.

Version History

Introduced in R2010a