4

为了帮助我计算国际空间站的视觉大小,我需要能够计算相位角。

谁能帮我计算一下?

在任何时候,我ObsISS使用PyEphem. 对于观察者,我有到Alt/Az太阳的距离......当然,我有来自观察者的(以公里为单位)。所以在我看来,我应该能够用“简单”的几何形状计算相位角。不幸的是,这个简单的几何形状有点超出我能够自信地解决的能力(我想自从我上次这样做以来已经太久了)。ISSAlt/AzISS.range

答案:我想通了(在旧互联网的帮助下)这是一个部分代码片段(Leandro Guedes 更新了 ephem.earth_radius 到 Km 的更正)

 # SSA Triangle.  We have side a and b and angle C.  Need to solve to find side c 
 a = sun.earth_distance * au - ephem.earth_radius/1000 #distance sun from observer (Km)
 b = iss.range / 1000 # distance to ISS from observer (Km)
 angle_c = ephem.separation( (iss.az, iss.alt), ( sun.az, sun.alt) ) 
 c = math.sqrt( math.pow(a,2) + math.pow(b,2) - 2*a*b*math.cos( angle_c) )
 # now we find the "missing" angles (of which angle A is the one we need)
 angle_a = math.acos((math.pow(b,2) + math.pow( c,2) - math.pow(a,2)) / (2 * b * c)) 
 angle_b = math.pi - angle_a - angle_c #note: this is basically ZERO - not a big surprise really - and I don't need this anyway.
 phase_angle = angle_a # This is the angle we need.  BINGO!!
4

2 回答 2

0

由于angle_b几乎为零(近日点和国际空间站直接在头顶上的最大 0.00016 度),你可以只做angle_a = math.pi - angle_c.

这具有大致相同的准确性,因为您已经在距离方面犯了一些小错误a

于 2020-01-09T16:30:17.543 回答
0

答案:我想通了(在旧互联网的帮助下)这是一个部分代码片段(Leandro Guedes 更新了 ephem.earth_radius 到 Km 的更正)

 # SSA Triangle.  We have side a and b and angle C.  Need to solve to find side c 
 a = sun.earth_distance * au - ephem.earth_radius/1000 #distance sun from observer (Km)
 b = iss.range / 1000 # distance to ISS from observer (Km)
 angle_c = ephem.separation( (iss.az, iss.alt), ( sun.az, sun.alt) ) 
 c = math.sqrt( math.pow(a,2) + math.pow(b,2) - 2*a*b*math.cos( angle_c) )
 # now we find the "missing" angles (of which angle A is the one we need)
 angle_a = math.acos((math.pow(b,2) + math.pow( c,2) - math.pow(a,2)) / (2 * b * c)) 
 angle_b = math.pi - angle_a - angle_c #note: this is basically ZERO - not a big surprise really - and I don't need this anyway.
 phase_angle = angle_a # This is the angle we need.  BINGO!!

(正式将我的答案发布为实际答案 - 是的 - 我花了一段时间才弄清楚这就是我应该一直做的)。

于 2019-04-23T04:30:35.780 回答