Esempio n. 1
0
func ExampleSouth() {
	// Example 52.b, p. 370.
	j, δ := moonmaxdec.South(2049.3)
	fmt.Printf("JDE = %.4f\n", j)
	y, m, d := julian.JDToCalendar(j)
	d, f := math.Modf(d)
	fmt.Printf("%d %s %d at %0.64d TD\n", y, time.Month(m), int(d),
		base.NewFmtTime(f*24*3600))
	fmt.Printf("δ = %.4f\n", δ*180/math.Pi)
	fmt.Printf("%+0.62d\n", base.NewFmtAngle(δ))
	// Output:
	// JDE = 2469553.0834
	// 2049 April 21 at 14ʰ TD
	// δ = -22.1384
	// -22°08′
}
Esempio n. 2
0
func ExampleSouth() {
	// Example 52.b, p. 370.
	j, δ := moonmaxdec.South(2049.3)
	fmt.Printf("JDE = %.4f\n", j)
	y, m, d := julian.JDToCalendar(j)
	d, f := math.Modf(d)
	fmt.Printf("%d %s %d at %0h TD\n", y, time.Month(m), int(d),
		sexa.FmtTime(unit.TimeFromDay(f)))
	fmt.Printf("δ = %.4f\n", δ.Deg())
	fmt.Printf("%+0m\n", sexa.FmtAngle(δ))
	// Output:
	// JDE = 2469553.0834
	// 2049 April 21 at 14ʰ TD
	// δ = -22.1384
	// -22°08′
}