A Space & astronomy forum. SpaceBanter.com

Go Back   Home » SpaceBanter.com forum » Others » Misc
Site Map Home Authors List Search Today's Posts Mark Forums Read Web Partners

need lunar phase algorithm



 
 
Thread Tools Display Modes
  #1  
Old August 11th 03, 07:10 AM
Marty
external usenet poster
 
Posts: n/a
Default need lunar phase algorithm

"Jim Showalter" wrote in
news
Greetings!

Pardon me if this is naive, but I am seeking an algorithm to calculate
the phase of the moon for any day in the 7980 year Julian Date range,
4713 BC to 3268 AD.

This is to be one feature in a calendar program, so I would like to
keep it simple - a resolution of 24 hours would be ideal.

I would also prefer that it makes it's conversions from JDN's, but
calendar dates (Julian/Gregorian) are OK.

Please let me know of any algorithm or source code (open source, P/D,
etc.) that would approximate my needs.


TIA!
Jim Showalter


Download this free generic BASIC routine from Sky and Telescope
MOONS.BAS that calculates phases for any year. (Though we are not told the
time span it is valid for).You will also need JDCAL.BAS (on the same page)
to convert the JD output to calendar date.
http://skyandtelescope.com/resources...icle_326_4.asp

Otherwise get hold of Jean Meeus's Astronomical Algorithms that has
rigorous formulae that you can create your own code with.

Martin Lewicki
  #2  
Old August 11th 03, 03:58 PM
Benoit Morrissette
external usenet poster
 
Posts: n/a
Default

On Mon, 11 Aug 2003 18:52:12 +1000, "|-|erc" wrote:

"Jim Showalter" wrote
Greetings!

Pardon me if this is naive, but I am seeking an algorithm to calculate
the phase of the moon for any day in the 7980 year Julian Date range,
4713 BC to 3268 AD.

This is to be one feature in a calendar program, so I would like to
keep it simple - a resolution of 24 hours would be ideal.

I would also prefer that it makes it's conversions from JDN's, but
calendar dates (Julian/Gregorian) are OK.

Please let me know of any algorithm or source code (open source, P/D,
etc.) that would approximate my needs.



This one works from 1600 to 2300, as you can see here...


if(g 16000000) {
bk = 1;
alert("Routines are not accurate enough to work back that" +
" far - answers are meaningless!");
}
if(g 23000000) {



but may be useful. Wish I had the URL there were a lot of other programs
around, you should be able to get a more accurate version online.

Herc

SNIP...

As a service to the community, i have put this HTML code om my site as moon.html
http://pages.infinit.net/benoitm/

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
The Apollo Hoax FAQ (is not spam) :-) Nathan Jones Astronomy Misc 5 July 29th 04 06:14 AM
Apollo Buzz alDredge Astronomy Misc 5 July 28th 04 10:05 AM
The Apollo Hoax FAQ darla Astronomy Misc 15 July 25th 04 02:57 PM
significant addition to section 25 of the faq heat Astronomy Misc 1 April 15th 04 01:20 AM


All times are GMT +1. The time now is 01:09 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 SpaceBanter.com.
The comments are property of their posters.