suncalc icon indicating copy to clipboard operation
suncalc copied to clipboard

moontimes always a few minutes off

Open jovrstra opened this issue 7 years ago • 1 comments

Hello, I'm trying to use suncalc to calculate the moon data, but my moon times are always a few minutes off (5-15 minutes); phase also seems off. I seem to have the same issue for all locations I tried (I tried some at sea level, to rule out altitude influence) and have no idea where else I can start looking... I'm comparing the output of suncalc.js with the suncalc.org website, so I suspect they should be the same... It has to be something I do wrong, but I don't know... One example I used is this one: var date = new Date('2018-10-07'), lat = 51.50735, lng = -0.12776; then a call to getMoonPosition(date,lat,lng,false) and I get a moonrise of Sun, 7 Oct 2018, 3:42:45 GMT The website gives 4:33:28. The fact that it is one hour off is probably due to timezones/utc, but I don't get why the minutes are off by that much.

Any clues on what I could be doing wrong? Thanks!

jovrstra avatar Oct 07 '18 16:10 jovrstra

same issue

stevenmusumeche avatar Jul 22 '20 19:07 stevenmusumeche