tidy3d.EMESimulation.smatrix_in_basis#
- EMESimulation.smatrix_in_basis(smatrix, port_modes, modes1=None, modes2=None)[source]#
Express a locally propagated S-matrix in another modal basis.
Pass the mode data for the left and right EME ports, typically
(mode_data[0], mode_data[-1])from the sequence used bypropagate(). Ifmodes1ormodes2isNone, that port is left unchanged.- Parameters:
smatrix (
EMESMatrixDataset) – Device S-matrix in the port-mode basis, as returned bypropagate(),propagate_from_overlaps(), orcompute_smatrix().port_modes (tuple[
ModeSimulationData|ModeSolverData, …]) – Mode results at the two EME ports.modes1 (
ElectromagneticFieldData,ModeSolverData, or) –ModeSimulationData, optional New modal bases at port 1 and port 2.modes2 (
ElectromagneticFieldData,ModeSolverData, or) –ModeSimulationData, optional New modal bases at port 1 and port 2.
- Returns:
S-matrix in the new basis.
- Return type: