tidy3d.PermittivityData#

class PermittivityData[source]#

Bases: PermittivityDataset, AbstractFieldData

Data for a PermittivityMonitor: diagonal components of the permittivity tensor.

Parameters:
  • monitor (Attribute: monitor) –

    Type

    PermittivityMonitor

    Default

    Description

    Permittivity monitor associated with the data.

  • symmetry (Attribute: symmetry) –

    Type

    Tuple[Literal[0, -1, 1], Literal[0, -1, 1], Literal[0, -1, 1]]

    Default

    = (0, 0, 0)

    Description

    Symmetry eigenvalues of the original simulation in x, y, and z.

  • symmetry_center (Attribute: symmetry_center) –

    Type

    Optional[Tuple[float, float, float]]

    Default

    = None

    Description

    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 (Attribute: grid_expanded) –

    Type

    Optional[Grid]

    Default

    = None

    Description

    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 and flux.

  • eps_xx (Attribute: eps_xx) –

    Type

    ScalarFieldDataArray

    Default

    Description

    Spatial distribution of the xx-component of the relative permittivity.

  • eps_yy (Attribute: eps_yy) –

    Type

    ScalarFieldDataArray

    Default

    Description

    Spatial distribution of the yy-component of the relative permittivity.

  • eps_zz (Attribute: eps_zz) –

    Type

    ScalarFieldDataArray

    Default

    Description

    Spatial distribution of the zz-component of the relative permittivity.

Notes

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

Example

>>> from tidy3d import ScalarFieldDataArray
>>> x = [-1,1,3]
>>> y = [-2,0,2,4]
>>> z = [-3,-1,1,3,5]
>>> f = [2e14, 3e14]
>>> coords = dict(x=x[:-1], y=y[:-1], z=z[:-1], f=f)
>>> grid = Grid(boundaries=Coords(x=x, y=y, z=z))
>>> sclr_fld = ScalarFieldDataArray((1+1j) * np.random.random((2,3,4,2)), coords=coords)
>>> monitor = PermittivityMonitor(size=(2,4,6), freqs=[2e14, 3e14], name='eps')
>>> data = PermittivityData(
...     monitor=monitor, eps_xx=sclr_fld, eps_yy=sclr_fld, eps_zz=sclr_fld, grid_expanded=grid
... )

Attributes

Methods

monitor#
__hash__()#

Hash method.