# CustomMedium

Medium with user-supplied permittivity distribution. The medium panel groups the fields under Optical Properties. Less common options are under Advanced, and display settings are under Appearance.

# Name

name: Optional unique name for the medium. The name appears in the Mediums list and is separate from the optical and thermal properties.

# Thermal Properties

This section appears when the task group includes a Heat solver and is omitted from a standalone FDTD task.

# Medium Type

type: Selects the thermal model under Medium Type.

Type: string

Options:

  • FluidSpec: The Heat solver does not solve for temperature in regions that use this medium.
  • SolidSpec: The Heat solver uses the solid thermal model.

Default: SolidSpec for a new medium in a Heat simulation.

# Thermal Conductivity

conductivity: Thermal conductivity. This field is shown when Medium Type is SolidSpec.

Type: floating-point number

  • Unit: W/(μm·K)
  • Constraint: greater than 0
  • Required field

NOTE

The editor has no inputs for heat capacity (capacity) or density (density). When you create a medium in a Heat simulation, the editor sets capacity to 1. To set other values, use the Python interface. See Thermal Properties for the API fields.

# Optical Properties

# Interpolation Method

interp_method: Interpolation method to obtain permittivity values that are not supplied at the Yee grids.

For grids outside the range of the supplied data, extrapolation will be applied. When the extrapolated value is smaller (greater) than the minimal (maximal) of the supplied data, the extrapolated value will take the minimal (maximal) of the supplied data.

Options:

  • nearest
  • linear

Default: nearest

# Subpixel

subpixel: If True and the simulation’s subpixel setting is also True, applies subpixel averaging of the permittivity on the interface of the structure, including exterior boundaries and intersections with other structures.

Type: boolean

Default: False

# Permittivity

permittivity: Spatial profile of relative permittivity. Use Import Material to load a supported medium HDF5 file containing the permittivity dataset.

If you prepare the upload outside the editor, create the corresponding medium with the Python interface and call to_hdf5(filename) (opens new window) to write the expected HDF5 dataset structure. For a spatially varying medium, see the Custom Medium tutorial (opens new window).

Type: SpatialDataArray

  • Unit: unitless
  • Constraint: every value in the spatial permittivity profile must be greater than or equal to 1

# Conductivity

conductivity: Spatial profile of the electric conductivity. The imaginary part of the complex permittivity at angular frequency omega is given by conductivity/omega. Use Import Material to load the conductivity dataset together with the permittivity dataset.

If you prepare the upload outside the editor, create the corresponding medium with the Python interface and call to_hdf5(filename) (opens new window) to write the expected HDF5 dataset structure.

Type: SpatialDataArray

  • Unit: S/μm

# Complex-valued Permittivity Dataset

eps_dataset: User-supplied dataset containing complex-valued permittivity as a function of space. The permittivity distribution over the Yee grid is interpolated using interp_method. Use Import Material to load the complex-valued dataset.

If you prepare the upload outside the editor, create the corresponding medium with the Python interface and call to_hdf5(filename) (opens new window) to write the expected HDF5 dataset structure.

Type: SpatialDataArray

  • Unit: unitless
  • Constraint: relative permittivity at infinite frequency must be greater than or equal to 1

# Advanced

frequency_range: Optional lower and upper frequency bounds for the medium.

Type: pair of floating-point numbers

  • Unit: Hz for both values
  • Constraint: each value greater than 0
  • Default: None

allow_gain: Enable gain medium. Caution: simulations with gain medium are unstable and are likely to diverge. Simulations with this option enabled are still charged even if they diverge. Monitor data up to the divergence point is still returned and can be useful in some cases.

Type: boolean

Default: False

# Appearance

Appearance settings control the medium’s face color and transparency in the model view. They do not change the optical properties.