legume.viz.eps_yz
- legume.viz.eps_yz(phc, x=0, Ny=100, Nz=50, ax=None, clim=None, cbar=False, cmap='Greys', cax=None, plot=True)
Plot permittivity cross section of a photonic crystal in an yz plane
- Parameters:
phc (PhotCryst)
x (float, optional) – The x-coordinate of the xz plane. Default is 0.
Ny (int, optional) – Number of sample points to use in y-direction. Default is 100.
Nz (int, optional) – Number of sample points to use in z-direction. Default is 50.
ax (int, optional) – Matplotlib axis object to use for plot.
clim (List[float], optional) – Matplotlib color limit to use for plot. Default is None.
cbar (bool, optional) – Whether or not a colorbar should be added to the plot. Default is False.
cmap (string, optional) – Matplotlib colormap to use for plot Default is ‘Greys’.
cax (matplotlib axis object, optional) – Axis handle for the colorbar Default it None.
plot (bool, optional) – Whether or not the a plot should be generated. Useful for cases where only the array values are needed, e.g. for logging during optimization. Default is True.
- Returns:
eps_r – Array containing permittivity values
- Return type:
np.ndarray