pub struct VectorAreaReport {
pub shells: Vec<ShellVectorArea>,
pub unreadable: Vec<String>,
}Expand description
Outcome of shell_vector_areas.
Fields§
§shells: Vec<ShellVectorArea>§unreadable: Vec<String>Shells or faces whose trims could not be read, shell/face: reason. A
scan that could not read a face did not clear it, so an empty
shells beside a non-empty this is not “every shell closes”.
Implementations§
Source§impl VectorAreaReport
impl VectorAreaReport
Sourcepub fn is_flagged(&self) -> bool
pub fn is_flagged(&self) -> bool
The predicate: some CLOSED shell is over its bar.
Sourcepub fn unmeasured(&self) -> Vec<(u64, ClosureReading)>
pub fn unmeasured(&self) -> Vec<(u64, ClosureReading)>
The shells this scan did NOT measure, with what each reached. A report with entries here has not cleared those shells, whatever the rest read.
Sourcepub fn worst_shell(&self) -> Option<&ShellVectorArea>
pub fn worst_shell(&self) -> Option<&ShellVectorArea>
The largest closed-shell residual, and the shell that carries it.
Sourcepub fn residual(&self) -> f64
pub fn residual(&self) -> f64
|trim_residual| of the worst CLOSED shell, and NaN when this
solid has no closed shell at all.
Not 0.0. A residual of zero is what a perfectly sound shell reads, so
a solid whose shells are all open — one that has LOST faces, say —
must not be able to read like one through this accessor. The whole
point of the check is that a number nothing compares against is how
the defects it hunts stayed hidden; handing back a sound-looking zero
for “there was nothing here to judge” would rebuild that trap inside
the detector. Use Self::has_closed_shell to tell the two apart
before reading this, or read the per-shell reports, where an open
shell’s residual is its boundary’s own vector area and is reported.
Sourcepub fn bar(&self) -> f64
pub fn bar(&self) -> f64
That shell’s bar, NaN when there is no closed shell — see
Self::residual for why this is not 0.0.
Sourcepub fn has_closed_shell(&self) -> bool
pub fn has_closed_shell(&self) -> bool
Is there a closed shell here for Self::residual to be about?
Σ ∫ n dA = 0 is a statement about a CLOSED shell, so a solid with
none is not “sound” and not “unsound” — it is unjudged, and every
reader of this report has to decide what to do about that rather than
inherit a zero.
Sourcepub fn open_shells(&self) -> impl Iterator<Item = &ShellVectorArea>
pub fn open_shells(&self) -> impl Iterator<Item = &ShellVectorArea>
The shells that are NOT closed, with the vector area their open boundary encloses — the reading that names a shell which has lost faces.
A closed shell’s every edge is used exactly twice. A shell that has dropped a face has that face’s edges used once, so it is open here and its residual is what the missing boundary encloses. That is a different question from Euler parity, and a strictly stronger one for this purpose: parity notices an ODD number of faces going and is silent when an even number does, while this counts the uses of every edge and does not care how many faces left.