Path¶
Overview¶
A Path label identifies the
spatial or logical channel associated with an optical mode.
Examples of paths include different waveguides, fibers, interferometer arms, or abstract routing labels used in a simulation.
In the library, path labels are discrete and orthonormal.
Physical meaning¶
For two path labels \(p_1\) and \(p_2\), the overlap is
This means that two modes on different paths are treated as fully distinguishable at the path level.
Examples¶
Constructing path labels¶
from symop.modes.labels.path import Path
a = Path("A")
b = Path("B")
print(a)
print(b)
print(a.signature)
print(b.signature)
Path(name='A')
Path(name='B')
('path', 'A')
('path', 'B')
Path overlaps¶
from symop.modes.labels.path import Path
a1 = Path("A")
a2 = Path("A")
b = Path("B")
print("⟨A|A⟩ =", a1.overlap(a2))
print("⟨A|B⟩ =", a1.overlap(b))
⟨A|A⟩ = (1+0j)
⟨A|B⟩ = 0j
Expected behavior:
identical names give overlap
1different names give overlap
0
Role in composite mode labels¶
Path labels form one component of a composite
ModeLabel.
together with Polarization
\(\pi\) and an envelope
(typically a BaseEnvelope)
\(\zeta\).
The total mode overlap factorizes as
This allows routing changes and device actions to modify path labels independently of polarization or envelope structure.
Design notes¶
Path labels are discrete and orthonormal.
They distinguish spatial or logical channels.
They contribute multiplicatively to composite mode overlap.
They provide stable signatures for comparison and caching.