tidy3d.AuxFieldTimeData

tidy3d.AuxFieldTimeData#

class AuxFieldTimeData[source]#

Bases: AuxFieldTimeDataset, AbstractFieldData

Data associated with a AuxFieldTimeMonitor: scalar components of aux fields.

Parameters:
  • monitor (AuxFieldTimeMonitor) – Time-domain auxiliary field monitor associated with the data.

  • symmetry (tuple[Literal[0, -1, 1], Literal[0, -1, 1], Literal[0, -1, 1]] = (0, 0, 0)) – Symmetry eigenvalues of the original simulation in x, y, and z.

  • symmetry_center (Optional[tuple[float, float, float]] = None) – Center of the symmetry planes of the original simulation in x, y, and z. Required only if any of the symmetry field are non-zero.

  • grid_expanded (Optional[Grid] = None) – Grid discretization of the associated monitor in the simulation which created the data. Required if symmetries are present, as well as in order to use some functionalities like getting Poynting vector and flux.

  • Nfx (Optional[ScalarFieldTimeDataArray] = None) – Spatial distribution of the free carrier density for polarization in the x-direction.

  • Nfy (Optional[ScalarFieldTimeDataArray] = None) – Spatial distribution of the free carrier density for polarization in the y-direction.

  • Nfz (Optional[ScalarFieldTimeDataArray] = None) – Spatial distribution of the free carrier density for polarization in the z-direction.

Notes

The data is stored as a DataArray object using the xarray package.

Example

>>> from tidy3d import ScalarFieldTimeDataArray
>>> x = [-1,1,3]
>>> y = [-2,0,2,4]
>>> z = [-3,-1,1,3,5]
>>> t = [0, 1e-12, 2e-12]
>>> coords = dict(x=x[:-1], y=y[:-1], z=z[:-1], t=t)
>>> grid = Grid(boundaries=Coords(x=x, y=y, z=z))
>>> scalar_field = ScalarFieldTimeDataArray(np.random.random((2,3,4,3)), coords=coords)
>>> monitor = AuxFieldTimeMonitor(
...     size=(2,4,6), interval=100, name='field', fields=['Nfx'], colocate=True
... )
>>> data = AuxFieldTimeData(monitor=monitor, Nfx=scalar_field, grid_expanded=grid)

Attributes

monitor

Nfx

Nfy

Nfz

symmetry

symmetry_center

grid_expanded

monitor#