risacher / sunwait

Sunwait calculates sunrise or sunset times with civil, nautical, astronomical and custom twilights, for use with Windows Task Scheduler or 'cron' on Linux.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

day off by one?

risacher opened this issue · comments

Donald Fore says:

Hi Dan,

I think your "day" calculation is 1 day off.
' compensated for it in a quick little script using day+1.

Very nice program!

Investigate this

This does seem to be the case:

$ sunwait report 37.000N 122.000W

      Current Date and Time: 20-Nov-2023 19:34 PST


Target Information ...

                   Location:  37.000000N, 238.000000E
                       Date: 19-Nov-2023
                   Timezone: PST
   Sun directly north/south: 11:53
             Twilight angle: -0.83 degrees (daylight)
          Day with twilight: 06:48 to 16:57
                      It is: Night

General Information (no offset) ...

 Times ...         Daylight: 06:48 to 16:57
        with Civil twilight: 06:22 to 17:24
     with Nautical twilight: 05:50 to 17:55
 with Astronomical twilight: 05:19 to 18:26

 Duration ...    Day length: 10:09 hours
        with civil twilight: 11:02 hours
     with nautical twilight: 12:05 hours
 with astronomical twilight: 13:06 hours

Notice that the Date: and the current date/time differ. This happens when a date specification is supplied as well.