OB.DAAC Logo
NASA Logo
Ocean Color Science Software

ocssw V2022
llh2geocoord.py
Go to the documentation of this file.
1 def llh2geocoord(iyr,iday,lon,lat,hgt):
2  # output: geomat
3  # format data as input to geomag70.c
4  # Liang Hong, 2/24/2020
5 
6  from hawknav.jddate import jddate
7  from hawknav.jd import jd
8  import numpy as np
9 
10  nl = np.size(lon)
11  njday = jd(iyr,1,iday)
12  iy,mon,idy = jddate(njday)
13 
14  # row: iyr,mon,idy,fix(hgt(i)),lat(i),lon(i),format='(i4,2(",",i02)," D K",i3,2f9.3)'
15  geomat = np.column_stack((iyr*np.ones(nl),mon*np.ones(nl),idy*np.ones(nl),np.ones(nl),np.fix(hgt),lat,lon))
16 
17  return geomat
def llh2geocoord(iyr, iday, lon, lat, hgt)
Definition: llh2geocoord.py:1
Definition: jddate.py:1
Definition: jd.py:1