Page 1 of 2

Moon phases Cumulus 1 v CumulusMX

Posted: Fri 03 Apr 2020 12:18 am
by laulau
Hi,
I noticed a little 'moon thing':
C1 and CMX not giving the same moon age (may be something known)
cloudbaseCUmx.php not showing the 'right' moon image.
mooncm1.PNG
mooncmx.PNG
moon.PNG
cloudbaseCumx.PNG
:?:

Re: CumulusMX and Cumulus1 UI style Multilingual Websites

Posted: Fri 03 Apr 2020 2:50 am
by BCJKiwi
Not sure what is going on,
The
MX index.php and cloudbaseCUmx.php files,
are the identical in
both MX and C1 files sets.
Yet both dashboard and cloudbase moon images (and days) are different on your MX and C1 sites.

Are the settings in the cumulus MX and Cumulus installations the same?

Re: CumulusMX and Cumulus1 UI style Multilingual Websites

Posted: Fri 03 Apr 2020 8:41 am
by mcrossley
I noticed CMX has two different calculations for Moon age and they were giving different results - I'll investigate, I think the routine it is using for the phase angle is more accurate, I'll look at updating for the next release.

Re: CumulusMX and Cumulus1 UI style Multilingual Websites

Posted: Fri 03 Apr 2020 8:50 am
by water01
mcrossley wrote: Fri 03 Apr 2020 8:41 am I noticed CMX has two different calculations for Moon age and they were giving different results - I'll investigate, I think the routine it is using for the phase angle is more accurate, I'll look at updating for the next release.
Mark if you change anything could you let me so I can change my moonphase script.

Re: CumulusMX and Cumulus1 UI style Multilingual Websites

Posted: Fri 03 Apr 2020 11:21 am
by mcrossley
Hmm, so the current date time is 2020/04/03 12:00
The routine CMX is using now is calculating the moon age to be 10.18 days

According to Heavens Above, the last new moon was on 24 March 2020 09:28, which according to my calculation was 10.11 days ago, so not far out from the CMX calculation.

However, lots of web sites as showing the age to be 8.x days! I'm puzzled!

But if I do a reverse calculation from the Phase Angle (which I've checked and the Phase Angle is also correct), I arrive at 8.49 days!
So I think these web sites must be doing that same calculation, what I cannot figure out is why the result is wrong, something about the trig functions.

Anyhoo, the result of the investigation is I believe the CMX age to be roughly correct and everybody else wrong! :shock: :lol:

Sorry, this is subverting this thread!

EDIT: Or is there some weird definition of moon age that I am missing?!

Re: CumulusMX and Cumulus1 UI style Multilingual Websites

Posted: Fri 03 Apr 2020 4:04 pm
by beteljuice
But if I do a reverse calculation from the Phase Angle (which I've checked and the Phase Angle is also correct), I arrive at 8.49 days!
....
EDIT: Or is there some weird definition of moon age that I am missing?!
Astro gotcha !!

The Phase Angle is a percentage of the lunation cycle - which varies !

So the correct answer is count time from New Moon ;)

Re: CumulusMX and Cumulus1 UI style Multilingual Websites

Posted: Fri 03 Apr 2020 4:45 pm
by mcrossley
I know the cycle length varies slightly (~13.5 hours), but not by nearly 2 days at 30 odd% way through the cycle!

Re: CumulusMX and Cumulus1 UI style Multilingual Websites

Posted: Sat 04 Apr 2020 4:09 am
by beteljuice
?
@Mark re mx

Remember you telling me the figure wasn't used in the distribution files and the value was rounded ?

For webtags you introduced a 'flag' for no rounding and truncating the value ie. 0 > 29.

I mention this because when I reverse engineered from the above screen shot(s) moonage was 9.88 days - so mx was at that time rounding up.

When you later investigated it was 10.?? (< 10.5)

Re: Moon phases Cumulus 1 v CumulusMX

Posted: Sat 04 Apr 2020 4:29 pm
by mcrossley
I did some more digging, I knew the Moons motion was complex, but..!

Though the overall mean period is 29d 12h 44m ~3s it can vary by around 13 hours.
BUT, the half period can vary by up to 44 hours. When you get a short first half it tends to be cancelled out by a longer second half and vise versa.

So the phase does not change at a linear rate throughout the period, therefore trying to work out the age in days using the phase calculations will not work, you are using a non-linear value to calculate a linear value.
beteljuice wrote: Sat 04 Apr 2020 4:09 am Remember you telling me the figure wasn't used in the distribution files and the value was rounded ?

For webtags you introduced a 'flag' for no rounding and truncating the value ie. 0 > 29.

I mention this because when I reverse engineered from the above screen shot(s) moonage was 9.88 days - so mx was at that time rounding up.

When you later investigated it was 10.?? (< 10.5)
Not sure what you are saying there beteljuice?
The #moonage tag is rounded by default, with as you say the option to truncate.
The screen shots show it using 10 days.

On 3 April 2020 at 02:03 CEST = 00:03 UTC the age was 9.57 days, which rounded is 10 days?

My calculation was based on 3 April 2020 at 12:00 BST = 11:00 UTC, age = 10.11, again rounded to 10 days, trunc to 10 days

Re: Moon phases Cumulus 1 v CumulusMX

Posted: Sat 04 Apr 2020 10:18 pm
by beteljuice
Perhaps I am being confused because I can't actually create / display the figures ..
The #moonage tag is rounded by default, with as you say the option to truncate.
The screen shots show it using 10 days.

On 3 April 2020 at 02:03 CEST = 00:03 UTC the age was 9.57 days, which rounded is 10 days?
Let's pick at this bit by bit (I'm getting too old for leaps of faith :) )

"The #moonage tag is rounded by default, with as you say the option to truncate."
So are you saying the option truncates a rounded figure ? - that serves no useful purpose regarding the initial enquiry !

"The screen shots show it using 10 days."
So is that screen using <#webtag>s, and not being generated directly by mx ?

"On 3 April 2020 at 02:03 CEST = 00:03 UTC the age was 9.57 days, which rounded is 10 days?"
OK - same argument as my query elsewhere for truncation - It isn't 10 days old !

Re: Moon phases Cumulus 1 v CumulusMX

Posted: Sat 04 Apr 2020 11:34 pm
by BCJKiwi
How does Cumulus (MX or C1) derive MoonPercent/abs, MoonAge and moonphase?

Is the MoonAge determined from MoonPercent?
If not it could be - if that is going to be any more representative of what is actually happening out there in space.

Re: Moon phases Cumulus 1 v CumulusMX

Posted: Sat 04 Apr 2020 11:46 pm
by mcrossley
beteljuice wrote: Sat 04 Apr 2020 10:18 pm Perhaps I am being confused because I can't actually create / display the figures ..
The #moonage tag is rounded by default, with as you say the option to truncate.
The screen shots show it using 10 days.

On 3 April 2020 at 02:03 CEST = 00:03 UTC the age was 9.57 days, which rounded is 10 days?
Let's pick at this bit by bit (I'm getting too old for leaps of faith :) )

"The #moonage tag is rounded by default, with as you say the option to truncate."
So are you saying the option truncates a rounded figure ? - that serves no useful purpose regarding the initial enquiry !

"The screen shots show it using 10 days."
So is that screen using <#webtag>s, and not being generated directly by mx ?

"On 3 April 2020 at 02:03 CEST = 00:03 UTC the age was 9.57 days, which rounded is 10 days?"
OK - same argument as my query elsewhere for truncation - It isn't 10 days old !
OK, above...

The screen shot mooncmx.PNG shows 10 days - I assume that is using the default tag so rounded, but you'd have to ask the site owner to be sure. It's not a default CMX web page, nor the admin interface.

Screen shot moon.PNG is some external web site, nothing to do with Cumulus.

Screen shot cloudbaseCumx.PNG is a third party script, I have no idea what web tag it is using, but again it looks like it it using the default rounded tag.
BCJKiwi wrote: Sat 04 Apr 2020 11:34 pm How does Cumulus (MX or C1) derive MoonPercent/abs, MoonAge and moonphase?

Is the MoonAge determined from MoonPercent?
If not it could be - if that is going to be any more representative of what is actually happening out there in space.
No idea about C1 - it's dead.

Moon Phase Angle is calculated from a complex astro calculation.
Moon (illuminated) Percent is derived from Moon Phase Angle.
Moon Phase is derived from Moon Percent
Moon Age is calculated using the Mean Synodic Period.

As the illuminated percentage is a function of the phase angle it cannot be used to derive the age for the reasons I gave above.

Re: Moon phases Cumulus 1 v CumulusMX

Posted: Sun 05 Apr 2020 12:23 am
by beteljuice
I assume that is using the default tag so rounded, but you'd have to ask the site owner to be sure. It's not a default CMX web page, nor the admin interface.
Ah so grasshopper ...

Thank you for lightening my darkness ... much is now clearer to me :geek:

Re: Moon phases Cumulus 1 v CumulusMX

Posted: Sun 05 Apr 2020 12:43 am
by BCJKiwi
OK
The screen shot mooncmx.PNG shows 10 days - I assume that is using the default tag so rounded, but you'd have to ask the site owner to be sure. It's not a default CMX web page, nor the admin interface.
The image comes from the new UIMX website and is selected by $moonage as delivered by CumulusMX from a set of images generated from complex program I cannot (at the moment) locate. It was a labour of many hours over some days done some time ago.

The cloudbase file also uses the moonage tag from CumulusMX (or C1) to select it's own image (created by Bashewa from whom the script source was derived and substantially modified by me, also a long time ago).
The Bashewa images are quite dark at the transition from light to dark on the present images so appear to have a wider dark portion.

Re: Moon phases Cumulus 1 v CumulusMX

Posted: Sun 05 Apr 2020 2:43 am
by BCJKiwi
Follow up:-

The images were generated by virtual moon atlas v6.0 (in 2013) a labour of many hours over an extended period. There is an update to v 6.1
It is available at https://sourceforge.net/projects/virtualmoon/
The update package (of 2013) patches the 2012 package I used.
The images were developed by stepping through each day of a full cycle so they are based on moonage.
As the illuminated percentage is a function of the phase angle it cannot be used to derive the age for the reasons I gave above.
That may be, but the illuminated percentage could be used to select an image that is nearest to that amount illuminated, rather than selecting an image based on the moon age.
The present image sets are based on the assumption that there is an even progression of illumination each day.
Illuminated % may be a better approach to deciding which image to display.

Running the program now and generating an image for today it looks nothing like what I see on the website. It also indicates an 86.9% illumination which agrees with cumulus. If I step it back 2 days it indicates 67.5% and matches the large image laulau shows at 67%.
This reinforces the idea that the selected image should be based on moon percent rather than days.

This means that ideally a set set of images should be generated based on percent illuminated at say 4% intervals yielding 25 images compared to the existing 28 (excluding the extras required with the existing system with its partials at either end of the cycle).

What say you all?