tidy3d.EMESimulationData#
- class EMESimulationData[source]#
Bases:
AbstractYeeGridSimulationData
Data associated with an EME simulation.
- Parameters:
attrs (dict = {}) โ Dictionary storing arbitrary metadata for a Tidy3D object. This dictionary can be freely used by the user for storing data without affecting the operation of Tidy3D as it is not used internally. Note that, unlike regular Tidy3D fields,
attrs
are mutable. For example, the following is allowed for setting anattr
obj.attrs['foo'] = bar
. Also note that Tidy3D` will raise aTypeError
ifattrs
contain objects that can not be serialized. One can check ifattrs
are serializable by callingobj.json()
.simulation (EMESimulation) โ EME simulation associated with this data.
data (Tuple[Annotated[Union[tidy3d.components.eme.data.monitor_data.EMEModeSolverData, tidy3d.components.eme.data.monitor_data.EMEFieldData, tidy3d.components.eme.data.monitor_data.EMECoefficientData, tidy3d.components.data.monitor_data.ModeSolverData], FieldInfo(default=PydanticUndefined, discriminator='type', extra={})], ...]) โ List of EME monitor data associated with the monitors of the original
EMESimulation
.log (Optional[str] = None) โ A string containing the log information from the simulation run.
smatrix (Optional[EMESMatrixDataset] = None) โ Scattering matrix of the EME simulation.
port_modes (Optional[EMEModeSolverData] = None) โ Modes associated with the two ports of the EME device. The scattering matrix is expressed in this basis.
Attributes
Port modes as a list of tuples
(port_modes_1, port_modes_2)
.Port modes as a tuple
(port_modes_1, port_modes_2)
.Custom logger to avoid the complexities of the logging module
Methods
field_in_basis
(field[,ย modes,ย port_index])Express the electromagnetic field in the provided basis.
smatrix_in_basis
([modes1,ย modes2])Express the scattering matrix in the provided basis.
Inherited Common Usage
- simulation#
- data#
- smatrix#
- port_modes#
- property port_modes_tuple#
Port modes as a tuple
(port_modes_1, port_modes_2)
.
- property port_modes_list_sweep#
Port modes as a list of tuples
(port_modes_1, port_modes_2)
. There is one entry for every sweep index if the port modes vary with sweep index.
- smatrix_in_basis(modes1=None, modes2=None)[source]#
Express the scattering matrix in the provided basis. Change of basis is done by computing overlaps between provided modes and port modes.
- Parameters:
- Returns:
The scattering matrix of the EME simulation, but expressed in the basis of the provided modes, rather than in the basis of
port_modes
used in computation.- Return type:
EMESMatrixDataset
- field_in_basis(field, modes=None, port_index=0)[source]#
Express the electromagnetic field in the provided basis. Change of basis is done by computing overlaps between provided modes and port modes.
- Parameters:
field (EMEFieldData) โ EME field to express in new basis.
modes (Union[FieldData, ModeData]) โ New modal basis. If None, use port_modes.
port_index (Literal[0, 1]) โ Port to excite.
- Returns:
The propagated electromagnetic fied expressed in the basis of the provided modes, rather than in the basis of
port_modes
used in computation.- Return type:
- __hash__()#
Hash method.