在python-ephem中,我无法得到某些星座的位置

2024-06-06 09:41:53 发布

您现在位置:Python中文网/ 问答频道 /正文

import ephem

date = '2018/9/20'

sun = ephem.Sun()
sun.compute(date)
print 'Sun in', list(ephem.constellation(sun))[1]

moon = ephem.Moon()
moon.compute(date)
print 'Moon in', list(ephem.constellation(moon))[1]

mars = ephem.Mars()
mars.compute(date)
print 'Mars in', list(ephem.constellation(mars))[1]

mercury = ephem.Mercury()
mercury.compute(date)
print 'Mercury in', list(ephem.constellation(mercury))[1]

jupiter = ephem.Jupiter()
jupiter.compute(date)
print 'Jupiter in', list(ephem.constellation(jupiter))[1]

venus = ephem.Venus()
venus.compute(date)
print 'Venus in', list(ephem.constellation(venus))[1]

saturn = ephem.Saturn()
saturn.compute(date)
print 'Saturn in', list(ephem.constellation(saturn))[1]

我已经在他们的房子里找到了7颗行星的具体日期。现在我需要在一张星盘上找到拉胡和克图的房子。怎么弄到的?它有什么功能吗?在


Tags: indatelistsunprintcomputejupitermars
1条回答
网友
1楼 · 发布于 2024-06-06 09:41:53

我很确定在ephem中只有真正的行星。我找到了这个定义

Astronomically, Rahu and Ketu denote the points of intersection of the paths of the Sun and the Moon as they move on the celestial sphere.

运用一些数学知识会告诉你要点。也许this可以帮助你转换不同系统之间的坐标。在

从这里你可以在ephem中导出一个视点,它被称为^{},并将其传递给ephem.constellation(o)

相关问题 更多 >