classdef (Hidden) Constants
    %   This class is for internal use only. It may be removed in the future.
    
    %   Copyright 2018 The MathWorks, Inc.
    
    %#codegen
    
    properties(Constant)
        %SpeedOfLight  Speed of light in a vacuum in m/s
        SpeedOfLight = 299792458

        %WGS84SemimajorAxis Earth's semimajor axis in World Geodetic System 1984 Model in m
        WGS84SemimajorAxis = 6378137

        %WGS84Flattening Earth's flattening in World Geodetic System 1984 Model
        WGS84Flattening = 1/298.257223563
    end

    methods (Static)
        function Re = wgs84MeanEarthRadius()
            % Compute the Earth's mean radius as defined by International Union of
            % Geodesy and Geophysics (IUGG)

            % semi-minor axis (meters)
            b = fusion.internal.Constants.WGS84SemimajorAxis*(1-fusion.internal.Constants.WGS84Flattening);
            % mean radius as defined by International Union of Geodesy and Geophysics (IUGG)
            Re = (2*fusion.internal.Constants.WGS84SemimajorAxis+b)/3;
        end
    end
end