GPT and GMF

版本 2.0.0 (15.6 KB) 作者: Changyong He
Vectorized version of the Matlab code for the GMP and GPT models
46.0 次下载
更新时间 2019/10/19

查看许可证

Vectorized version of the Matlab code for the GMP and GPT models. Original Fortran and Matlab code can be found in IERS 2010 Conventions (http://iers-conventions.obspm.fr/conventions_versions.php#official_target) and
Vienna Mapping Functions Open Access Data (http://vmf.geo.tuwien.ac.at/codes/)

Test example (Matlab code):

n = 86400;
%% GMF
dmjd = 55055*ones(n,1);
dlat = 0.6708665767*ones(n,1);
dlon = -1.393397187*ones(n,1);
dhgt = 844.715*ones(n,1);
zd = 1.278564131*ones(n,1);
tic
[gmfh,gmfw] = gmf(dmjd,dlat,dlon,dhgt,zd);
toc
% Test case:
% given input: DMJD = 55055D0
% DLAT = 0.6708665767D0 radians (NRAO, Green Bank, WV)
% DLON = -1.393397187D0 radians
% DHGT = 844.715D0 meters
% ZD = 1.278564131D0 radians
%
% expected output: GMFH = 3.425245519339138678 11.064702723565059
% GMFW = 3.449589116182419257 11.313101285827178
fprintf('GMF %.15f\t%.15f\n', gmfh(1), gmfw(1));
fprintf('\n');

tic
[gmfh,gmfw] = gmf_deriv(dmjd,dlat,dlon,dhgt,zd);
toc
fprintf('GMF_deriv %.15f\t%.15f\t%.15f\t%.15f\n', gmfh(1,:), gmfw(1,:));
fprintf('\n');
%% GPT
dmjd = 55055*ones(n,1);
dlat = 0.6708665767*ones(n,1);
dlon = -1.393397187*ones(n,1);
dhgt = 812.546*ones(n,1);
tic
[pres,temp,undu] = gpt(dmjd , dlat , dlon , dhgt);
toc
% Test case:
% given input: DMJD = 55055D0
% DLAT = 0.6708665767D0 radians (NRAO, Green Bank, WV)
% DLON = -1.393397187D0 radians
% DHGT = 812.546 meters
% expected output: PRES = 918.0710638757363995D0 hPa
% TEMP = 19.31914181012882992D0 degrees Celsius
% UNDU = -42.19185643717770517D0 meters
fprintf('GPT %.15f\t%.15f\t%.15f\n', pres(1), temp(1), undu(1));
fprintf('\n');

Enjoy!

引用格式

Changyong He (2024). GPT and GMF (https://www.mathworks.com/matlabcentral/fileexchange/73066-gpt-and-gmf), MATLAB Central File Exchange. 检索来源 .

MATLAB 版本兼容性
创建方式 R2019b
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Error Detection and Correction 的更多信息
标签 添加标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
版本 已发布 发行说明
2.0.0

NaN

1.0.0