如何验证皮弗姆的结果



我想看看"在我的天空中"我能看到多少颗卫星。我正在使用以下代码:

sat_alt, sat_az, sat_name = [], [], []
observer = ephem.Observer()
observer.long = Longitude
observer.lat = Latitude
observer.date = TimeNow
HowMany = 0
print "TIME: ", TimeNow
print
GPS_list = 'http://www.celestrak.com/NORAD/elements/gps-ops.txt'
GPS2_list = 'http://www.tle.info/data/gps-ops.txt'
GLONASS_list = 'http://www.celestrak.com/NORAD/elements/glo-ops.txt'
GLONASS2_list = 'http://www.tle.info/data/glo-ops.txt'
#'http://www.amsat.org/amsat/ftp/keps/current/nasabare.txt').readlines()

tles = urllib2.urlopen(GPS_list).readlines() 
tles = [item.strip() for item in tles]
tles = [(tles[i],tles[i+1],tles[i+2]) for i in xrange(0,len(tles)-2,3)]
for tle in tles:
    try:
        sat = ephem.readtle(tle[0], tle[1], tle[2])
        rt, ra, tt, ta, st, sa = observer.next_pass(sat)
        if rt is not None and st is not None:
            sat.compute(observer)
            if TimeNow >= ephem.localtime(st) and TimeNow <= ephem.localtime(rt):
                text = tle[0]
                sat_alt.append(np.rad2deg(sat.alt))
                sat_az.append(np.rad2deg(sat.az))
                text2 = text.rsplit(')', 1)[0]
                NamePRN = text2.rsplit('(', 1)[1]
                sat_name.append(NamePRN)
                #I wanna Try just with the PRN 1
                if 1 == 1: # NamePRN = 'PRN 01':
                    print NamePRN
                    print "Elev:" , np.rad2deg(sat.alt), "Azimuth: ",np.rad2deg(sat.az) #sat.alt / ephem.degree
                    print "original rise time: ",rt
                    print 'rise time: ', ephem.localtime(rt)
                    print 'set time: ',  ephem.localtime(st) 
                    print
                    print 'Time until rise: ', ephem.localtime(rt) - TimeNow
                    print 'Time until set: ',ephem.localtime(st) - TimeNow
                    timeuntilrise = ephem.localtime(rt)-TimeNow
                    HowMany += 1
                    minutesaway = timeuntilrise.seconds/60.0
                    if sys.platform == 'darwin':
                        say = 'say "%s WILL BE MAKING A PASS IN %d MINUTES."' % (NamePRN,minutesaway)
                        os.system(say)
                    else:
                        print "Minutes Away: ",minutesaway

            #print ' Rise Azimuth: ', ra
            #print ' Transit Time: ', tt
            #print ' Transit Altitude: ', ta
            #print ' Set Time: ', st
            #print ' Set Azimuth: ', sa
            #print 'rise time: ', ephem.localtime(rt)
            #print 'set time: ',  ephem.localtime(st)
            #print
    except ValueError as e:
        print e
print
print "How Many: ", HowMany

结果是:

TIME:  2017-03-23 09:32:30.445831
PRN 14
Elev: 23.5719168541 Azimuth:  186.783257119
original rise time:  2017/3/23 18:15:23
rise time:  2017-03-23 13:15:23.000003
set time:  2017-03-23 05:56:40.000003
Time until rise:  3:42:52.554172
Time until set:  -1 day, 20:24:09.554172
Minutes Away:  222.866666667
PRN 22
Elev: 27.8617383982 Azimuth:  135.529777134
original rise time:  2017/3/23 18:59:39
rise time:  2017-03-23 13:59:38.000003
set time:  2017-03-23 05:52:54.000003
Time until rise:  4:27:07.554172
Time until set:  -1 day, 20:20:23.554172
Minutes Away:  267.116666667
PRN 19
Elev: 63.2536032619 Azimuth:  23.0164551349
original rise time:  2017/3/23 19:01:01
rise time:  2017-03-23 14:01:00.000003
set time:  2017-03-23 07:01:07.000003
Time until rise:  4:28:29.554172
Time until set:  -1 day, 21:28:36.554172
Minutes Away:  268.483333333
PRN 23
Elev: 2.50815303871 Azimuth:  88.104092255
original rise time:  2017/3/23 21:33:06
rise time:  2017-03-23 16:33:06.000003
set time:  2017-03-23 08:35:45.000003
Time until rise:  7:00:35.554172
Time until set:  -1 day, 23:03:14.554172
Minutes Away:  420.583333333
PRN 17
Elev: 43.5586196015 Azimuth:  52.03302655
original rise time:  2017/3/23 18:27:16
rise time:  2017-03-23 13:27:15.000003
set time:  2017-03-23 06:12:30.000003
Time until rise:  3:54:44.554172
Time until set:  -1 day, 20:39:59.554172
Minutes Away:  234.733333333
PRN 31
Elev: 7.61244305169 Azimuth:  168.667710308
original rise time:  2017/3/23 19:47:23
rise time:  2017-03-23 14:47:23.000003
set time:  2017-03-23 08:03:23.000003
Time until rise:  5:14:52.554172
Time until set:  -1 day, 22:30:52.554172
Minutes Away:  314.866666667
PRN 12
Elev: 48.18881167 Azimuth:  258.782917613
original rise time:  2017/3/23 18:42:38
rise time:  2017-03-23 13:42:38.000003
set time:  2017-03-23 07:35:56.000003
Time until rise:  4:10:07.554172
Time until set:  -1 day, 22:03:25.554172
Minutes Away:  250.116666667
PRN 25
Elev: 18.8269690697 Azimuth:  222.58247788
original rise time:  2017/3/23 19:39:10
rise time:  2017-03-23 14:39:09.000003
set time:  2017-03-23 08:34:40.000003
Time until rise:  5:06:38.554172
Time until set:  -1 day, 23:02:09.554172
Minutes Away:  306.633333333
PRN 01
Elev: 9.20983988345 Azimuth:  117.518172142
original rise time:  2017/3/23 17:53:54
rise time:  2017-03-23 12:53:54.000003
set time:  2017-03-23 04:56:06.000003
Time until rise:  3:21:23.554172
Time until set:  -1 day, 19:23:35.554172
Minutes Away:  201.383333333
PRN 24
Elev: 15.4381621753 Azimuth:  284.908746358
original rise time:  2017/3/23 16:23:16
rise time:  2017-03-23 11:23:16.000003
set time:  2017-03-23 05:14:38.000003
Time until rise:  1:50:45.554172
Time until set:  -1 day, 19:42:07.554172
Minutes Away:  110.75
PRN 06
Elev: 49.0638613556 Azimuth:  345.92883678
original rise time:  2017/3/23 20:57:05
rise time:  2017-03-23 15:57:04.000003
set time:  2017-03-23 08:25:55.000003
Time until rise:  6:24:33.554172
Time until set:  -1 day, 22:53:24.554172
Minutes Away:  384.55
PRN 03
Elev: 41.016662249 Azimuth:  109.881781593
original rise time:  2017/3/23 19:45:53
rise time:  2017-03-23 14:45:53.000003
set time:  2017-03-23 06:43:35.000003
Time until rise:  5:13:22.554172
Time until set:  -1 day, 21:11:04.554172
Minutes Away:  313.366666667
PRN 32
Elev: 13.6017761707 Azimuth:  207.711749038
original rise time:  2017/3/23 17:23:22
rise time:  2017-03-23 12:23:22.000003
set time:  2017-03-23 05:14:55.000003
Time until rise:  2:50:51.554172
Time until set:  -1 day, 19:42:24.554172
Minutes Away:  170.85
How Many:  13

我正在检查菜单"轨道卫星"中的"http://www.n2yo.com/"页面>"GPS 卫星"但是我怎么能看到我是否正确? 另一个网页?谢谢。

Calsky和n2yo可以从某个位置查看方位角和高程。 在卡尔斯基显示默认,25º以上的卫星

对于在线工具,我真的发现 in-the-sky.org 有用和有帮助的。它是相当新的,现代的,并且由活跃的空间专家和Web开发人员维护良好。看到这个和这个。

另一个python检查可以用Skyfield完成。它由维护PyEphem的同一个人维护,但又是更新和现代化的。Skyfield在内部与PyEphem完全不同,它们具有不同的功能集。 在 stackoverflow 中看到所有这些,然后在太空探索 SE 中看到所有这些,然后在天文学 SE 中看到所有这些!

相关内容

  • 没有找到相关文章

最新更新