Custom equation guidance

29 Views Asked by At

i was having a tough time deciding on which SE site to post this rather unique question being that it would help me with a program I'm writing. I decided to come to you guys, not hoping that you would come up with the equation for me, but rather tell me if its even possible to begin with.

My program is a day/night cycle which works fine in itself but i was hoping to add some sort of equation that could compute the time of day based off a few dynamic variables.

Variables: starting rotation position, rotation speed, distance between hour A and hour B(15 degrees between each hour making 360 degrees after a full day)

All of these variables have values set in my program, i was hoping somebody could tell me with those variables would it be possible to calculate the starting time based off where a user places the sun with these factors? I have a working game clock already i just wanted it to be more user friendly with a working equation! If i posted this on the wrong site or its just completely irrelevant, i apologize in advance. If anybody can weigh in on this it would be more than greatly appreciated!!

Thanks, Dave