Function Helmert14.tryApply

Transform Earth-centred XYZ coordinates at an observation epoch.

bool tryApply(
  const GeocentricCoordinate!T source,
  const Epoch!T observationEpoch,
  out GeocentricCoordinate!T result
) const pure nothrow @nogc @safe;

The observation epoch controls how many years of parameter change are applied after the reference epoch. This checked call returns false rather than throwing on failure.

Example

Example applying a dynamic identity transform without throwing.

import geodesy;
const h = PositionVectorHelmert14!double.fromCanonical(
    PositionVectorHelmert!double.init,
    0, 0, 0, 0, 0, 0, 0,
    Epoch!double.fromDecimalYear(2000.0));
const source = GeocentricCoordinate!double.fromComponents(1, 2, 3);
GeocentricCoordinate!double target;
assert(h.tryApply(
    source,
    Epoch!double.fromDecimalYear(2020.0),
    target));
assert(target == source);