solprop.modes.rectangular#
Model gas-filled rectangular waveguides with dielectric or metallic walls.
The two wall pairs use the TE-like and TM-like reflection corrections of
Laakmann and Steier (1976), with the filled-core contrast eps_cl - eps_co and
the TM-like permittivity ratio eps_cl / eps_co. Complex wall corrections contribute
to both phase and attenuation. This is an asymptotic model, not exact boundary
matching: squaring the first-order boundary factor keeps a real second-order term the
expansion does not control, and the normalisation carries the vacuum admittance where
the modal power strictly carries the filled core’s, a choice of the order of the gas
susceptibility. The indices follow one convention: m runs along x and n along y.
One wall pair’s decrement (_transverse_term) and the material sampling and
TE-like/TM-like reflection coefficients (_WallPairFill) are shared with
the hollow planar guide of solprop.modes.slab, which is the one-wall-pair
limit b -> infinity of this guide.
Classes
|
Describe one polarisation of a hollow rectangular waveguide mode. |
- class solprop.modes.rectangular.RectMode(half_width_x, half_width_y, gas=None, pressure=0.0, *, n=1, m=1, polarisation='x', loss=True, cladding=None, temperature=None, susceptibility=None, mixture=None)[source]#
Bases:
_WallPairFillDescribe one polarisation of a hollow rectangular waveguide mode.
- Attributes:
- half_width_x, half_width_yfloat or ZProfile
Positive half-widths a and b in m. A shared path object gives a uniform scale taper; independently varying paths are not scale invariant.
- gasGas or str or None
Legacy gas declaration; None means vacuum unless a mixture is supplied.
- pressurefloat or ZProfile
Legacy gas pressure in bar, non-negative.
- n, mint
Positive mode indices along y and x respectively.
- polarisation{‘x’, ‘y’}
Nonzero transverse electric-field component. Its partner is a distinct mode with a different index unless the geometry makes them degenerate.
- lossbool or float or callable
Shared hollow-mode policy: model loss, no loss, a non-negative model scale, or an absolute power attenuation in 1/m.
- claddingGlassIndex or complex or None
Wall index, positive imaginary part for absorption. None selects fused silica.
- temperaturefloat, ZProfile or None
Positive legacy fill temperature in K, or a path of it along z in m, which the density follows.
None(the default) is 293.15 K for a gas and the mixture’s own beside a mixture; a different one beside it is refused.- susceptibilityGasSusceptibility or None
Explicit legacy gas susceptibility;
Nonetakes the built-in gas’s.- mixtureMixture or None
Ordered material populations; excludes competing legacy fill arguments.
- width_x, width_yZProfile
Resolved geometry paths in m.
- densityZProfile
Total number-density path in m^-3.
- cladding_indexGlassIndex or complex
Resolved wall material.
- model{‘full’, ‘reduced’}
Fixed internally to full, selecting the shared evanescent floor.
References
K. D. Laakmann and W. H. Steier, Applied Optics 15, 1334-1340 (1976), doi:10.1364/AO.15.001334. The filled-core factor
eps_cl / (eps_co s)of the TM-like coefficient follows from grazing-incidence Fresnel reflection; it reduces to the publishedeps_cl / sfor an evacuated core.Examples
>>> mode = RectMode(50e-6, 12.5e-6, "Ar", 1.0) >>> mode.principal_component(), mode.orthogonal_polarisation.principal_component() ('x', 'y') >>> f"{mode.aeff():.6e}" '1.111111e-09'
- aeff(z=0.0)[source]#
Return the closed-form effective area.
- Parameters:
- zfloat, optional
Position in m.
- Returns:
- float
16 a b / 9 in m², independent of mode index and fill.
- at_parameters(values)[source]#
Copy the mode with the supplied geometry and fill paths frozen.
- Parameters:
- valuescollections.abc.Mapping
A subset of the declared paths, in m, m^-3 or shared pressure in bar.
- Returns:
- RectMode
A copy retaining unspecified paths and the same wall model.
- Raises:
- ModeError
If a path is unknown or a half-width is invalid.
- property azimuthal_order: int[source]#
Return the larger Cartesian order as a geometry-resolution hint.
- Returns:
- int
Maximum of n and m. Cartesian Gauss rules integrate trigonometric products, not polynomials; their required node count is measured, not derived (see
solprop.modes.quadrature.cartesian_nodes()).
- property channel_label: ChannelLabel[source]#
Return the rectangular family, its two indices and its polarisation.
- Returns:
- ChannelLabel
Family
rect, withnandmin the azimuthal and radial fields – a rectangular guide has neither, but they are the two indices the record carries – and the polarisation in the display label. The other polarisation is a distinct mode with its own operator row, not a parity partner of this one, soparitystaysNone.
Examples
>>> from solprop.modes import RectMode >>> RectMode(50e-6, 12.5e-6, "Ar", 1.0).channel_label.display_label 'rect1,1:x'
- cladding: GlassIndex | complex | None = None#
- cladding_index: GlassIndex | complex#
- dimlimits(z=0.0)[source]#
Return the Cartesian cross-section and its integration bounds.
- Parameters:
- zfloat, optional
Position in m.
- Returns:
- tuple
Cartesian rectangle from (-a, -b) to (a, b), in m.
- dneff_domega(omega, z=0.0)[source]#
Return the analytic derivative including core and wall material slopes.
- Parameters:
- omeganumpy.ndarray
Positive frequencies in rad/s.
- zfloat, optional
Position in m.
- Returns:
- numpy.ndarray
Complex index derivative in s/rad; only a slope-free loss callable uses the shared numerical loss derivative.
- field(points, z=0.0)[source]#
Return the unnormalised real Cartesian electric-field components.
- Parameters:
- pointsnumpy.ndarray
Cartesian (x,y) coordinates in m, shape (n_points, 2).
- zfloat, optional
Position in m.
- Returns:
- numpy.ndarray
(Ex,Ey), shape (n_points, 2); zero outside the hollow rectangle.
- Raises:
- ModeError
If points are non-finite or have an invalid shape.
- neff(omega, z=0.0)[source]#
Return the effective index with positive imaginary part for attenuation.
- Parameters:
- omeganumpy.ndarray
Positive frequencies in rad/s.
- zfloat, optional
Position in m.
- Returns:
- numpy.ndarray
Complex effective index, shape (n_omega,).
- neff_minus_one(omega, z=0.0)[source]#
Return refractivity directly from the small square-root argument.
- Parameters:
- omeganumpy.ndarray
Positive frequencies in rad/s.
- zfloat, optional
Position in m.
- Returns:
- numpy.ndarray
Complex n_eff - 1, without subtracting unity from the returned index.
- normalisation(z=0.0)[source]#
Return the power carried by the unnormalised transverse profile.
- Parameters:
- zfloat, optional
Position in m.
- Returns:
- float
Power eps0 c a b / 2 in W.
- property orthogonal_polarisation: RectMode[source]#
Return the distinct mode with the other electric-field orientation.
- Returns:
- RectMode
Same indices, geometry and fill, with the other wall-pair assignment. It requires its own operator row; it is not a duplicated scalar index.
- property parameter_paths: Mapping[str, ZProfile][source]#
Return the geometry and material paths carrying longitudinal variation.
- Returns:
- collections.abc.Mapping
Half-width paths plus the shared fill’s density or pressure paths.
- property polarisation_degenerate: bool[source]#
Return whether the two polarisations share one effective index.
- Returns:
- bool
False: the x- and y-polarised modes of one (n, m) take the TE-like and TM-like coefficients on opposite wall pairs, so they are distinct modes and need a row each.
- principal_component(z=0.0)[source]#
Return the nonzero Cartesian electric-field component.
- Parameters:
- zfloat, optional
Longitudinal position in m; orientation is fixed.
- Returns:
- str
The component, x or y.
- property radius_is_constant: bool[source]#
Return the transform’s geometry-constant trait for the rectangle.
- Returns:
- bool
True when both half-width paths are constant; the historical trait name also serves Cartesian modes.
- property scale_invariant: bool[source]#
Return whether one scalar rescaling represents the geometry.
- Returns:
- bool
True for constant half-widths or the same path object on both axes.
- susceptibility: GasSusceptibility | None = None#