commons-suncalc
commons-suncalc copied to clipboard
Moon age (days) calculation
Thank you for your work, Richard
What is the right way to calculate Moon age (Moon days) using your library?
This is kotlin
val moonage = 29.0 * (normalized / 360.0) + 1.0
content += "Moon Age: " + moonage.toString()
I don't code in Kotlin, but it's enough like Java that I'm reasonably confident you don't need the explicit moonage.toString()
. Simplifying a bit, you can think of string concatenation terms all being wrapped in an implicit String.valueOf(x)
call.
What is the precise definition of Moon age/days here? I'm not familiar with this.