Path: utzoo!utgpu!watmath!clyde!ima!think!barmar From: barmar@think.COM (Barry Margolin) Newsgroups: comp.misc Subject: Re: Need to predict phase of moon. Message-ID: <34976@think.UUCP> Date: 30 Dec 88 18:19:25 GMT References: <101150002@hpcvlx.HP.COM> Sender: news@think.UUCP Reply-To: barmar@kulla.think.com.UUCP (Barry Margolin) Organization: Thinking Machines Corporation, Cambridge MA, USA Lines: 16 All you need to know is the time of a recent new moon and the period of the moon phase cycle. The program we use here has the base new moon time as Oct 21, 1987 23:47 GMT, and the period as 29 days, 12 hours, 44 minutes, 3 seconds (totaling 2,551,443 seconds). Then compute (((current_time_in_seconds - base_new_moon_time) % period) / (float) period). You can get a more recent base new moon time from an astronomy magazine, almanac, or ephemeris. Barry Margolin Thinking Machines Corp. barmar@think.com {uunet,harvard}!think!barmar