Compute the latitude, longitude and orthometric
height of the summit of the Matterhorn (Monte Cervino) from its azimuth,
elevation and (slant) range relative to Zermatt, Switzerland. All
distances and lengths are in meters.

Origin (reference point): Zermatt.

fmt = get(0,'Format');
format short g
lat0 = dm2degrees([46 1]) % convert degree-minutes to degrees
lon0 = dm2degrees([ 7 45])
hOrthometric0 = 1620;
hGeoid = 53;
h0 = hOrthometric0 + hGeoid

lat0 =
46.017
lon0 =
7.75
h0 =
1673

Azimuth, elevation, and slant range to Matterhorn summit.

az = 237.8;
elev = 18.755;
slantRange = 8871.7;

Latitude, longitude, and ellipsoidal height of summit.

[lat, lon, hEllipsoidal] = aer2geodetic( ...
az, elev, slantRange, lat0, lon0, h0, wgs84Ellipsoid)

lat =
45.976
lon =
7.6583
hEllipsoidal =
4531

Orthometric height of summit.

hGeoid = 53;
hOrthometric = hEllipsoidal - hGeoid
format(fmt)

hOrthometric =
4478