MayaFlux 0.2.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches
MayaFlux::Nodes::Network::WaveguideNetwork::WaveguideSegment Struct Reference

1D delay-line segment supporting both uni- and bidirectional propagation More...

#include <WaveguideNetwork.hpp>

+ Collaboration diagram for MayaFlux::Nodes::Network::WaveguideNetwork::WaveguideSegment:

Public Types

enum class  PropagationMode : uint8_t { UNIDIRECTIONAL , BIDIRECTIONAL }
 Whether this segment uses one or two traveling-wave rails. More...
 

Public Member Functions

 WaveguideSegment (size_t length, PropagationMode prop_mode=PropagationMode::UNIDIRECTIONAL)
 Construct segment with both rails at the specified length.
 

Public Attributes

Memory::HistoryBuffer< double > p_plus
 Forward-traveling wave rail.
 
Memory::HistoryBuffer< double > p_minus
 Backward-traveling wave rail (BIDIRECTIONAL only)
 
std::shared_ptr< Filters::Filterloop_filter
 UNIDIRECTIONAL: single termination filter.
 
std::shared_ptr< Filters::Filterloop_filter_closed
 BIDIRECTIONAL: closed-end filter (mouthpiece/nut)
 
std::shared_ptr< Filters::Filterloop_filter_open
 BIDIRECTIONAL: open-end filter (bell/bridge)
 
PropagationMode mode { PropagationMode::UNIDIRECTIONAL }
 
double loss_factor { 0.996 }
 
double reflection_closed { -1.0 }
 Reflection coefficient at closed end (pressure node)
 
double reflection_open { 1.0 }
 Reflection coefficient at open end (pressure antinode)
 

Detailed Description

1D delay-line segment supporting both uni- and bidirectional propagation

UNIDIRECTIONAL (STRING): Only p_plus is active. Wave circulates in a single loop. p_minus is allocated but never written or read. Output tapped at pickup_sample along p_plus.

BIDIRECTIONAL (TUBE): Both rails active. p_plus travels toward the open end (bell), p_minus travels back toward the mouthpiece. At the closed end: p_minus[0] = -p_plus[end] (pressure inversion) At the open end: p_plus[0] = -p_minus[end] (approximate open reflection) Output is p_plus[pickup] + p_minus[pickup] (physical pressure sum).

Both rails share the same integer/fractional delay length and loop filter. The propagation mode is set once at construction and never changes.

Definition at line 138 of file WaveguideNetwork.hpp.


The documentation for this struct was generated from the following file: