PanelOptics
Defined in: surface.rs:31
pub struct PanelOpticsHow a flat panel reflects sunlight, for radiation pressure.
Absorption, specular reflection and diffuse reflection sum to 1, so two of
them determine the third. Absorption is derived rather than stored, and the
two stored fractions are private, so the constraint holds for every value
that exists — unlike the sibling fields of SurfacePanel, which are
independent scalars a struct literal can set freely. A specular above 1
would make the absorbed fraction negative and point the Sun-line component
of the force toward the Sun.
A single lumped Cr cannot stand in for these: it fixes the force magnitude
face-on but leaves the direction undetermined at oblique incidence, where
specular and diffuse reflection push along the panel normal rather than
along the Sun line.
Methods
Section titled “Methods”fn new(specular: f64, diffuse: f64) -> Self
Reflection properties from the specular and diffuse fractions; the rest of the incident light is absorbed.
Panics
Section titled “Panics”Panics unless both coefficients are finite, non-negative and sum to at most 1.
absorber()
Section titled “absorber()”fn absorber() -> Self
A black panel: everything absorbed, nothing reflected (Cr = 1 face-on).
specular()
Section titled “specular()”fn specular(self) -> f64
Specular reflectivity ρ_s: the fraction reflected mirror-like.
diffuse()
Section titled “diffuse()”fn diffuse(self) -> f64
Diffuse reflectivity ρ_d: the fraction re-emitted Lambertian.
absorptivity()
Section titled “absorptivity()”fn absorptivity(self) -> f64
Absorbed fraction α = 1 − (ρ_s + ρ_d).
Never negative: Self::new has already checked that the sum is at
most 1, and subtracting that one sum keeps the guarantee. Subtracting
the two terms one after the other would not — 1.0 - 0.9 - 0.1 is
-2.8e-17, because the second subtraction rounds again.