Skip to content

Commit 1258ec0

Browse files
committed
Nit: fix consistent use of n² variable
1 parent 761587c commit 1258ec0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

osgridref.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ class OsGridRef {
104104
φ = (N-N0-M)/(a*F0) + φ;
105105

106106
const Ma = (1 + n + (5/4)*n2 + (5/4)*n3) * (φ-φ0);
107-
const Mb = (3*n + 3*n*n + (21/8)*n3) * Math.sin(φ-φ0) * Math.cos(φ+φ0);
107+
const Mb = (3*n + 3*n2 + (21/8)*n3) * Math.sin(φ-φ0) * Math.cos(φ+φ0);
108108
const Mc = ((15/8)*n2 + (15/8)*n3) * Math.sin(2*(φ-φ0)) * Math.cos(2*(φ+φ0));
109109
const Md = (35/24)*n3 * Math.sin(3*(φ-φ0)) * Math.cos(3*(φ+φ0));
110110
M = b * F0 * (Ma - Mb + Mc - Md); // meridional arc
@@ -296,7 +296,7 @@ class LatLon_OsGridRef extends LatLonEllipsoidal {
296296
const η2 = ν/ρ-1; // eta = ?
297297

298298
const Ma = (1 + n + (5/4)*n2 + (5/4)*n3) * (φ-φ0);
299-
const Mb = (3*n + 3*n*n + (21/8)*n3) * Math.sin(φ-φ0) * Math.cos(φ+φ0);
299+
const Mb = (3*n + 3*n2 + (21/8)*n3) * Math.sin(φ-φ0) * Math.cos(φ+φ0);
300300
const Mc = ((15/8)*n2 + (15/8)*n3) * Math.sin(2*(φ-φ0)) * Math.cos(2*(φ+φ0));
301301
const Md = (35/24)*n3 * Math.sin(3*(φ-φ0)) * Math.cos(3*(φ+φ0));
302302
const M = b * F0 * (Ma - Mb + Mc - Md); // meridional arc

0 commit comments

Comments
 (0)