Added Haversine distance operation

This operation calculates the great circle distance between two GPS co-ordinates, returning the value
This commit is contained in:
Luke Lanchester 2018-08-03 18:20:38 +01:00
parent 4ca14ed0ce
commit 87b77215e4
4 changed files with 82 additions and 0 deletions

View file

@ -0,0 +1,22 @@
/**
* Haversine distance tests.
*
* @author Dachande663 [dachande663@gmail.com]
* @copyright Crown Copyright 2018
* @license Apache-2.0
*/
import TestRegister from "../../TestRegister";
TestRegister.addTests([
{
name: "Haversine distance",
input: "51.487263,-0.124323, 38.9517,-77.1467",
expectedOutput: "5619355.701829259",
recipeConfig: [
{
"op": "Haversine distance",
"args": []
}
],
}
]);