Dennis M. Sullivan

Electromagnetic Simulation Using the FDTD Method with Python


Скачать книгу

by caption."/>

are needed.

      This is the fundamental paradigm of the FDTD method (1).

      Substituting this into Eq. (1.4a) and (1.4b) gives

      Once the cell size Δx is chosen, then the time step Δt is determined by

      where c0 is the speed of light in free space. (The reason for this will be explained in Section 1.2.) Therefore, remembering that ε0μ0 = 1/(c0)2,

      1 The Ex and Hy values are calculated by separate loops, and they employ the interleaving described above.

      2 After the Ex values are calculated, the source is calculated. This is done by simply specifying a value of Ex at the point k = kc and overriding what was previously calculated. This is referred to as a hard source because a specific value is imposed on the FDTD grid.

      1 Get the program fd1d_1_1.py running. What happens when the pulse hits the end of the array? Why?

      2 Modify the program so it has two sources, one at kc ‐ 20 and one at kc + 20. (Notice that kc is the center of the problem space.) What happens when the pulses meet? Explain this from basic electromagnetic (EM) theory.

      3 Instead of Ex as the source, use Hy at k = kc as the source. What difference does it make? Try a two‐point magnetic source at kc ‐ 1 and kc such that hy[kc ‐ 1] = ‐ hy[kc]. What does this look like? To what does it correspond physically?

      Let us return to the discussion of how to determine the time step. An EM wave propagating in free space cannot go faster than the speed of light. To propagate a distance of one cell requires a minimum time of Δt = Δx/c0. With a two‐dimensional simulation, we must allow for the propagation in the diagonal direction, which brings the requirement to

. Obviously, a three‐dimensional simulation requires
. This is summarized by the well‐known Courant Condition (3, 4):

      (1.10)

      where n is the dimension of the simulation. Unless otherwise specified, throughout this book we will determine Δt by

      (1.11)

      This is not necessarily the best formula; we will use it for simplicity to avoid using square roots.

      1 In fd1d_1_1.py, go to the governing equations, Eq. (1.9a) and (1.9b), and change the factor 0.5 to 1.0. What happens? Change it to 1.1. Now what happens? Change it to 0.25 and see what happens.