matlab geoid,Calculate geoid height as determined from EGM96 Geopotential Model

该函数根据EGM96地球重力位模型计算地壳高度,精度达到0.01米。它从15分钟间隔的网格点值中插值获取潮汐自由系统的地壳高度,并将地壳凹凸相对于WGS84椭球体进行计算。当输入的经纬度超出范围时,函数会进行相应处理,如警告或错误。提供的示例展示了在不同位置计算地壳高度的方法。
摘要由CSDN通过智能技术生成

geoidegm96

Calculate geoid height as determined from EGM96 Geopotential

Model

Note

geoidegm96 will be removed in a future

version. Use geoidheight instead.

Syntax

N = geoidegm96(lat, long)

N = geoidegm96(lat, long, action)

Description

N = geoidegm96(lat, long) calculates the

geoid height as determined from the EGM96 Geopotential Model. It calculates

geoid heights to 0.01 meters. This function interpolates geoid heights

from a 15-minute grid of point values in the tide-free system, using

the EGM96 Geopotential Model to the degree and order 360. The geoid

undulations are relative to the WGS84 ellipsoid.

N = geoidegm96(lat, long, action) calculates

the geoid height as determined from the EGM96 Geopotential Model.

This function performs action if latitude or longitude are

out of range.

Inputs required by geoidegm96:

latAn array of m geocentric latitudes, in degrees,

where north latitude is positive and south latitude is negative. lat must

be of type single or double. If lat is not within

the range -90 to 90, inclusive, this function wraps the value to be

within the range.

longAn array of m geocentric longitudes, in

degrees, where east longitude is positive and west longitude is negative. long must

be of type single or double. If long is not within

the range 0 to 360 inclusive, this function wraps the value to be

within the range.

actionAction for out-of-range input. Specify if out-of-range input

invokes a 'Warning', 'Error',

or no action ('None'). The default is 'Warning'.

Examples

Calculate the geoid height at 42.4 degrees N latitude and 71.0

degrees E longitude.

N = geoidegm96( 42.4, 71.0)

Calculate the geoid height at two different locations, with

out-of-range actions generating warnings.

N = geoidegm96( [39.3,33.4], [-77.2, 36.5])

Calculate the geoid height with latitude wrapping, with out-of-range

actions displaying no warnings.

N = geoidegm96(100,150,'None')

Limitations

This function has the limitations of the 1996 Earth Geopotential Model. For more information,

see

The WGS84 EGM96 geoid undulations have an error range of +/-0.5

to +/-1.0 meters worldwide.

References

NIMA TR8350.2: “Department of Defense World Geodetic

System 1984, Its Definition and Relationship with Local Geodetic Systems.”

NASA/TP-1998-206861: “The Development of the Joint NASA

GSFC and NIMA Geopotential Model EGM96”

Introduced in R2007b

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
非常抱歉给您造成了困扰,可能是因为代码中的一些问题导致了计算结果不正确。我们可以尝试使用另一种方法来计算大地高。 在C语言中,可以使用EGM96的高斯反算公式来计算大地高。以下是示例代码: ```c #include <math.h> #define EGM96_A 6378136.3 // EGM96椭球体长半轴 #define EGM96_F 0.00335281969 // EGM96椭球体扁率 double egm96_geoid_height(double lat, double lon, double height) { double sin_lat = sin(lat); double cos_lat = cos(lat); double sin_lon = sin(lon); double cos_lon = cos(lon); double N = EGM96_A / sqrt(1.0 - EGM96_F * (2.0 - EGM96_F) * sin_lat * sin_lat); double X = (N + height) * cos_lat * cos_lon; double Y = (N + height) * cos_lat * sin_lon; double Z = (N * (1.0 - EGM96_F * EGM96_F) + height) * sin_lat; double X0, Y0, Z0; double dX, dY, dZ; double R; double lat0, lon0, h0; double sin_lat0, cos_lat0, sin_lon0, cos_lon0; // 定义EGM96的重心参数 X0 = 0.0; Y0 = 0.0; Z0 = 0.0; // 定义EGM96椭球体参数 double a = EGM96_A; double b = EGM96_A * (1.0 - EGM96_F); // 定义迭代精度 double eps = 1e-9; // 迭代计算大地高 do { lat0 = atan(Z / sqrt(X * X + Y * Y)); sin_lat0 = sin(lat0); cos_lat0 = cos(lat0); lon0 = atan2(Y, X); sin_lon0 = sin(lon0); cos_lon0 = cos(lon0); R = sqrt(X * X + Y * Y + Z * Z); dX = -a * sin_lat0 * cos_lon0; dY = -a * sin_lat0 * sin_lon0; dZ = b * cos_lat0; X0 += dX; Y0 += dY; Z0 += dZ; } while (sqrt(dX * dX + dY * dY + dZ * dZ) > eps); h0 = sqrt(X0 * X0 + Y0 * Y0 + Z0 * Z0) - R; return h0; } ``` 这段代码中,`lat`为当前位置的纬度,`lon`为当前位置的经度,`height`为当前位置的WGS84椭球面高。函数返回当前位置的EGM96数值。 需要注意的是,这里使用的是EGM96模型,也可以使用其他的数学模型来描述大地水准面的形状,不同的模型之间可能会有一定的误差。 如果您仍然发现计算结果不正确,请告诉我更多信息,我将尽力帮助您解决问题。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值