Natural Clock app

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Natural Clock app

Victor Engel
Dear Calendar People,

A friend of mine and I met yesterday at a local cafe to test an app I'd written. In the course of our conversation, he mentioned the need he and some of his colleagues have for an app that can be used for scheduling things relative to sunset. He mentioned that time used to be reckoned 12 hours a day, spaced equally across the daylight hours.

So I thought of writing an app to do just that. I found a framework that calculates sunrise and sunset times (saving me some coding time), given latitude and longitude, which I can get from the device. The app sets 6AM at the calculated sunrise and 6PM at the calculated sunset (I'm not sure exactly what definitions the framework uses, but there are actually several values to chose from).

Time throughout the day is divided equally so that 12 hours exactly fill up the time between sunrise and sunset.

I coded the app so that when it starts out, it shows the customary time, with daylight saving taken into account if the locale supports daylight saving time. Tapping the screen switches to the other mode, where time is equally spaced from 6AM to 6PM.

To make it obvious which version of time is being displayed, I made the second hand red for normal time, and green for what I'm calling natural time (in the code, I call it faux time).

I've put a short video clip up on Dropbox so you can see it in action. I switch between the two modes a couple of times.


I was curious how the framework handles situations where there is no sunrise and sunset (polar conditions). It looks like if there is no sunrise/sunset, it uses local midnight or local noon for both.

Victor
Reply | Threaded
Open this post in threaded view
|

Re: Natural Clock app

Amos Shapir-2
Hi Victor and calendar people,

Some Jewish calendar apps also calculate the Zmanim, prayer and observances time relative to local sunrise / sunset. Usually they just show a list of times for a chosen date, but I guess on a smart device they can be made to put up notifications (but I have no idea if there is any available smartphone app which does that).

On Tue, Aug 15, 2017 at 11:44 PM, Victor Engel <[hidden email]> wrote:
Dear Calendar People,

A friend of mine and I met yesterday at a local cafe to test an app I'd written. In the course of our conversation, he mentioned the need he and some of his colleagues have for an app that can be used for scheduling things relative to sunset. He mentioned that time used to be reckoned 12 hours a day, spaced equally across the daylight hours.

So I thought of writing an app to do just that. I found a framework that calculates sunrise and sunset times (saving me some coding time), given latitude and longitude, which I can get from the device. The app sets 6AM at the calculated sunrise and 6PM at the calculated sunset (I'm not sure exactly what definitions the framework uses, but there are actually several values to chose from).

Time throughout the day is divided equally so that 12 hours exactly fill up the time between sunrise and sunset.

I coded the app so that when it starts out, it shows the customary time, with daylight saving taken into account if the locale supports daylight saving time. Tapping the screen switches to the other mode, where time is equally spaced from 6AM to 6PM.

To make it obvious which version of time is being displayed, I made the second hand red for normal time, and green for what I'm calling natural time (in the code, I call it faux time).

I've put a short video clip up on Dropbox so you can see it in action. I switch between the two modes a couple of times.


I was curious how the framework handles situations where there is no sunrise and sunset (polar conditions). It looks like if there is no sunrise/sunset, it uses local midnight or local noon for both.

Victor



--
Amos Shapir
 
Reply | Threaded
Open this post in threaded view
|

Re: Natural Clock app

guvapo
In reply to this post by Victor Engel
Dear Victor
I find your app very interesting.
I have in my garden a device that shows local noon (when there is sunshine)
I wonder if your clock shows 12 when my device says it is local noon.
Can I buy somewhere your app (for iPhone6) ?

Thanks
Guido


On 15 Aug 2017, at 22:44, Victor Engel <[hidden email]> wrote:

Dear Calendar People,

A friend of mine and I met yesterday at a local cafe to test an app I'd written. In the course of our conversation, he mentioned the need he and some of his colleagues have for an app that can be used for scheduling things relative to sunset. He mentioned that time used to be reckoned 12 hours a day, spaced equally across the daylight hours.

So I thought of writing an app to do just that. I found a framework that calculates sunrise and sunset times (saving me some coding time), given latitude and longitude, which I can get from the device. The app sets 6AM at the calculated sunrise and 6PM at the calculated sunset (I'm not sure exactly what definitions the framework uses, but there are actually several values to chose from).

Time throughout the day is divided equally so that 12 hours exactly fill up the time between sunrise and sunset.

I coded the app so that when it starts out, it shows the customary time, with daylight saving taken into account if the locale supports daylight saving time. Tapping the screen switches to the other mode, where time is equally spaced from 6AM to 6PM.

To make it obvious which version of time is being displayed, I made the second hand red for normal time, and green for what I'm calling natural time (in the code, I call it faux time).

I've put a short video clip up on Dropbox so you can see it in action. I switch between the two modes a couple of times.


I was curious how the framework handles situations where there is no sunrise and sunset (polar conditions). It looks like if there is no sunrise/sunset, it uses local midnight or local noon for both.

Victor

Reply | Threaded
Open this post in threaded view
|

Re: Natural Clock app

Moongazer
In reply to this post by Victor Engel
Victor, what you call natural time is called, by Jews, seasonal time, measured in seasonal hours, whose length varies with the seasons (and, of course, latitude). (This is what Amos Shapir refers to in his reply.) I have explained it on this webpage, where I contrast two different Jewish time conventions, Jewish Mean Time (used in calendar computations) and Jewish Seasonal Time (used for religious observances, as mentioned by Amos).

(The website at the above link has not yet been published; it is still under construction, so, although I have shared it here, please do not spread it beyond this list.)
Reply | Threaded
Open this post in threaded view
|

Re: Natural Clock app

Moongazer
In reply to this post by Victor Engel
Victor, to expand on my previous reply, your app could be very useful to religiously observant Orthodox Jews. If you want to make it super useful to that potential market, you should add a settings page where the user can set 'daytime' to one of two (or more) alternative definitions: (a) sunrise to sunset or (b) dawn to dusk. The most commonly used definition (I think) of dawn and dusk is the Sun at 8.5 degrees below the horizon (slightly darker than civil twilight, which is 6 deg, but not as dark as nautical twilight, which is 12 deg). There are alternative definitions of dawn and dusk in use by certain groups, but I don't know them offhand.

Also, what does the natural clock show during the night-time? It should do the same as in the daytime - i.e. divide the night, however long or short, into 12 equal night-time hours, perhaps with a different background colour to distinguish between day and night. During summer, a daytime hour will be longer than a night-time hour and vice-versa during winter.

An additionally useful feature for that market might be: disable screen time-out while natural clock is showing, so the clock can be visible without intervention by the user. (Will probably drain the battery though, so it should operate only when connected to a charger.)

You might find a large market for the app in Israel if you got the interface translated into Hebrew. There is a retired civil engineer I know there, who is interested in this kinda thing and may be willing to do the translation.

Presumably your natural time clock shows 12 o'clock at local noon, which will only = 12 o'clock on the civil clock for someone living at the central meridian of their time zone, and not always, i.e. not all year round.

Is there a version for Microsoft Lumia phones? (WP 8.1)  (Probably not.) (I got it for a very good price.)

Reply | Threaded
Open this post in threaded view
|

Re: Natural Clock app

Victor Engel
In reply to this post by guvapo
I have just started it. I think I will integrate some calendar functions, too, like setting up appointments/events that are based on natural/seasonal time. When I get it set up on iTunes Connect, I can add you as a tester. Let me know off-list if you'd like to be included.

Victor

On Wed, Aug 16, 2017 at 1:55 AM, Guido VanPoucke <[hidden email]> wrote:
Dear Victor
I find your app very interesting.
I have in my garden a device that shows local noon (when there is sunshine)
I wonder if your clock shows 12 when my device says it is local noon.
Can I buy somewhere your app (for iPhone6) ?

Thanks
Guido


On 15 Aug 2017, at 22:44, Victor Engel <[hidden email]> wrote:

Dear Calendar People,

A friend of mine and I met yesterday at a local cafe to test an app I'd written. In the course of our conversation, he mentioned the need he and some of his colleagues have for an app that can be used for scheduling things relative to sunset. He mentioned that time used to be reckoned 12 hours a day, spaced equally across the daylight hours.

So I thought of writing an app to do just that. I found a framework that calculates sunrise and sunset times (saving me some coding time), given latitude and longitude, which I can get from the device. The app sets 6AM at the calculated sunrise and 6PM at the calculated sunset (I'm not sure exactly what definitions the framework uses, but there are actually several values to chose from).

Time throughout the day is divided equally so that 12 hours exactly fill up the time between sunrise and sunset.

I coded the app so that when it starts out, it shows the customary time, with daylight saving taken into account if the locale supports daylight saving time. Tapping the screen switches to the other mode, where time is equally spaced from 6AM to 6PM.

To make it obvious which version of time is being displayed, I made the second hand red for normal time, and green for what I'm calling natural time (in the code, I call it faux time).

I've put a short video clip up on Dropbox so you can see it in action. I switch between the two modes a couple of times.


I was curious how the framework handles situations where there is no sunrise and sunset (polar conditions). It looks like if there is no sunrise/sunset, it uses local midnight or local noon for both.

Victor


Reply | Threaded
Open this post in threaded view
|

Re: Natural Clock app

guvapo
yes, of course !
important qua input would be : latitude, longitude, sunset, sunrise, and date of course
if possible Equation of Time of the day
I think UTC would be enough (because universal)

Guido



On 16 Aug 2017, at 15:31, Victor Engel <[hidden email]> wrote:

I have just started it. I think I will integrate some calendar functions, too, like setting up appointments/events that are based on natural/seasonal time. When I get it set up on iTunes Connect, I can add you as a tester. Let me know off-list if you'd like to be included.

Victor

On Wed, Aug 16, 2017 at 1:55 AM, Guido VanPoucke <[hidden email]> wrote:
Dear Victor
I find your app very interesting.
I have in my garden a device that shows local noon (when there is sunshine)
I wonder if your clock shows 12 when my device says it is local noon.
Can I buy somewhere your app (for iPhone6) ?

Thanks
Guido


On 15 Aug 2017, at 22:44, Victor Engel <[hidden email]> wrote:

Dear Calendar People,

A friend of mine and I met yesterday at a local cafe to test an app I'd written. In the course of our conversation, he mentioned the need he and some of his colleagues have for an app that can be used for scheduling things relative to sunset. He mentioned that time used to be reckoned 12 hours a day, spaced equally across the daylight hours.

So I thought of writing an app to do just that. I found a framework that calculates sunrise and sunset times (saving me some coding time), given latitude and longitude, which I can get from the device. The app sets 6AM at the calculated sunrise and 6PM at the calculated sunset (I'm not sure exactly what definitions the framework uses, but there are actually several values to chose from).

Time throughout the day is divided equally so that 12 hours exactly fill up the time between sunrise and sunset.

I coded the app so that when it starts out, it shows the customary time, with daylight saving taken into account if the locale supports daylight saving time. Tapping the screen switches to the other mode, where time is equally spaced from 6AM to 6PM.

To make it obvious which version of time is being displayed, I made the second hand red for normal time, and green for what I'm calling natural time (in the code, I call it faux time).

I've put a short video clip up on Dropbox so you can see it in action. I switch between the two modes a couple of times.


I was curious how the framework handles situations where there is no sunrise and sunset (polar conditions). It looks like if there is no sunrise/sunset, it uses local midnight or local noon for both.

Victor



Reply | Threaded
Open this post in threaded view
|

Re: [SUSPICIOUS MESSAGE] Re: Natural Clock app

Victor Engel
In reply to this post by Moongazer
Dear Moongazer andCalendar People,

I'm slightly surprised at the interest this app is generating. I will address your points, below.

On Wed, Aug 16, 2017 at 7:47 AM, Moongazer <[hidden email]> wrote:
Victor, to expand on my previous reply, your app could be very useful to
religiously observant Orthodox Jews. If you want to make it super useful to
that potential market, you should add a settings page where the user can set
'daytime' to one of two (or more) alternative definitions: (a) sunrise to
sunset or (b) dawn to dusk. The most commonly used definition (I think) of
dawn and dusk is the Sun at 8.5 degrees below the horizon (slightly darker
than civil twilight, which is 6 deg, but not as dark as nautical twilight,
which is 12 deg). There are alternative definitions of dawn and dusk in use
by certain groups, but I don't know them offhand.

I'm using a framework that was written specifically for sunrise and sunset. Without modification, it provides the following:

Sunrise/Sunset -35/60 degrees

Civil Twilight Start/End -6.0 degrees

Nautical Twilight Start/End -12.0 degrees

Astronomical Twilight Start/End -18.0 degrees

I can extend it, if need be. All these use a common method when uses an altitude argument. I think there's something about the time being when three stars are visible. I wonder how light pollution affects such a definition. In any case, I anticipate having a settings page where the definition can be selected/entered.
 

Also, what does the natural clock show during the night-time? It should do
the same as in the daytime - i.e. divide the night, however long or short,
into 12 equal night-time hours, perhaps with a different background colour
to distinguish between day and night. During summer, a daytime hour will be
longer than a night-time hour and vice-versa during winter.

Currently, the face turns from white to dark grey at sunset and then back to white again at sunrise. I have a request to add a lamp or other light for the night-time. The night is divided into 12 equal hours just as the day is. Night hours and day hours are different lengths. 

An additionally useful feature for that market might be: disable screen
time-out while natural clock is showing, so the clock can be visible without
intervention by the user. (Will probably drain the battery though, so it
should operate only when connected to a charger.)

I will look into that.  

You might find a large market for the app in Israel if you got the interface
translated into Hebrew. There is a retired civil engineer I know there, who
is interested in this kinda thing and may be willing to do the translation.

Thanks. I'm sure I have local resources, as well. 

Presumably your natural time clock shows 12 o'clock at local noon, which
will only = 12 o'clock on the civil clock for someone living at the central
meridian of their time zone, and not always, i.e. not all year round.

That will vary with the equation of time. But yes. 

Is there a version for Microsoft Lumia phones? (WP 8.1)  (Probably not.) (I
got it for a very good price.)

Considering I just got the idea for the app two days ago, no. :)

There's another question of what to do if the latitude and time of year are such that there is no sunrise/sunset. Currently, what the app does is to use local apparent noon/midnight for both, resulting in days or nights of length 24 UT hours and counterparts that have no length. I think that is probably the best solution, but I'm open to other ideas on that.

Victor
Reply | Threaded
Open this post in threaded view
|

Re: Natural Clock app

Christoph Päper-2
In reply to this post by Victor Engel
Victor Engel <[hidden email]>
>
> I coded the app so that when it starts out, it shows the customary time,
> with daylight saving taken into account if the locale supports daylight
> saving time. Tapping the screen switches to the other mode, where time is
> equally spaced from 6AM to 6PM.
>
> To make it obvious which version of time is being displayed, I made the
> second hand red for normal time, and green for what I'm calling natural
> time (in the code, I call it faux time).

I don't think the colored hand makes this obvious or intuitive. Perhaps draw the clock face as a sun for "natural time". Alternatively, show the clock face with a dark border or shadow where it's night, i.e. in natural time, the left half would be dark during PM and the right half during AM times.

This app should of course be tested on smart watches where it would probably primarily run.

> I was curious how the framework handles situations where there is no
> sunrise and sunset (polar conditions). It looks like if there is no
> sunrise/sunset, it uses local midnight or local noon for both.

You could add an option for a minimum and maximum length of "natural hours", although the number of potential users that will experience the need for this is rather small.

A perfect companion app would be a truly lunar calendar, wherein a week lasts a phase of the Moon (i.e. from Full to Quarter to New to Quarter to Full). An app like that may exist already.
Reply | Threaded
Open this post in threaded view
|

Re: Natural Clock app

Victor Engel


On Wed, Aug 16, 2017 at 1:53 PM, Christoph Päper <[hidden email]> wrote:
Victor Engel <[hidden email]>
>
> I coded the app so that when it starts out, it shows the customary time,
> with daylight saving taken into account if the locale supports daylight
> saving time. Tapping the screen switches to the other mode, where time is
> equally spaced from 6AM to 6PM.
>
> To make it obvious which version of time is being displayed, I made the
> second hand red for normal time, and green for what I'm calling natural
> time (in the code, I call it faux time).

I don't think the colored hand makes this obvious or intuitive.

I agree. Please realize this is just proof of concept at this point. I expect that in actual use, perhaps two faces would be shown or one face is shown according to a preferences setting. Currently, there is no preferences screen.
 
Perhaps draw the clock face as a sun for "natural time".

I plan to also add skins.
 
Alternatively, show the clock face with a dark border or shadow where it's night, i.e. in natural time, the left half would be dark during PM and the right half during AM times.

This app should of course be tested on smart watches where it would probably primarily run.

Good point. This could be my first smart watch app. I had not considered this. I don't use any sort of watch myself. 

> I was curious how the framework handles situations where there is no
> sunrise and sunset (polar conditions). It looks like if there is no
> sunrise/sunset, it uses local midnight or local noon for both.

You could add an option for a minimum and maximum length of "natural hours", although the number of potential users that will experience the need for this is rather small.

Another option would be to use a preferences-selected base location for out-of-range GPS coordinates, or just in general (toggle GPS use). 

A perfect companion app would be a truly lunar calendar, wherein a week lasts a phase of the Moon (i.e. from Full to Quarter to New to Quarter to Full). An app like that may exist already.

It seems like there are apps for everything these days.

Victor 

Reply | Threaded
Open this post in threaded view
|

Re: Natural Clock app

Ryan

It would be good if the sunrise and sunset times, solar noon, etc. are calculated to calendar day/ecliptic longitude and latitude/longitude, mean solar time and maybe other factors including equation of time to determine when it’s 00:00, 06:00, 12:00 and 18:00 in natural time, and also have Android and Windows 10 support

 

Sent from Mail for Windows 10

 

From: [hidden email]
Sent: August 16, 2017 16:18
To: [hidden email]
Subject: Re: Natural Clock app

 

 

 

On Wed, Aug 16, 2017 at 1:53 PM, Christoph Päper <[hidden email]> wrote:

Victor Engel <[hidden email]>
>
> I coded the app so that when it starts out, it shows the customary time,
> with daylight saving taken into account if the locale supports daylight
> saving time. Tapping the screen switches to the other mode, where time is
> equally spaced from 6AM to 6PM.
>
> To make it obvious which version of time is being displayed, I made the
> second hand red for normal time, and green for what I'm calling natural
> time (in the code, I call it faux time).

I don't think the colored hand makes this obvious or intuitive.

 

I agree. Please realize this is just proof of concept at this point. I expect that in actual use, perhaps two faces would be shown or one face is shown according to a preferences setting. Currently, there is no preferences screen.

 

Perhaps draw the clock face as a sun for "natural time".

 

I plan to also add skins.

 

Alternatively, show the clock face with a dark border or shadow where it's night, i.e. in natural time, the left half would be dark during PM and the right half during AM times.

This app should of course be tested on smart watches where it would probably primarily run.

 

Good point. This could be my first smart watch app. I had not considered this. I don't use any sort of watch myself. 


> I was curious how the framework handles situations where there is no
> sunrise and sunset (polar conditions). It looks like if there is no
> sunrise/sunset, it uses local midnight or local noon for both.

You could add an option for a minimum and maximum length of "natural hours", although the number of potential users that will experience the need for this is rather small.

 

Another option would be to use a preferences-selected base location for out-of-range GPS coordinates, or just in general (toggle GPS use). 


A perfect companion app would be a truly lunar calendar, wherein a week lasts a phase of the Moon (i.e. from Full to Quarter to New to Quarter to Full). An app like that may exist already.

 

It seems like there are apps for everything these days.

 

Victor