Multi-Physics
- FEM
Calculate the waveguide modes with the full-vector finite-element method. Requires a ‘3D’ license. The cross-section is meshed with triangles that follow every material interface, and the mesh is refined where the modes are under-resolved, as set by the
fem_*settings insettings(). The saved fields, effective indices, losses and TE fractions are the same quantities, with the same normalization, as described underFDM(), soget(),get_fields(),report(),plot()andEME()work the same way. CallingFEM()sets the profile’ssolversetting to ‘FEM’.All
boundary_conditionvalues, PMLs, expansion regions, bends, lossy and anisotropic materials (including crystals tilted out of the cross-section withtheta), andheat()andelectrostatic()perturbations are supported. A symmetric or antisymmetric boundary on an axis whose mirror a crystal’s orientation breaks raises an error, since it would describe a different structure. Field plots sample the FEM solution atx_resolutionandy_resolution, andplot(mesh_display=True)shows the triangle mesh.The mesh is built by EMode’s own mesher, so a mesh, and every number solved on it, is the same on Windows, Linux and both kinds of Mac. Circles and ellipses are meshed to the true curve rather than to the polygon the FDM sees, and refinement adds its new boundary points on the curve.
fem_min_angle(no triangle has an angle below it) and each shape’sfem_resolution(the largest triangle edge in that shape) keep their meaning.With the default settings (3 points per wavelength, a 30 degree angle bound, three smoothing passes and three refinement passes), an effective index is within about 1e-4 of the converged value and a loss within about 1e-4 of its converged value, relatively, in a second or two for a typical cross-section. For more, set
fem_max_refinements='converge': the mesh is refined until every mode’s extrapolated effective index changes by less than 1e-8, which takes 20 s to a minute on a silicon or silicon nitride waveguide, andget('resolution_report')gives each mode’s estimated error. A round core converges more slowly, because its circle is meshed with straight edges between points on the curve, and stops near 1e-8 at about a million unknowns. The heat and electrostatic solves use first-order elements, so a quantity derived from them converges more slowly: the Phase Shifter example’sV_pi Lchanges by about 4e-4 between an eighth of its mesh sizes and the converged value.- Parameters:
profile (str or int) – the stored profile to solve, in place (one saved with
label_profile()), the same oneget(profile=...)reads. An unknown name raises an error listing the stored profiles. To save a solve under a new name, calllabel_profile()after it. Withsection, the name the solved slice is stored under. Default: ‘_default’section (str) – name of an EME section to solve a slice from, instead of the profile’s own settings/shapes, default: None
propagation_distance (float) – [nm] where along
sectionto take the cross-section, default: Noneinclude_heat (bool) – whether to include the temperature change from the most recent
heat()solve, default: Trueinclude_static (bool) – whether to apply the electro-optic (Pockels) permittivity perturbation from the most recent
electrostatic()solve, default: Trueverbose (bool) – print progress, default: True
simulation_name (str) – simulation name, default: ‘emode’
- Returns:
a dict with
n_eff_tilde,TE_fraction,TE_indices,TM_indices,PML_indicesandrefinement(n_eff_history,num_dofsandnum_elementsper refinement level, andstopped_by, the rule that ended refinement). The fields and the mesh are not part of the return value, since they run to tens of MB for many modes. Read the fields withget()orget_fields(), and draw them and the mesh withplot()(mesh_display=True). For a multi-wavelength profile, aWavelengthDictof these dicts, one per wavelength, indexable like adict[float, dict].
- heat
Run a steady-state thermal simulation of a waveguide cross-section. Requires a ‘3D’ license.
Note
Each
shape()now accepts an input parameter calledheat_only(default: False), which can be used to set additional shapes on top or bottom of the photonic layer stack. For example, commonheat_onlyshapes are the substrate and metal heater layers.Each
shape()also now accepts an input parameter calledfem_resolution(default: 500), which is used to refine the triangular mesh within certain shapes.Every material carries
thermal_conductivity(W/m·K),resistivity(Ohm·nm),dn_dT(1/K), andeps_r_dc. The defaults are1e-10, infinity,0, and1.0where no reliable published value has been entered.dn_dTandeps_r_dcare one value for every axis or three for the crystal’s x, y and z axes, and each principal index shifts by its owndn_dT. The mesh covers the shapes, so a region the shapes enclose without covering takes the background material’s properties. See the Material Database page for values and sources.- Parameters:
min_angle (float) – Smallest angle allowed in the triangle mesh, in degrees, at most 34. A larger value gives better-shaped triangles, and more of them. Default: 30.
boundary_temperature (float) – Fixed temperature boundary condition in ‘K’ set along each perimeter indicated by
boundaries. Default: 298.boundaries (list[str]) – ‘top’, ‘bottom’, ‘left’, or ‘right’. Indicates which boundaries are set to the fixed temperature
boundary_temperature. Default: [‘bottom’].verbose (bool) – Control the display of the progress bar. Default: True.
simulation_name (str) – Simulation name. Default: ‘emode’.
- Returns:
A dictionary/struct with the mesh points (
p), mesh triangles (t),temperature,thermal_conductivity, andheat_generationarrays. It also includes theboundary_temperatureandboundariessettings.
- electrostatic
Run a steady-state electrostatic simulation of a waveguide cross-section. Requires a ‘3D’ license.
Note
Each
shape()also now accepts an input parameter calledvoltage(default: None), which is set to create electric field sources. Shapes withvoltageleft as None do not get a voltage boundary condition applied.Each
shape()also now accepts an input parameter calledfem_resolution(default: 500), which is used to refine the triangular mesh within certain shapes.Each material in the EMode material database now has
eps_r_dc(relative permittivity at ~1 kHz), one value or three for the crystal’s x, y and z axes. The solve uses the in-plane (x, y) block of each material’s turnedeps_r_dctensor.The DC field derived here perturbs the permittivity through each material’s linear electro-optic (Pockels) tensor
r(get('<material>')['r'], m/V): \(\Delta(1/n^2)_{ij} = \sum_k r_{ijk} E_k\), then \(\Delta\varepsilon = -\varepsilon \cdot \Delta(1/n^2) \cdot \varepsilon\).FDM()applies this automatically on the next solve (include_static=Falseto skip it), the same wayheat()’s temperature field perturbs the permittivity throughdn_dT.- Parameters:
min_angle (float) – Smallest angle allowed in the triangle mesh, in degrees, at most 34. A larger value gives better-shaped triangles, and more of them. Default: 30.
verbose (bool) – Control the display of the progress bar. Default: True.
simulation_name (str) – Simulation name. Default: ‘emode’.
- Returns:
A dictionary/struct with the mesh points (
p), mesh triangles (t),voltage,eps_dc_grid(the in-plane DC permittivity of each element, shape (2, 2, number of elements)), the per-element electric field (Ex,Ey, in V/nm), andcentroids(element centers, in the optical window’s frame).