Documentation ¶
Overview ¶
Node: Chapter 39, Passages through the Nodes.
Index ¶
- func EllipticAscending(axis, ecc float64, argP unit.Angle, timeP float64) (jde, r float64)
- func EllipticDescending(axis, ecc float64, argP unit.Angle, timeP float64) (jde, r float64)
- func ParabolicAscending(q float64, argP unit.Angle, timeP float64) (jde, r float64)
- func ParabolicDescending(q float64, argP unit.Angle, timeP float64) (jde, r float64)
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EllipticAscending ¶
EllipticAscending computes time and distance of passage through the ascending node of a body in an elliptical orbit.
Argument axis is semimajor axis in AU, ecc is eccentricity, argP is argument of perihelion, timeP is time of perihelion as a jd.
Result is jde of the event and distance from the sun in AU.
Example ¶
package main import ( "fmt" "time" "github.com/soniakeys/meeus/v3/julian" "github.com/soniakeys/meeus/v3/node" "github.com/soniakeys/unit" ) func main() { // Example 39.a, p. 276 t, r := node.EllipticAscending(17.9400782, .96727426, unit.AngleFromDeg(111.84644), julian.CalendarGregorianToJD(1986, 2, 9.45891)) y, m, d := julian.JDToCalendar(t) fmt.Printf("%d %s %.2f\n", y, time.Month(m), d) fmt.Printf("%.4f AU\n", r) }
Output: 1985 November 9.16 1.8045 AU
Example (Venus) ¶
package main import ( "fmt" "time" "github.com/soniakeys/meeus/v3/julian" "github.com/soniakeys/meeus/v3/node" "github.com/soniakeys/meeus/v3/perihelion" "github.com/soniakeys/meeus/v3/planetelements" ) func main() { // Example 39.c, p. 278 var k planetelements.Elements planetelements.Mean(planetelements.Venus, julian.CalendarGregorianToJD(1979, 1, 1), &k) t, _ := node.EllipticAscending(k.Axis, k.Ecc, k.Peri-k.Node, perihelion.Perihelion(perihelion.Venus, 1979)) y, m, d := julian.JDToCalendar(t) fmt.Printf("%d %s %.3f\n", y, time.Month(m), d) }
Output: 1978 November 27.409
func EllipticDescending ¶
EllipticDescending computes time and distance of passage through the descending node of a body in an elliptical orbit.
Argument axis is semimajor axis in AU, ecc is eccentricity, argP is argument of perihelion, timeP is time of perihelion as a jd.
Result is jde of the event and distance from the sun in AU.
Example ¶
package main import ( "fmt" "time" "github.com/soniakeys/meeus/v3/julian" "github.com/soniakeys/meeus/v3/node" "github.com/soniakeys/unit" ) func main() { // Example 39.a, p. 276 t, r := node.EllipticDescending(17.9400782, .96727426, unit.AngleFromDeg(111.84644), julian.CalendarGregorianToJD(1986, 2, 9.45891)) y, m, d := julian.JDToCalendar(t) fmt.Printf("%d %s %.2f\n", y, time.Month(m), d) fmt.Printf("%.4f AU\n", r) }
Output: 1986 March 10.37 0.8493 AU
func ParabolicAscending ¶
ParabolicAscending computes time and distance of passage through the ascending node of a body in a parabolic orbit.
Argument q is perihelion distance in AU, argP is argument of perihelion, timeP is time of perihelion as a jd.
Result is jde of the event and distance from the sun in AU.
Example ¶
package main import ( "fmt" "time" "github.com/soniakeys/meeus/v3/julian" "github.com/soniakeys/meeus/v3/node" "github.com/soniakeys/unit" ) func main() { // Example 29.b, p. 277 t, r := node.ParabolicAscending(1.324502, unit.AngleFromDeg(154.9103), julian.CalendarGregorianToJD(1989, 8, 20.291)) y, m, d := julian.JDToCalendar(t) fmt.Printf("%d %s %d\n", y, time.Month(m), int(d)) fmt.Printf("%.2f AU\n", r) }
Output: 1977 September 17 28.07 AU
func ParabolicDescending ¶
ParabolicDescending computes time and distance of passage through the descending node of a body in a parabolic orbit.
Argument q is perihelion distance in AU, argP is argument of perihelion, timeP is time of perihelion as a jd.
Result is jde of the event and distance from the sun in AU.
Example ¶
package main import ( "fmt" "time" "github.com/soniakeys/meeus/v3/julian" "github.com/soniakeys/meeus/v3/node" "github.com/soniakeys/unit" ) func main() { // Example 29.b, p. 277 t, r := node.ParabolicDescending(1.324502, unit.AngleFromDeg(154.9103), julian.CalendarGregorianToJD(1989, 8, 20.291)) y, m, d := julian.JDToCalendar(t) fmt.Printf("%d %s %.3f\n", y, time.Month(m), d) fmt.Printf("%.4f AU\n", r) }
Output: 1989 September 17.636 1.3901 AU
Types ¶
This section is empty.