Files
astro/moon/nodes.go
T

30 lines
1019 B
Go
Raw Normal View History

2026-05-01 22:38:44 +08:00
package moon
import (
"time"
"b612.me/astro/basic"
)
// AscendingNode 月球升交点黄经 / ascending node longitude of the Moon.
func (module *Moon) AscendingNode(date time.Time) float64 {
return module.AscendingNodeN(date, -1)
2026-05-01 22:38:44 +08:00
}
// AscendingNodeN 月球升交点黄经(n 变体) / n-parameterised ascending node longitude of the Moon.
func (module *Moon) AscendingNodeN(date time.Time, n int) float64 {
jde := basic.UTC2TT(basic.Date2JD(date.UTC()))
return basic.MoonAscendingNodeNWithInstance(jde, n, module.inst)
2026-05-01 22:38:44 +08:00
}
// DescendingNode 月球降交点黄经 / descending node longitude of the Moon.
func (module *Moon) DescendingNode(date time.Time) float64 {
return module.DescendingNodeN(date, -1)
2026-05-01 22:38:44 +08:00
}
// DescendingNodeN 月球降交点黄经(n 变体) / n-parameterised descending node longitude of the Moon.
func (module *Moon) DescendingNodeN(date time.Time, n int) float64 {
jde := basic.UTC2TT(basic.Date2JD(date.UTC()))
return basic.MoonDescendingNodeNWithInstance(jde, n, module.inst)
2026-05-01 22:38:44 +08:00
}