GPT and GMF
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!
Zitieren als
Changyong He (2024). GPT and GMF (https://www.mathworks.com/matlabcentral/fileexchange/73066-gpt-and-gmf), MATLAB Central File Exchange. Abgerufen .
Kompatibilität der MATLAB-Version
Plattform-Kompatibilität
Windows macOS LinuxKategorien
- Wireless Communications > Communications Toolbox > PHY Components > Error Detection and Correction >
Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Live Editor erkunden
Erstellen Sie Skripte mit Code, Ausgabe und formatiertem Text in einem einzigen ausführbaren Dokument.
Version | Veröffentlicht | Versionshinweise | |
---|---|---|---|
2.0.0 | NaN |
||
1.0.0 |