solstice

package
v3.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 10, 2018 License: MIT Imports: 5 Imported by: 1

Documentation

Overview

Solstice: Chapter 27: Equinoxes and Solstices.

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

func December

func December(y int) float64

December returns the JDE of the December solstice for a given year.

Results are valid for the years -1000 to +3000.

Accuracy is within one minute of time for the years 1951-2050.

func December2

func December2(y int, e *pp.V87Planet) float64

December2 returns a more accurate JDE of the December solstice.

Result is accurate to one second of time.

Parameter e must be a V87Planet object representing Earth, obtained with the package planetposition and code similar to

e, err := planetposition.LoadPlanet(planetposition.Earth, "")
    if err != nil {
        ....

See example under June2.

func June

func June(y int) float64

June returns the JDE of the June solstice for the given year.

Results are valid for the years -1000 to +3000.

Accuracy is within one minute of time for the years 1951-2050.

Example
package main

import (
	"fmt"

	"github.com/soniakeys/meeus/v3/solstice"
)

func main() {
	// Example 27.a, p. 180
	fmt.Printf("%.5f\n", solstice.June(1962))
}
Output:

2437837.39245

func June2

func June2(y int, e *pp.V87Planet) float64

June2 returns a more accurate JDE of the June solstice.

Result is accurate to one second of time.

Parameter e must be a V87Planet object representing Earth, obtained with the package planetposition.

Example
// Example 27.b, p. 180.
e, err := pp.LoadPlanet(pp.Earth)
if err != nil {
	fmt.Println(err)
	return
}
j := solstice.June2(1962, e)
t := j - 2437836.5 // 0h 1962 June 21
// result is VSOP87 result given in example 27.a, p. 180
fmt.Println(sexa.FmtTime(unit.TimeFromDay(t)))
Output:

21ʰ24ᵐ42ˢ

func March

func March(y int) float64

March returns the JDE of the March equinox for the given year.

Results are valid for the years -1000 to +3000.

Accuracy is within one minute of time for the years 1951-2050.

func March2

func March2(y int, e *pp.V87Planet) float64

March2 returns a more accurate JDE of the March equinox.

Result is accurate to one second of time.

Parameter e must be a V87Planet object representing Earth, obtained with the package planetposition and code similar to

e, err := planetposition.LoadPlanet(planetposition.Earth, "")
    if err != nil {
        ....

See example under June2.

func September

func September(y int) float64

September returns the JDE of the September equinox for the given year.

Results are valid for the years -1000 to +3000.

Accuracy is within one minute of time for the years 1951-2050.

func September2

func September2(y int, e *pp.V87Planet) float64

September2 returns a more accurate JDE of the September equinox.

Result is accurate to one second of time.

Parameter e must be a V87Planet object representing Earth, obtained with the package planetposition and code similar to

e, err := planetposition.LoadPlanet(planetposition.Earth, "")
    if err != nil {
        ....

See example under June2.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL