tidy3d.EMECoefficientDataset#
- class EMECoefficientDataset[source]#
Bases:
DatasetDataset storing various coefficients related to the EME simulation.
- Parameters:
A (Optional[EMECoefficientDataArray] = None) – Coefficient for forward mode in this cell.
B (Optional[EMECoefficientDataArray] = None) – Coefficient for backward mode in this cell.
n_complex (Optional[EMEModeIndexDataArray] = None) – Complex-valued effective propagation indices associated with the EME modes.
flux (Optional[EMEFluxDataArray] = None) – Power flux of the EME modes.
interface_smatrices (Optional[
EMEInterfaceSMatrixDataset] = None) – S matrices associated with the interfaces between EME cells.overlaps (Optional[
EMEOverlapDataset] = None) – Overlaps between EME modes.
Notes
These coefficients can be used for debugging or optimization.
The
AandBfields store the expansion coefficients for the modes in a cell. These are defined at the cell centers.The
n_complexandfluxfields respectively store the complex-valued effective propagation index and the power flux associated with the modes used in the EME calculation.The
interface_Sijfields store the S matrices associated with the interfaces between EME cells.Example
>>> from tidy3d import EMECoefficientDataArray >>> f = [2e14] >>> sweep_index = [0] >>> eme_port_index = [0, 1] >>> eme_cell_index = [0, 1, 2] >>> mode_index_out = [0, 1] >>> mode_index_in = [0, 1] >>> coords = dict( ... f=f, sweep_index=sweep_index, eme_port_index=eme_port_index, ... eme_cell_index=eme_cell_index, ... mode_index_out=mode_index_out, mode_index_in=mode_index_in, ... ) >>> A = EMECoefficientDataArray((1+1j) * np.random.random((1, 1, 2, 3, 2, 2)), coords=coords) >>> data = EMECoefficientDataset(A=A, B=A)
Attributes
Return a flux-normalized copy of this dataset.
- A#
- B#
- n_complex#
- flux#
- interface_smatrices#
- overlaps#
- property normalized_copy#
Return a flux-normalized copy of this dataset.
The
AandBcoefficients as well as theinterface_smatricesare multiplied by the square root of the mode flux, so that the forward and backward power of each mode are given directly by|A|^2and|B|^2, respectively, without additional normalization by flux.- Returns:
A new dataset with flux-normalized coefficients. The
fluxfield is set toNoneto prevent double normalization.- Return type: