/// <inheritdoc /> protected override void OnInverse(double[] xy, double[] lp, int startIndex, int numPoints) { for (int i = startIndex; i < startIndex + numPoints; i++) { int phi = i * 2 + PHI; int lam = i * 2 + LAMBDA; int x = i * 2 + X; int y = i * 2 + Y; lp[phi] = xy[y] / CY; lp[lam] = xy[x] / (CX * (CA + Proj.Asqrt(1 - CB * lp[phi] * lp[phi]))); } }
/// <inheritdoc /> protected override void OnForward(double[] lp, double[] xy, int startIndex, int numPoints) { for (int i = startIndex; i < startIndex + numPoints; i++) { int phi = i * 2 + PHI; int lam = i * 2 + LAMBDA; int x = i * 2 + X; int y = i * 2 + Y; xy[y] = CY * lp[phi]; xy[x] = CX * lp[lam] * (CA + Proj.Asqrt(1 - CB * lp[phi] * lp[phi])); } }
/// <summary> /// The inverse transform from linear units to geodetic units /// </summary> /// <param name="xy">The double values for the input x and y values stored in an array</param> /// <param name="lp">The double values for the output lambda and phi values stored in an array</param> protected override void OnInverse(double[] xy, double[] lp) { lp[Phi] = xy[Y] / Cy; lp[Lambda] = xy[X] / (Cx * (Ca + Proj.Asqrt(1 - Cb * lp[Phi] * lp[Phi]))); }
/// <summary> /// The forward transform from geodetic units to linear units /// </summary> /// <param name="lp">The array of lambda, phi coordinates</param> /// <param name="xy">The array of x, y coordinates</param> protected override void OnForward(double[] lp, double[] xy) { xy[Y] = Cy * lp[Phi]; xy[X] = Cx * lp[Lambda] * (Ca + Proj.Asqrt(1 - Cb * lp[Phi] * lp[Phi])); }