def __r_mtx_p(self): """ precession(歳差)変換行列(J2000.0 用) * 歳差の変換行列 P(ε, ψ, φ, γ) = R1(-ε) * R3(-ψ) * R1(φ) * R3(γ) 但し、R1, R2, R3 は x, y, z 軸の回転。 | 1 0 0 | | cosθ sinθ 0 | R1(θ) = | 0 cosθ sinθ |, R3(θ) = | -sinθ cosθ 0 | | 0 -sinθ cosθ | | 0 0 1 | | P_11 P_12 P_13 | P(ε, ψ, φ, γ) = | P_21 P_22 P_23 | とすると、 | P_31 P_32 P_33 | P_11 = cosψcosγ + sinψcosφsinγ P_12 = cosψsinγ - sinψcosφcosγ P_13 = -sinψsinφ P_21 = cosεsinψcosγ - (cosεcosψcosφ + sinεsinφ)sinγ P_22 = cosεsinψcosγ + (cosεcosψcosφ + sinεsinφ)cosγ P_23 = cosεcosψsinφ - sinεcosφ P_31 = sinεsinψcosγ - (sinεcosψcosφ - cosεsinφ)sinγ P_32 = sinεsinψcosγ + (sinεcosψcosφ - cosεsinφ)cosγ P_33 = sinεcosψsinφ + cosεcosφ :return np.matrix r: 変換行列 """ try: gam = self.__gamma_p() phi = self.__phi_p() psi = self.__psi_p() r = lmtx.r_z(gam) r = lmtx.r_x(phi, r) r = lmtx.r_z(-psi, r) r = lmtx.r_x(-self.eps, r) return r except Exception as e: raise
def __r_mtx_n(self): """ nutation(章動)変換行列 * IAU 2000A nutation with adjustments to match the IAU 2006 precession. :return np.matrix r: 変換行列 """ try: r = lmtx.r_x(self.eps) r = lmtx.r_z(-self.dpsi, r) r = lmtx.r_x(-self.eps - self.deps, r) return r except Exception as e: raise
def __r_mtx_b(self): """ Bias 変換行列(一般的な理論) * 赤道座標(J2000.0)の極は ICRS の極に対して12時(x軸のマイナス側)の 方向へ 17.3±0.2 mas、18時(y軸のマイナス側)の方向へ 5.1±0.2 mas ズレているので、変換する。 さらに、平均分点への変換はICRSでの赤経を78±10 mas、天の極を中心に 回転させる。 18時の方向の変換はx軸を-5.1mas回転 | 1 0 0 | R1(θ ) = | 0 cosθ sinθ | | 0 -sinθ cosθ | 12時の方向の変換はy軸を-17.3mas回転 | cosθ 0 -sinθ | R2(θ ) = | 0 1 0 | | sinθ 0 cosθ | 天の極を中心に78.0mas回転 | cosθ sinθ 0 | R3(θ ) = | -sinθ cosθ 0 | | 0 0 1 | :return np.matrix r: 回転行列 """ try: r = lmtx.r_x( -5.1 * lcst.MAS2R) r = lmtx.r_y(-17.3 * lcst.MAS2R, r) r = lmtx.r_z( 78.0 * lcst.MAS2R, r) return r except Exception as e: raise
def __r_mtx_pn(self): """ Precession + Nutation 変換行列 * IAU 2000A nutation with adjustments to match the IAU 2006 precession. :return np.matrix r: 変換行列 """ try: gam = self.__gamma_p() phi = self.__phi_p() psi = self.__psi_p() r = lmtx.r_z(gam) r = lmtx.r_x(phi, r) r = lmtx.r_z(-psi - self.dpsi, r) r = lmtx.r_x(-self.eps - self.deps, r) return r except Exception as e: raise
def __r_mtx_bpn(self): """ Bias + Precession + Nutation 変換行列 * IAU 2006 (Fukushima-Williams 4-angle formulation) 理論 :return np.matrix r: 変換行列 """ try: gam = self.__gamma_bp() phi = self.__phi_bp() psi = self.__psi_bp() r = lmtx.r_z(gam) r = lmtx.r_x(phi, r) r = lmtx.r_z(-psi - self.dpsi, r) r = lmtx.r_x(-self.eps - self.deps, r) return r except Exception as e: raise
def rect_ec2eq(rect, eps): """ 直交座標:黄道座標 -> 赤道座標. :param list rect: 黄道直交座標 :param float eps: 黄道傾斜角 (Unit: rad) :return list : 赤道直交座標 """ try: mtx_rect = np.matrix([rect]).transpose() r_mtx = lmtx.r_x(-eps) return lmtx.rotate(r_mtx, mtx_rect).A1.tolist() except Exception as e: raise