moons 0.0.3

Moon celestial simulation crate for the MilkyWay SolarSystem workspace
Documentation
1
2
3
4
5
6
7
pub fn earthshine_irradiance_lux(earth_phase_fraction: f64) -> f64 {
    0.15 + 0.85 * earth_phase_fraction.clamp(0.0, 1.0)
}

pub fn dark_side_visibility_index(earth_phase_fraction: f64, terrain_albedo: f64) -> f64 {
    earthshine_irradiance_lux(earth_phase_fraction) * terrain_albedo.clamp(0.0, 1.0)
}