tidy3d.EMEModeSolverDataset#
- class EMEModeSolverDataset[source]#
Bases:
ElectromagneticFieldDatasetDataset storing the eigenmodes computed at each EME cell.
- Parameters:
Ex (EMEScalarModeFieldDataArray) – Spatial distribution of the x-component of the electric field of the mode.
Ey (EMEScalarModeFieldDataArray) – Spatial distribution of the y-component of the electric field of the mode.
Ez (EMEScalarModeFieldDataArray) – Spatial distribution of the z-component of the electric field of the mode.
Hx (EMEScalarModeFieldDataArray) – Spatial distribution of the x-component of the magnetic field of the mode.
Hy (EMEScalarModeFieldDataArray) – Spatial distribution of the y-component of the magnetic field of the mode.
Hz (EMEScalarModeFieldDataArray) – Spatial distribution of the z-component of the magnetic field of the mode.
n_complex (EMEModeIndexDataArray) – Complex-valued effective propagation indices associated with the mode.
Notes
Each field component is an
EMEScalarModeFieldDataArraywith coordinates(x, y, z, f, eme_cell_index, mode_index)and optionallysweep_indexwhen a frequency sweep is used. Also stores the complex propagation indexn_complexfor each mode.Example
>>> from tidy3d import EMEScalarModeFieldDataArray, EMEModeIndexDataArray >>> x = [0, 1] >>> y = [0, 1, 2] >>> z = [0] >>> f = [2e14] >>> sweep_index = [0] >>> eme_cell_index = [0, 1, 2] >>> mode_index = [0, 1] >>> field_coords = dict( ... x=x, y=y, z=z, f=f, sweep_index=sweep_index, ... eme_cell_index=eme_cell_index, mode_index=mode_index, ... ) >>> field = EMEScalarModeFieldDataArray( ... (1+1j) * np.random.random((2,3,1,1,1,3,2)), coords=field_coords ... ) >>> index_coords = dict( ... f=f, sweep_index=sweep_index, eme_cell_index=eme_cell_index, mode_index=mode_index, ... ) >>> n_complex = EMEModeIndexDataArray((1+0.01j) * np.ones((1,1,3,2)), coords=index_coords) >>> data = EMEModeSolverDataset( ... n_complex=n_complex, Ex=field, Ey=field, Ez=field, Hx=field, Hy=field, Hz=field, ... )
Attributes
- n_complex#
- Ex#
- Ey#
- Ez#
- Hx#
- Hy#
- Hz#