Class PolarCoordConverter


  • public class PolarCoordConverter
    extends java.lang.Object
    Ported to Java from the NGA GeoTrans polarst.c and polarst.h code.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      long convertGeodeticToPolarStereographic​(double Latitude, double Longitude)
      The function Convert_Geodetic_To_Polar_Stereographic converts geodetic coordinates (latitude and longitude) to Polar Stereographic coordinates (easting and northing), according to the current ellipsoid and Polar Stereographic projection parameters.
      long convertPolarStereographicToGeodetic​(double Easting, double Northing)
      The function Convert_Polar_Stereographic_To_Geodetic converts Polar Stereographic coordinates (easting and northing) to geodetic coordinates (latitude and longitude) according to the current ellipsoid and Polar Stereographic projection Parameters.
      double getEasting()  
      double getLatitude()  
      double getLongitude()  
      double getNorthing()  
      long setPolarStereographicParameters​(double a, double f, double Latitude_of_True_Scale, double Longitude_Down_from_Pole, double False_Easting, double False_Northing)
      The function setPolarStereographicParameters receives the ellipsoid parameters and Polar Stereograpic projection parameters as inputs, and sets the corresponding state variables.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • setPolarStereographicParameters

        public long setPolarStereographicParameters​(double a,
                                                    double f,
                                                    double Latitude_of_True_Scale,
                                                    double Longitude_Down_from_Pole,
                                                    double False_Easting,
                                                    double False_Northing)
        The function setPolarStereographicParameters receives the ellipsoid parameters and Polar Stereograpic projection parameters as inputs, and sets the corresponding state variables. If any errors occur, error code(s) are returned by the function, otherwise POLAR_NO_ERROR is returned.
        Parameters:
        a - Semi-major axis of ellipsoid, in meters
        f - Flattening of ellipsoid
        Latitude_of_True_Scale - Latitude of true scale, in radians
        Longitude_Down_from_Pole - Longitude down from pole, in radians
        False_Easting - Easting (X) at center of projection, in meters
        False_Northing - Northing (Y) at center of projection, in meters
        Returns:
        error code
      • convertGeodeticToPolarStereographic

        public long convertGeodeticToPolarStereographic​(double Latitude,
                                                        double Longitude)
        The function Convert_Geodetic_To_Polar_Stereographic converts geodetic coordinates (latitude and longitude) to Polar Stereographic coordinates (easting and northing), according to the current ellipsoid and Polar Stereographic projection parameters. If any errors occur, error code(s) are returned by the function, otherwise POLAR_NO_ERROR is returned.
        Parameters:
        Latitude - latitude, in radians
        Longitude - Longitude, in radians
        Returns:
        error code
      • getEasting

        public double getEasting()
      • getNorthing

        public double getNorthing()
      • convertPolarStereographicToGeodetic

        public long convertPolarStereographicToGeodetic​(double Easting,
                                                        double Northing)
        The function Convert_Polar_Stereographic_To_Geodetic converts Polar Stereographic coordinates (easting and northing) to geodetic coordinates (latitude and longitude) according to the current ellipsoid and Polar Stereographic projection Parameters. If any errors occur, the code(s) are returned by the function, otherwise POLAR_NO_ERROR is returned.
        Parameters:
        Easting - Easting (X), in meters
        Northing - Northing (Y), in meters
        Returns:
        error code
      • getLatitude

        public double getLatitude()
        Returns:
        Latitude in radians.
      • getLongitude

        public double getLongitude()
        Returns:
        Longitude in radians.