GetFullMoons
Previous  Top  Next

BSTCalH.GetFullMoons PROCEDURE(LONG pYR,*REAL[,] pFM),VIRTUAL !Real DIM(15,2)

GetFullMoons Method takes a Passed Year or Date, and fills an array of Reals -DIM(15,2) (passed by address) with Clarion Star dates for the full and new moons for the passed year. The Dates and Times are in UTC. See FMutcCor to convert them to your time zone, as the date occasionally changes. The Full Moons are stored in the Array in Position 1, and the New Moons are stored in Position 2. GetFullMoons Method starts with the Last New Moon of the previous Year when filling the Array, so the Array may contain empty values to test for. I usually returns 29 values, so as a result, may return Full and New moons into February of the next year. This is necessary to cover the "Blue Moons" that may occur. See July of 2004 for this<g>.

Standard Usage

BHT:FullMoons REAL,DIM(15,2)! Array of StarDates for Moons.

BSTCalH.GetFullMoons(BHT:YrWanted,BHT:FullMoons)
or
BSTCalH.GetFullMoons(BHT:Date,BHT:FullMoons)

Processing the Array. The clarion star date has the date stored in the integer portion (Date# = INT(BHT:FullMoons[I#,2])), and the time stored in the decimal portion (TIME# = (BHT:FullMoons[I#,2] - INT(BHT:FullMoons[I#,2]))*8640000). Sample code to process the array into a queue is as follows.

BSTCalH.GetFullMoons(BHT:YrWanted,BHT:FullMoons)
FREE(FMQ)
LOOP I# = 1 to 15
IF BHT:FullMoons[I#,2] > 1
T# = (BHT:FullMoons[I#,2] - INT(BHT:FullMoons[I#,2]))*8640000
FMQ:FMQDisplay = 'New Moon ' & FORMAT(INT(BHT:FullMoons[I#,2]),@D3) & ' ' &|
FORMAT(T#,@T3)
ADD(FMQ)
END
IF BHT:FullMoons[I#,1] > 1
T# = (BHT:FullMoons[I#,1] - INT(BHT:FullMoons[I#,1]))*8640000
FMQ:FMQDisplay = 'Full Moon ' & FORMAT(INT(BHT:FullMoons[I#,1]),@D3) & ' ' &|
FORMAT(T#,@T3)
ADD(FMQ)
END
END
Display(?List1)