tidy3d.FullyAnisotropicMedium#

class FullyAnisotropicMedium[source]#

Bases: AbstractMedium

Fully anisotropic medium including all 9 components of the permittivity and conductivity tensors.

Parameters:
  • name (Attribute: name) –

    Type

    Optional[str]

    Default

    = None

    Description

    Optional unique name for medium.

  • frequency_range (Attribute: frequency_range) –

    Type

    Optional[Tuple[float, float]]

    Default

    = None

    Units

    (Hz, Hz)

    Description

    Optional range of validity for the medium.

  • allow_gain (Attribute: allow_gain) –

    Type

    bool

    Default

    = False

    Description

    Allow the medium to be active. Caution: simulations with a gain medium are unstable, and are likely to diverge.Simulations where ‘allow_gain’ is set to ‘True’ will still be charged even if diverged. Monitor data up to the divergence point will still be returned and can be useful in some cases.

  • nonlinear_spec (Attribute: nonlinear_spec) –

    Type

    Union[NonlinearSpec, NonlinearSusceptibility]

    Default

    = None

    Description

    Nonlinear spec applied on top of the base medium properties.

  • modulation_spec (Attribute: modulation_spec) –

    Type

    Optional[ModulationSpec]

    Default

    = None

    Description

    Modulation spec applied on top of the base medium properties.

  • heat_spec (Attribute: heat_spec) –

    Type

    Union[FluidSpec, SolidSpec, NoneType]

    Default

    = None

    Description

    Specification of the medium heat properties. They are used for solving the heat equation via the HeatSimulation interface. Such simulations can be used for investigating the influence of heat propagation on the properties of optical systems. Once the temperature distribution in the system is found using HeatSimulation object, Simulation.perturbed_mediums_copy() can be used to convert mediums with perturbation models defined into spatially dependent custom mediums. Otherwise, the heat_spec does not directly affect the running of an optical Simulation.

  • permittivity (Attribute: permittivity) –

    Type

    ArrayLike[dtype=float, ndim=2, shape=(3, 3)]

    Default

    = [[1, 0, 0], [0, 1, 0], [0, 0, 1]]

    Units

    None (relative permittivity)

    Description

    Relative permittivity tensor.

  • conductivity (Attribute: conductivity) –

    Type

    ArrayLike[dtype=float, ndim=2, shape=(3, 3)]

    Default

    = [[0, 0, 0], [0, 0, 0], [0, 0, 0]]

    Units

    S/um

    Description

    Electric conductivity tensor. Defined such that the imaginary part of the complex permittivity at angular frequency omega is given by conductivity/omega.

Notes

Provided permittivity tensor and the symmetric part of the conductivity tensor must have coinciding main directions. A non-symmetric conductivity tensor can be used to model magneto-optic effects. Note that dispersive properties and subpixel averaging are currently not supported for fully anisotropic materials.

Note

Simulations involving fully anisotropic materials are computationally more intensive, thus, they take longer time to complete. This increase strongly depends on the filling fraction of the simulation domain by fully anisotropic materials, varying approximately in the range from 1.5 to 5. The cost of running a simulation is adjusted correspondingly.

Example

>>> perm = [[2, 0, 0], [0, 1, 0], [0, 0, 3]]
>>> cond = [[0.1, 0, 0], [0, 0, 0], [0, 0, 0]]
>>> anisotropic_dielectric = FullyAnisotropicMedium(permittivity=perm, conductivity=cond)

See also

CustomAnisotropicMedium

Diagonally anisotropic medium with spatially varying permittivity in each component.

AnisotropicMedium

Diagonally anisotropic medium.

Notebooks

Attributes

eps_sigma_diag

Main components of permittivity and conductivity tensors and their directions.

n_cfl

This property computes the index of refraction related to CFL condition, so that the FDTD with this medium is stable when the time step size that doesn't take material factor into account is multiplied by n_cfl.

Methods

conductivity_commutes(val, values)

Check that the symmetric part of conductivity tensor commutes with permittivity tensor (that is, simultaneously diagonalizable).

eps_comp(row, col, frequency)

Single component the complex-valued permittivity tensor as a function of frequency.

eps_diagonal(frequency)

Main diagonal of the complex-valued permittivity tensor as a function of frequency.

eps_model(frequency)

Complex-valued permittivity as a function of frequency.

from_diagonal(xx, yy, zz, rotation)

Construct a fully anisotropic medium by rotating a diagonally anisotropic medium.

permittivity_spd_and_ge_one(val)

Check that provided permittivity tensor is symmetric positive definite with eigenvalues >= 1.

plot(freqs[, ax])

Plot n, k of a FullyAnisotropicMedium as a function of frequency.

permittivity#
conductivity#
classmethod permittivity_spd_and_ge_one(val)[source]#

Check that provided permittivity tensor is symmetric positive definite with eigenvalues >= 1.

classmethod conductivity_commutes(val, values)[source]#

Check that the symmetric part of conductivity tensor commutes with permittivity tensor (that is, simultaneously diagonalizable).

classmethod from_diagonal(xx, yy, zz, rotation)[source]#

Construct a fully anisotropic medium by rotating a diagonally anisotropic medium.

Parameters:
  • xx (Medium) – Medium describing the xx-component of the diagonal permittivity tensor.

  • yy (Medium) – Medium describing the yy-component of the diagonal permittivity tensor.

  • zz (Medium) – Medium describing the zz-component of the diagonal permittivity tensor.

  • rotation (Union[RotationAroundAxis]) – Rotation applied to diagonal permittivity tensor.

Returns:

Resulting fully anisotropic medium.

Return type:

FullyAnisotropicMedium

property eps_sigma_diag#

Main components of permittivity and conductivity tensors and their directions.

eps_model(frequency)[source]#

Complex-valued permittivity as a function of frequency.

eps_diagonal(frequency)[source]#

Main diagonal of the complex-valued permittivity tensor as a function of frequency.

eps_comp(row, col, frequency)[source]#

Single component the complex-valued permittivity tensor as a function of frequency.

Parameters:
  • row (int) – Component’s row in the permittivity tensor (0, 1, or 2 for x, y, or z respectively).

  • col (int) – Component’s column in the permittivity tensor (0, 1, or 2 for x, y, or z respectively).

  • frequency (float) – Frequency to evaluate permittivity at (Hz).

Returns:

Element of the relative permittivity tensor evaluated at frequency.

Return type:

complex

property n_cfl#

This property computes the index of refraction related to CFL condition, so that the FDTD with this medium is stable when the time step size that doesn’t take material factor into account is multiplied by n_cfl.

For this medium, it take the minimal of sqrt(permittivity) for main directions.

plot(freqs, ax=None)[source]#

Plot n, k of a FullyAnisotropicMedium as a function of frequency.

__hash__()#

Hash method.