src

Go monorepo.
git clone git://code.dwrz.net/src
Log | Files | Refs

longitude.go (285B)


      1 package sunrise
      2 
      3 import (
      4 	"math"
      5 )
      6 
      7 // EclipticLongitude calculates the angular distance of the earth along the
      8 // ecliptic.
      9 func EclipticLongitude(solarAnomaly, equationOfCenter, d float64) float64 {
     10 	return math.Mod(solarAnomaly+equationOfCenter+180+ArgumentOfPerihelion(d), 360)
     11 }