

Then in the second simulation, we repeat the calculation by putting it into the slab. We're simulating a vacuum and we look at how the Poynting vector flux looks on the monitor plane as a functional frequency and that gives us the blue curve. In the first calculation, we would use the same computational domain with the source and the monitor, but without the slab. Therefore, in many of these simulations we typically do two calculations. To convert this into a transmission spectrum, however, we need to figure out the amount of power or intensity that's in the incident wave. How to calculate the transmission spectrum in FDTD As I mentioned in my last video for any finite difference time domain simulation, you will need to choose the boundary condition that truncates the computational domain. We choose a discretization so that each grid corresponds to a linear dimension of about 10 nanometer and that turns out to be sufficient to get to the accuracy that we need. However, in the next video we're going to use the same computational domain to simulate the photonic crystal slab structure, which has more complexity in the in-plane direction. In fact, because the silicon slab is uniform in the x and y dimension, you can in fact, choose a much smaller computational domain size, maybe even 0.1 or 0.2 micron would have worked. In the XY direction, we choose the size of the computational domain to be 2 microns. We choose 1.5 micron which corresponds to about one and a half wavelengths of free space below and above the silicon slab. We will add some free space below and above the silicon slab so that we can accommodate the source and the monitor on either side of the silicon slab. In our case, we will put the silicon slab in the middle of the computational domain. To start any FDTD simulation, the first thing that you need to do is to set up the computational cell or the computational domain. How to set up FDTD to simulate the transmission spectrum Medium ( permittivity = n_slab ** 2, name = 'silicon' ) # Grid resolution (cells per um) # dl = lambda_range / 30 / n_slab dl = 6e-3 # space between slabs and sources and PML spacing = 1 * lambda_range # simulation size sim_size = Lx, Ly, Lz = ( 2.0, 2.0, 2 * spacing + t_slab ) 0.38 for broadband freqw = bandwidth * ( freq_range - freq_range ) t_stop = 100 / freq0 # Thickness and refractive index of slab t_slab = 0.5 n_slab = 3.5 mat_slab = td. C_0 / freq0 bandwidth = 0.18 # bandwidth of source in units of delta frequency. C_0 / monitor_freqs # central frequency, frequency pulse width and total running time lambda0 = td. linspace ( freq_range, freq_range, Nfreq ) monitor_lambdas = td. sum ( freq_range ) / 2 Nfreq = 301 # frequencies and wavelengths of monitor monitor_freqs = np. # Wavelength and frequency range freq_range = ( 200e12, 400e12 ) lambda_range = ( td.
