Day of week Regconization

Dear all,

I am trying to build Astronomical time switch using Arduino Uno.
I am using GPS and DS1307 for time related function.

Currently i could able to getgps date/time/latitude/longitude
& DS1307 setdate / display date etc function.

Now i wanted to know how to print day of week. Based on date read from GPS/DS1307 if user want to set time on weekday and weekends . how can he set.

if i could able to get date for example 5/oct/2019 its Saturday. user will set time alone for Saturday for 11Am to 5pm

on every saturday,11am to 5pm relay should be on and other timing relay should be OFF.

How to make proper use of day of week option in this case.

RTC libraries come with examples. Are you using a library? If so, which one? Did it not show how to use day-of-week?

Regularly read the RTC and get the day-of-week number. If it matches the day (and time) that the user specified, react on it.