Path: Orbit/OrbitMechanics
% Compute the gravitational acceleration in cartesian coordinates. Acceleration vectors are a [ aX;aY;aZ ]. If the gravity coefficients are normalized, an additional matrix multiplication is required. The normalization matrix is stored as a persistent variable but AGravityC will gracefully update it if the normalization or order of the model changes between calls. -------------------------------------------------------------------------- Form: [aG, aS, aZ, aT] = AGravityC( r, nN, nM, d ) % structure [aG, aS, aZ, aT] = AGravityC( r, nN, nM, s, c, j, mu, a, useNormM ) -------------------------------------------------------------------------- ------ Inputs ------ r (3,:) Position vector, planet-fixed nN (1,1) Highest zonal harmonic (m = 0) (empty gives the max #) nM (1,1) Highest sectorial and tesseral harmonic (empty gives the max #) d (.) Gravity model struct -or- s (:,:) S terms c (:,:) C terms j (:) m = 0 terms mu (1,1) Spherical gravitational potential a (1,1) Planet radius useNormM (1,1) Generate the normalization matrix (default false) ------- Outputs ------- aG (3,:) Total gravitational acceleration km/sec^2 aS (3,:) Spherical term km/sec^2 aZ (3,:) Zonal term km/sec^2 aT (3,:) Tesseral term km/sec^2 -------------------------------------------------------------------------- Reference: Bond, V. R. and M. C. Allman (1996.) Modern Astrodynamics. Princeton. pp. 212-213. Lerch, F. J., Klosko, S. M., Labuscher, R. E., Wagner, C.A., "Gravity Model Improvement GEOS-3 (GEM 9 & 10)," N78-10645, September, 1977. Gottlieb, R. G., "Fast Gravity, Gravity Partials, Normalized Gravity, Gravity Graident Torque and Magnetic Field: Derivation, Code and Data, NASA CR 188243, February, 1993. -------------------------------------------------------------------------- See also UnnormalizeGravity, AGravity (output in spherical coords) --------------------------------------------------------------------------
Orbit: GravityModels/LoadGEM Orbit: GravityModels/NormalizationMatrix SC: SCMat/GEMT1 Common: CommonData/SwooshWatermark Common: General/CellToMat Common: General/DeBlankLT Common: General/DispWithTitle Common: General/MatToCell Common: General/Watermark Common: Graphics/Mesh2 Common: Graphics/NewFig Common: Graphics/Plot2D Common: Graphics/PltStyle Common: Graphics/XLabelS Common: Graphics/YLabelS Common: Graphics/ZLabelS Math: Linear/DupVect Math: Linear/Factorl
Back to the Orbit Module page