,name = c("Oktyabrskiy-Gorodok", "Pogranichnyi", "Napas", "Vanavara")
test_that("*mgtdhid* produces wrong results", {
test_that("*mgtdhidt* produces wrong results", {
#    mgtdhidt(tau = as.integer(seq.int(0, 8736, by = 1)), depth = d24)[11:20] -
mgtdhidt(tau = hours, id = 28434L, depth = d24),
mgtdhidt(tau = hours, id = 28418L, depth = d24),
mgtdhidt(tau = hours, id = 28630L, depth = d24)
test_that("*mgtdhgeot* produces wrong results", {
mgtdhid(id = 28434L, tau = 1440L, depth = d24)
,mgtdhid(id = 28434L, tau = 1450L, depth = d24)
,mgtdhid(id = 28434L, tau = 1540L, depth = d24)
test_that("*mgtdhgeot* and others produce wrong results without execution parallelization", {
mgtdhgeo(head(lat, 3), head(lon, 3), tau = 1440L, depth = d24),
mgtdhgeo(lat[["CP2"]], lon[["CP2"]], tau = 1440L, depth = d24),
) %*% drop(1/sapply(r, function(x) sum((x/r)^2)))
mgtdhgeot(tau = 1440L, lat[["CP2"]], lon[["CP2"]], depth = d24),
test_that("*mgtdhgeot* and others produce wrong results utilizing parallel execution (if possible)", {
mgtdhgeo(head(lat, 3), head(lon, 3), tau = 1440L, depth = d24, use_cluster = !nzchar(Sys.getenv("_R_CHECK_LIMIT_CORES_", ""))),
mgtdhgeo(lat[["CP1"]], lon[["CP1"]], tau = as.POSIXct("2023-03-02"), depth = d24, use_cluster = !nzchar(Sys.getenv("_R_CHECK_LIMIT_CORES_", ""))),
mgtdhgeo(lat[["CP2"]], lon[["CP2"]], tau = 1440L, depth = d24, use_cluster = !nzchar(Sys.getenv("_R_CHECK_LIMIT_CORES_", ""))),
mgtdhgeo(lat[["CP2"]], lon[["CP2"]], tau = as.POSIXct("2023-03-02"), depth = d24, use_cluster = !nzchar(Sys.getenv("_R_CHECK_LIMIT_CORES_", "")))
,mgtdhgeo(lat[["CP2"]], lon[["CP2"]], tau = as.POSIXct("2023-03-02") + 3600 * 10, depth = d24, use_cluster = !nzchar(Sys.getenv("_R_CHECK_LIMIT_CORES_", "")))
,mgtdhgeo(lat[["CP2"]], lon[["CP2"]], tau = as.POSIXct("2023-03-02") + 3600 * 100, depth = d24, use_cluster = !nzchar(Sys.getenv("_R_CHECK_LIMIT_CORES_", "")))

"*mgtdhgeot* and others produce wrong results without execution parallelization"
# Google maps distances from CP2 to the nearest stations, [m]
"*mgtdhgeot* and others produce wrong results utilizing parallel execution (if possible)"