pub enum BoundaryPolicy {
Tight,
DelayedSense,
DelayedCoupling(Domain),
}Expand description
The boundary policy for an edge between two ports, given the directed signal-flow orientation and component memory.
This is the single source of truth for “how must an edge between these two
kinds of ports be treated at a stage boundary”. A later formation phase
reads BoundaryPolicy::directive to decide whether to co-solve the two
ends (tight) or cut + route them with a delay (sense / coupling).
Variants§
Tight
Co-solve: the two ports belong to the same solved system (an ordinary forward cascade edge, a conducting edge). No boundary cut.
DelayedSense
Cut + sense with a one-sample delay: a FEEDBACK edge into a control electrode (e.g. an output tap rectified back into a sidechain grid). The sense path is broken to keep the forward solve causal.
DelayedCoupling(Domain)
Cut + couple across a non-electrical Domain with a one-sample delay:
a transducer edge (photocoupler LED drive, OTA Iabc CV). The two
networks never share a node; the coupling is delivered next sample.
Implementations§
Source§impl BoundaryPolicy
impl BoundaryPolicy
Sourcepub fn classify(
ends: (PortClass, PortClass),
flow_is_back_edge: bool,
has_memory: bool,
) -> Self
pub fn classify( ends: (PortClass, PortClass), flow_is_back_edge: bool, has_memory: bool, ) -> Self
The whole rule table. ends are the two port classes of an edge,
flow_is_back_edge is true when the edge runs against the directed
signal flow (feedback), and has_memory records whether the coupling
element carries state/taus (photocoupler cell, etc.).
Rules (in priority order):
- an edge into a
PortClass::Transducer→BoundaryPolicy::DelayedCoupling. - a BACK-edge into a
PortClass::ControlInput→BoundaryPolicy::DelayedSense. - a FORWARD edge into a
PortClass::ControlInput(cascade) →BoundaryPolicy::Tight. - everything else →
BoundaryPolicy::Tight.
has_memory is part of the signature because a future refinement may
route a memoryless transducer differently from a stateful one; in the
Phase-1 table it does not change the outcome (a transducer coupling is
always delayed, with or without its own state).
Trait Implementations§
Source§impl Clone for BoundaryPolicy
impl Clone for BoundaryPolicy
Source§fn clone(&self) -> BoundaryPolicy
fn clone(&self) -> BoundaryPolicy
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for BoundaryPolicy
Source§impl Debug for BoundaryPolicy
impl Debug for BoundaryPolicy
impl Eq for BoundaryPolicy
Source§impl PartialEq for BoundaryPolicy
impl PartialEq for BoundaryPolicy
Source§fn eq(&self, other: &BoundaryPolicy) -> bool
fn eq(&self, other: &BoundaryPolicy) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for BoundaryPolicy
Auto Trait Implementations§
impl Freeze for BoundaryPolicy
impl RefUnwindSafe for BoundaryPolicy
impl Send for BoundaryPolicy
impl Sync for BoundaryPolicy
impl Unpin for BoundaryPolicy
impl UnsafeUnpin for BoundaryPolicy
impl UnwindSafe for BoundaryPolicy
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.