API Design#

Meshing#

Meshing

get_layer_overlaps_z(layer_stack[, include_zmax])

Maps layers to unique LayerStack z coordinates.

get_layers_at_z(layer_stack, z)

Returns layers present at a given z-position.

list_unique_layer_stack_z(layer_stack)

List all unique LayerStack z coordinates.

map_unique_layer_stack_z(layer_stack[, ...])

Map unique LayerStack z coordinates to various layers.

order_layer_stack(layer_stack)

Orders layer_stack according to mesh_order.

get_u_bounds_layers(layer_polygons_dict, ...)

Given a layer_polygons_dict and two coordinates (x1,y1), (x2,y2).

get_u_bounds_polygons(polygons, xsection_bounds)

Performs the bound extraction given a (Multi)Polygon or [Polygon] and cross-sectional line coordinates.

get_uz_bounds_layers(layer_polygons_dict, ...)

Given a component and layer stack, computes the bounding box(es).

uz_xsection_mesh(component, xsection_bounds, ...)

Mesh uz cross-section of component along line u = [[x1,y1] , [x2,y2]].

xy_xsection_mesh(component, z, layer_stack, ...)

Mesh xy cross-section of component at height z.

Mode solvers#

Mode solver tidy3d

Waveguide(*[, wavelength, box_material, ...])

Waveguide Model.

WaveguideCoupler(*[, wavelength, ...])

Waveguide coupler Model.

sweep_n_eff(waveguide, **sweep_kwargs)

Return the effective index for a range of waveguide geometries.

sweep_n_group(waveguide, **sweep_kwargs)

Return the group index for a range of waveguide geometries.

sweep_bend_mismatch(waveguide, bend_radii)

Overlap integral squared for the bend mode mismatch loss.

sweep_coupling_length(coupler, gaps[, ...])

Calculate coupling length for a series of gap sizes.

Mode solver Femwell

compute_cross_section_modes(cross_section, ...)

Calculate effective index of a cross-section.

EME (Eigen Mode Expansion)

MEOW(component, layer_stack[, wavelength, ...])

FDTD Simulation#

Sparameter utils

plot_sparameters(sp[, logscale, plot_phase, ...])

Plots Sparameters from a dict of np.ndarrays.

plot_imbalance2x2(sp, *[, ports, ax])

Plots imbalance in dB for coupler.

plot_loss2x2(sp, *[, ports, ax])

Plots loss dB for coupler.

common FDTD functions

get_effective_indices(core_material, ...)

Returns the effective refractive indices for a 1D mode.

pandas_to_float64(df[, magnitude_suffix, ...])

Converts a pandas CSV sparameters from complex128 format to 2x float64 format.

pandas_to_numpy(df[, port_map])

Converts a pandas CSV sparameters into a numpy array.

csv_to_npz(filepath)

Convert CSV files into numpy.

convert_directory_csv_to_npz(dirpath)

Convert CSV files from directory dirpath into numpy.

FDTD tidy3d

write_sparameters(component[, layer_stack, ...])

Writes the S-parameters for a component.

write_sparameters_grating_coupler(component)

Get sparameter matrix from a gdsfactory grating coupler.

write_sparameters_grating_coupler_batch(...)

Returns Sparameters for a list of write_sparameters.

FDTD lumerical

write_sparameters_lumerical(component[, ...])

Returns and writes component Sparameters using Lumerical FDTD.

Circuit solver#

SAX

read.model_from_csv(filepath[, xkey, ...])

Returns a SAX Sparameters Model from a CSV file.

read.model_from_component(component, ...)

Returns SAX model from lumerical FDTD simulations.

plot_model(model[, port1, ports2, logscale, ...])

Plot Model Sparameters Magnitude.

models

Lumerical interconnect

install_design_kit(session, cml_path[, ...])

add_interconnect_element(session, label, model)

Add an element to the Interconnect session.

get_interconnect_settings(instance)

send_to_interconnect(component, session[, ...])

Send netlist components to Interconnect and connect them according to netlist.

run_wavelength_sweep(component[, session, ...])

Args are the following.

plot_wavelength_sweep(ports_out, results[, ...])

Electrostatics#

Elmer

run_capacitive_simulation_elmer(component[, ...])

Run electrostatic finite element method simulations using `Elmer`_.

Palace

run_capacitive_simulation_palace(component)

Run electrostatic finite element method simulations using `Palace`_.

Full-wave RF#

Palace

run_scattering_simulation_palace(component)

Run full-wave finite element method simulations using Palace.