Is there an accurate algorithm / method to determine the precise time of day/night when the sun is X degrees above (or below) the horizon for a given latitude Y at date Z?
Is this the same question here? Reverse Sun position algorithm? I'm having a hard time plugging in specifics.