All Implemented Interfaces:
Serializable, Formattable, MathTransformProvider, Deprecable, LenientComparable, org.opengis.referencing.IdentifiedObject, org.opengis.referencing.operation.OperationMethod

public final class Molodensky extends GeocentricAffineBetweenGeographic
The provider for "Molodensky transformation" (EPSG:9604). This provider constructs transforms between two geographic reference systems without passing though a geocentric one. This class nevertheless extends GeocentricAffineBetweenGeographic because it is an approximation of GeocentricTranslation3D.

The translation terms (dx, dy and dz) are common to all authorities. But remaining parameters are specified in different ways depending on the authority:

  • EPSG defines "Semi-major axis length difference" and "Flattening difference" parameters.
  • OGC rather defines "src_semi_major", "src_semi_minor", "tgt_semi_major", "tgt_semi_minor" and "dim" parameters.
Since:
0.7
Version:
1.3
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      Serial number for inter-operability with different versions.
      See Also:
    • AXIS_LENGTH_DIFFERENCE

      public static final org.opengis.parameter.ParameterDescriptor<Double> AXIS_LENGTH_DIFFERENCE
      The operation parameter descriptor for the Semi-major axis length difference optional parameter value. This parameter is defined by the EPSG database and can be used in replacement of GeocentricAffineBetweenGeographic.TGT_SEMI_MAJOR. Units are metres.
      Parameter names
      EPSG: Semi-major axis length difference
      Notes:
      • No default value
    • FLATTENING_DIFFERENCE

      public static final org.opengis.parameter.ParameterDescriptor<Double> FLATTENING_DIFFERENCE
      The operation parameter descriptor for the Flattening difference optional parameter value. This parameter is defined by the EPSG database and can be used in replacement of GeocentricAffineBetweenGeographic.TGT_SEMI_MINOR. Valid values range from -1 to +1, dimensionless.
      Parameter names
      EPSG: Flattening difference
      Notes:
      • Value domain: [-1.0 … 1.0]
      • No default value
    • PARAMETERS

      public static final org.opengis.parameter.ParameterDescriptorGroup PARAMETERS
      The group of all parameters expected by this coordinate operation.
  • Constructor Details

    • Molodensky

      public Molodensky()
      Constructs a new provider.
    • Molodensky

      private Molodensky(int sourceDimensions, int targetDimensions, GeodeticOperation[] redimensioned)
      Constructs a provider for the given dimensions.
      Parameters:
      sourceDimensions - number of dimensions in the source CRS of this operation method.
      targetDimensions - number of dimensions in the target CRS of this operation method.
      redimensioned - providers for all combinations between 2D and 3D cases.
  • Method Details

    • internal

      @Debug public static org.opengis.parameter.ParameterDescriptorGroup internal()
      Creates a descriptor for the internal parameters of MolodenskyTransform. This is similar to the standard parameters except that the redundant target axes lengths are omitted.
      Returns:
      internal parameter descriptor.
    • createMathTransform

      public org.opengis.referencing.operation.MathTransform createMathTransform(org.opengis.referencing.operation.MathTransformFactory factory, org.opengis.parameter.ParameterValueGroup values) throws org.opengis.util.FactoryException
      Creates a Molodensky transform from the specified group of parameter values.
      Specified by:
      createMathTransform in interface MathTransformProvider
      Overrides:
      createMathTransform in class GeocentricAffineBetweenGeographic
      Parameters:
      factory - the factory to use for creating concatenated transforms.
      values - the group of parameter values.
      Returns:
      the created Molodensky transform.
      Throws:
      org.opengis.util.FactoryException - if a transform cannot be created.
    • createMathTransform

      static org.opengis.referencing.operation.MathTransform createMathTransform(org.opengis.referencing.operation.MathTransformFactory factory, Parameters values, int sourceDimensions, int targetDimensions, boolean isAbridged) throws org.opengis.util.FactoryException
      Creates a (potentially abridged) Molodensky transform from the specified group of parameter values. The specified number of dimensions are default values; they may be overridden by user parameters.
      Parameters:
      factory - the factory to use for creating concatenated transforms.
      values - the group of parameter values specified by the users.
      sourceDimensions - number of source dimensions (2 or 3) of the operation method.
      targetDimensions - number of target dimensions (2 or 3) of the operation method.
      isAbridged - true for the abridged form.
      Returns:
      the created (abridged) Molodensky transform.
      Throws:
      org.opengis.util.FactoryException - if a transform cannot be created.
    • optional

      private static double optional(Parameters values, org.opengis.parameter.ParameterDescriptor<Double> parameter)
      Returns the value of the given parameter, or NaN if undefined.
    • conditional

      private static double conditional(Parameters values, org.opengis.parameter.ParameterDescriptor<Double> parameter, double condition)
      Returns the value of the given parameter as a mandatory parameter if condition is NaN, or an optional parameter otherwise.