Module ebcm

Module ebcm 

Source
Expand description

Q-matrices of the extended boundary condition method (EBCM) for particles that are symmetric about the z axis, with analytic gradients for the surface and the media.

Upstream: treams.ebcm. qmat computes treams.ebcm.qmat with two differences:

  • radial_area_factor = true includes the factor r of the surface element (r rhat - r' theta-hat) r sin(theta) dtheta dphi, which treams omits; false reproduces treams. See https://yaugenst.github.io/treams-rs/latest/coming-from-treams/differences/.
  • It sums over the fixed polar nodes and weights of a Surface; the Python ebcm.qmat passes Gauss-Legendre nodes. treams integrates each matrix entry with the adaptive scipy.integrate.quad.

StructsΒ§

NodeGradient πŸ”’
The gradient contributions of one node: its radius and slope, and its share of the wavenumber and impedance gradients.
QmatGradient
Input gradients of QmatResidual::pullback.
QmatResidual
What qmat saves for its pullback: the modes, the surface and the media, without any wave values; the pullback evaluates the waves again.
Sample πŸ”’
Surface weight and normal of one node with the waves evaluated there.
SampleTangent πŸ”’
The value and directional derivative of a node’s integrand factors. Wave derivatives are contracted here, before assembling any matrix entries.
Surface
A surface of revolution r(theta) about the z axis, sampled at fixed polar quadrature nodes in [0, pi].

ConstantsΒ§

HELICITY πŸ”’
The sign 2 pol - 1 of polarizations 0 and 1 (negative and positive helicity), as helicity_sign gives it. A pair of helicities couples through the impedance factor HELICITY[a] z_outer + HELICITY[b] z_inner, so the impedance gradients use the same signs.

FunctionsΒ§

cross πŸ”’
a x n of a complex and a real vector.
dot πŸ”’
The bilinear (unconjugated) product a . b.
evaluate_waves πŸ”’
The first count waves of waves at point, which share their radial functions per degree and wavenumber and their solid harmonics per degree and order. N is the derivative level, VALUES or SPATIAL_AND_K.
node_geometry πŸ”’
The point of node i in the x-z plane, its unnormalized surface normal r rhat - r' theta-hat (r' is the slope dr/dtheta) and the unit vectors rhat and -theta-hat, along which the normal changes with the radius and the slope.
origin_waves πŸ”’
Spherical helicity waves of modes about the origin with wavenumbers ks. Only the wavenumbers of helicities with modes are evaluated. The other may be zero, which WaveSet::new rejects, so it takes the evaluated one’s value.
qmat
Integrate Q between regular inner test waves and regular or singular outer waves.
triple πŸ”’
The triple product n . (a x b).