Function File: e, n, u = ecef2enu (x, y, z, lat0, lon0, alt0)
Function File: e, n, u = ecef2enu (x, y, z, lat0, lon0, alt0, spheroid)
Function File: e, n, u = ecef2enu (x, y, z, lat0, lon0, alt0, spheroid, angleUnit)

Convert Earth Centered Earth Fixed (ECEF) coordinates to local East, North, Up (ENU) coordinates.

Inputs:

  • x, y, z: ECEF coordinates of target points (length units equal to length unit of used referenceEllipsoid, of which the default is meters). Can be scalars but vectors and nD arrays are accepted if they have equal dimensions.
  • lat0, lon0, alt0: latitude, longitude and height of local observer point(s). Length unit of local height: see above. In case of multiple local locations their numbers and dimensions should match those of the target points (i.e., one observer location for each target point).
  • (Optional) spheroid: referenceEllipsoid specified as EPSG number, ellipsoid name, or parameter struct. An empty string ("") or empty numeric array ([]) is also accepted. Default is WGS84.
  • (Optional) angleUnit: string for angular units (’radians’ or ’degrees’), only the first letter matters. Default is ’d’: degrees.

Outputs:

  • e, n, u: East, North, Up local cartesian coordinates of target point(s) (default length unit that of invoked referenceEllipsoid, of which the default is meters).

Example:

[e, n, u] = ecef2enu (660930, -4701424, 4246579, 42, -82, 200, ...
                      "wgs84", "degrees")
-->
     e =  186.12
     n =  286.56
     u =  939.10

See also: enu2ecef, ecef2enuv, ecef2geodetic, ecef2ned, ecef2enu, referenceEllipsoid.

Package: mapping