europas 0.0.1

Europa celestial simulation crate for the MilkyWay SolarSystem workspace
Documentation
#[derive(Debug, Clone, Copy, PartialEq)]
pub struct RegolithResource {
    pub ice_fraction: f64,
    pub oxygen_yield_fraction: f64,
    pub bulk_density_kg_m3: f64,
}

impl RegolithResource {
    pub fn oxygen_mass_kg(&self, processed_mass_kg: f64) -> f64 {
        processed_mass_kg * self.oxygen_yield_fraction
    }

    pub fn ice_feedstock_kg(&self, processed_mass_kg: f64) -> f64 {
        processed_mass_kg * self.ice_fraction
    }
}

pub fn surface_ice_resource() -> RegolithResource {
    RegolithResource {
        ice_fraction: 0.98,
        oxygen_yield_fraction: 0.86,
        bulk_density_kg_m3: 550.0,
    }
}