Correct for numerical dispersion at 3d solve_waveguide_mode level
This commit is contained in:
parent
af8efd00eb
commit
c306bb1f46
1 changed files with 3 additions and 0 deletions
|
|
@ -111,6 +111,9 @@ def solve_waveguide_mode(mode_number: int,
|
|||
'''
|
||||
Apply corrections and expand to 3D
|
||||
'''
|
||||
# Correct wavenumber to account for numerical dispersion.
|
||||
fields_2d['wavenumber'] = 2/dx_prop * numpy.arcsin(fields_2d['wavenumber'] * dx_prop/2)
|
||||
|
||||
# Adjust for propagation direction
|
||||
fields_2d['E'][2] *= polarity
|
||||
fields_2d['H'][2] *= polarity
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue