コード例 #1
0
ファイル: kepler_test.go プロジェクト: thecc4re/meeus
func ExampleKepler2a() {
	// Example data from p. 205
	E, err := kepler.Kepler2a(.99, .2, 14)
	if err != nil {
		fmt.Println(err)
		return
	}
	fmt.Printf("%.12f\n", E)
	// Output:
	// 1.066997365282
}
コード例 #2
0
ファイル: kepler_test.go プロジェクト: soniakeys/meeus
func ExampleKepler2a() {
	// Example data from p. 205
	E, err := kepler.Kepler2a(.99, unit.Angle(.2), 14)
	if err != nil {
		fmt.Println(err)
		return
	}
	fmt.Printf("%.12f\n", E.Rad())
	fmt.Printf("%.8f\n", E.Deg())
	// Output:
	// 1.066997365282
	// 61.13444578
}