v0.45.0
What's Changed
🔭 This release introduces the possible to calculate if for a given location on Earth, at a specific time, there will either be a Solar or Lunar eclipse.
The API is exposed as isSolarEclipse()
and isLunarEclipse()
, (both take in the same parameter arguments) e.g.,:
import { isSolarEclipse } from '@observerly/astrometry'
// Give me an observer that is based in Truro, Cornwall, UK
const observer = {
latitude: 50.2632,
longitude: -5.051,
elevation: 0
}
const datetime = new Date('1999-08-11T11:04:00Z')
const eclipse = isSolarEclipse(datetime, observer)
console.log('11th August 1999', eclipse)
11th August 1999 {
k: -5,
JD: 2451401.9613755625,
type: 'total',
isCentral: true,
maximum: 1999-08-11T11:04:22.848Z,
magnitude: 1.0139097183206915,
alt: 51.8161625251939,
az: 147.15517329772132,
ra: 140.91260868409128,
dec: 15.809473632815184,
F: 7.358285775281047,
'Ω': 132.5933794317036,
'γ': 0.5066040940101156,
u: -0.0037459435675944045
}
Features
- feat: add getLunarEclipse() utility to @observerly/astrometry by @michealroberts in #255
- feat: add getSolarEclipse() utility to @observerly/astrometry by @michealroberts in #252
- feat: add isLunarEclipse() to eclipse module in @observerly/astrometry by @michealroberts in #256
- feat: add isSolarEclipse() to eclipse module in @observerly/astrometry by @michealroberts in #253
Full Changelog: v0.44.0...v0.45.0