36
4/24/2021 1 Computational Science: Introduction to FiniteDifference TimeDomain The Perfectly Matched Layer Lecture Outline Review of Lecture 12 Background Information The Uniaxial Perfectly Matched Layer (UPML) Calculating the PML parameters Convolutional PML (CPML) Incorporating a UPML into Maxwell’s equations Final Notes About PMLs Slide 2

Lecture -- The Perfectly Matched Layer - EMPossible

  • Upload
    others

  • View
    3

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

1

Computational Science:

Introduction to Finite‐Difference Time‐Domain

The Perfectly Matched Layer

Lecture Outline

• Review of Lecture 12

• Background Information

• The Uniaxial Perfectly Matched Layer (UPML)

• Calculating the PML parameters

• Convolutional PML (CPML)

• Incorporating a UPML into Maxwell’s equations

• Final Notes About PMLs

Slide 2

Page 2: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

2

Slide 3

Review

Effect of “Windowing” on FDTD Spectrum

Slide 4

• Long simulation time•Wide window• Narrow window spectrum• Less “blurring”• High frequency resolution

•Moderate simulation time•Moderate window•Moderate window spectrum•More “blurring”• Reduced frequency resolution

• Short simulation time• Narrow window•Wide window spectrum•Much “blurring”• Poor frequency resolution

W H

h t

w t

H W

W

H

h t

w t

H W

W

H

h t

w t

H W

Page 3: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

3

Ensuring Sufficient Iterations to Resolve f

Slide 5

Given the time step t, the Nyquist sampling theorem quantifies the highest frequency that can be resolved.

max

1

2f

t

Given the FDTD simulation runs for STEPS number of iterations, the frequency resolution is

max2 1

STEPS STEPS

ff

t

Therefore, to resolve the frequency response down to a resolution of f, the number of iterations required is

1STEPS

t f

Note:  In practice, you should setmax

1 10t

t

t NN f

Notes:1. This is related to the uncertainty principle.2. You can calculate kernels for very finely spaced frequency 

points, but the actual frequency resolution is still limited by the windowing effect.  Your data will be “blurred.”

Dielectric Smoothing

Slide 6

Physical Device

Conventional Representation on Grid

Representation on Gridwith Dielectric Smoothing

x

y

Page 4: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

4

Anisotropic Dielectric Smoothing

Slide 7

Given the simulation problem defined by

11

smooth N̂

D E

Convergence rate can be improved by smoothing the dielectric function according to

2

2

2

ˆx x y x z

y x y y z

z x z y z

n n n n n

N n n n n n

n n n n n

Dielectric Smoothing of a Sphere

Slide 8

Given a sphere with dielectric constant r=5.0 in air and in a grid with Nx=Ny=Nz=25 cells, the dielectric tensor after averaging is

xy cross section

xz cross section

Page 5: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

5

2× Grid Technique

Slide 9

The 2× grid is only used for building devices on a Yee grid.It is not used anywhere else!

Concept of the 2× Grid

Slide 10

i

j

i

j

The Conventional 1× Grid

y

x

Due to the staggered nature of the Yee grid, 

we are effectively getting twice the 

resolution.

i

j

It now makes sense to talk 

about a grid that is at twice the resolution, the 

“2× grid.”

Ez

Hy

HxThe 2× grid concept is useful because we can create devices (or PMLs) on the 2× grid without having to think about where the different field components are located.  In a second step, we can easily pull off the values from the 2× grid where they exist for a particular field component.

Page 6: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

6

Parsing the Materials From 2× to 1× Grid

Slide 11

Ez

Hy

Hx

ERzz

URxx

URyy

Slide 12

Background

Page 7: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

7

Tensors

Slide 13

Tensors are a generalization of a scaling factor where the direction of a vector can be altered in addition to its magnitude.

V

aV

V a V

Scalar Relation 

Tensor Relation

xx xy xz

yx yy yz

zx zy zz

x

y

z

a a a

a a a a

a a a

V

V V

V

Reflectance from a Surface with Loss

Slide 14

Complex Refractive Index

on n j

o ordinary refractive index oscillation

extinction coefficient decay

n

Reflectance from a lossy surface

n n j

2 2o

2 2o

1

1

nR

n

air

** Loss contributes to reflections

Page 8: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

8

Reflection, Transmission and Refraction at an Interface:Isotropic Case

Slide 15

TE Polarization

2 1 1 2 2 1TE TE

2 1 1 2 2 1 1 2

cos cos 2 cos

cos cos cos cosr t

TM Polarization

2 2 1 1 2 1TM TM

1 1 2 2 1 1 2 2

cos cos 2 cos

cos cos cos cosr t

Angles

inc ref 1

1 1 2 2sin sinn n

Snell’s Law

refractive index in region impedance in region i in i i

1 1,n

2 2,n

Maxwell’s Equations in Anisotropic Media

Slide 16

Maxwell’s curl equations in anisotropic media are:

0 r 0 r H j E E j H

These can also be written in a matrix form that makes the tensor aspect of  and more obvious.

0

0

0

0

0

0

0

0

z y x xx xy xz x

y yx yy yz yz x

z zx zy zz zy x

z y x xx xy xz

y yx yy yzz x

z zx zy zzy x

H E

H j E

H E

E

E j

E

x

y

z

H

H

H

Page 9: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

9

Types of Anisotropic Media

Slide 17

There are three basic types of anisotropic media:

iso

iso

iso

o

o

e

a

b

c

0 0

0 0 isotropic

0 0

0 0

0 0 uniaxial

0 0

0 0

0 0 biaxial

0 0

Note: terms only arise in the off‐diagonal positions when the tensor is rotated relative to the coordinate system.

(𝜀 & 𝜀 ) Vs. (𝜀 & 𝜎)

Slide 18

There are two ways to incorporate loss into Maxwell’s equations.

At very low frequencies and/or for time‐domain analysis, the (𝜀 & 𝜎) system is usually preferred.

0 r 0 rH J j D E j E j E

At high frequencies and in the frequency‐domain, (𝜀 & 𝜀 ) is usually preferred.

0 rH j D j E

The parameters are related through

r r0j

This will be used for FDTD

Page 10: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

10

Maxwell’s Equations in Doubly‐Diagonally Anisotropic Media

Slide 19

Maxwell’s equations for diagonally anisotropic media can be written as

0 0

0 00 0 0 0

0 0 0 0 0 0

0 0 0 0 0 0

z y z yx xx x x xx x

y yy y y yy yz x z x

z zz z z zz zy x y x

H E E H

H j E E j H

H E E H

0

0

0 0 0

0 0 0

0 0 0

0 0 0

0 0 0

0 0 0

Ez y x x x x

Ey y y yz x

Ez z z zy x

Hz y x x x

Hy y yz x

Hz z zy x

H j E

H j j E

H j E

E j

E j j

E j

x

y

z

H

H

H

This can be generalized even further by incorporating loss.

Scattering at a Doubly‐Anisotropic Interface

Slide 20

Reflection from a diagonally anisotropic material is

1 2TE

1 2

1 2TM

1 2

cos cos

cos cos

cos cos

cos cos

a br

a b

a br

a b

Refraction into a diagonally anisotropic materials is described by

1 2sin sinbc r r

0 0

0 0

0 0

a

b

c

Sacks, Zachary S., et al. "A perfectly matched anisotropic absorber for use as an absorbing boundary condition." IEEE Trans. Antennas and Propagation, Vol. 43, No. 12, pp. 1460-1463, 1995.

Page 11: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

11

Notes on a Single Interface

• It is a change in impedance that causes reflections• Snell’s Law quantifies the angle of transmission•Angle of transmission and reflection does not depend on polarization• The Fresnel equations quantify the amount of reflection and transmission•Amount of reflection and transmission depends on the polarization

Slide 21

Slide 22

The Uniaxial Perfectly Matched Layer (UPML)

S. Zachary, D. Kingsland, R. Lee, J. Lee, “A Perfectly Matched Anisotropic Absorber for Use as an Absorbing Boundary Condition,”  IEEE Trans. on Ant. and Prop., vol. 43, 

no. 12, pp 1460–1463, 1995.

Page 12: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

12

Boundary Condition Problem

Slide 23

If we model a wave hitting some device or object, it will scatter the applied wave into potentially many directions.  We do NOT want these scattered waves to reflect from the boundaries of the grid.  We also don’t want them to reenter from the other side of the grid (periodic boundaries).

?

?How can reflections from the boundary be eliminated?

x

y

No PAB in Two Dimensions

Slide 24

If we simulate a wave hitting some device or object, it will scatter the applied wave into potentially many directions.  Waves at different angles travel at different speeds through a boundary.  Therefore, the PAB condition can only be satisfied for one direction, not all directions.

fastest

slowest

x

y

Page 13: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

13

Simulation Without a PML

Slide 25

Simulation With a PML

Slide 26

Page 14: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

14

How Reflections are Prevented in the Lab

Slide 27

In the lab, anechoic foam is used to absorb outgoing waves.  

Absorbing Boundary Conditions

Slide 28

Introduce loss at the boundaries of the grid!

0

0

x

y

Absorbing Boundary

Page 15: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

15

Oops!!

Slide 29

But if loss is introduced, reflections are also introduced from the lossy regions!!

0

0

2 2

2 2

1

1

nR

n

x

y

Match the Impedance

Slide 30

Loss must be incorporated to absorb outgoing waves, but the impedance must also remain matched to the problem space to prevent reflections.

r r rj

introduce loss here

adjust this to maintain constant impedance

Page 16: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

16

More Trouble?

Slide 31

By examining the Fresnel equations, it is observed that reflections can only be eliminated from an interface at one frequency, one angle of incidence, and one polarization.

2 1 1 2 2TE 2 1

2 1 1 2 1

cos cos cos0

cos cos cosr

2 2 1 1 1TM 2 1

1 1 2 2 2

cos cos cos0

cos cos cosr

Anisotropy to the Rescue!!

Slide 32

It turns out reflections can be eliminated at all angles and for all polarizations if the absorbing material is made to be doubly‐diagonally anisotropic.

and

and

x

y

Page 17: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

17

Problem Setup for the UPML

Slide 33

1 21

0%

100%

0 0, Free Space

,

z

Designing Anisotropy for Zero Reflection (1 of 3)

Slide 34

The impedance of the PML must be perfectly matched to the impedance of the grid.

everywhere

One easy way to ensure impedance is perfectly matched is:

r r

0 0

0 0

0 0

a

b

c

For now, the elements along the diagonal are set to a, b, c.  

Next, rules for these will be determined.

Page 18: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

18

Designing Anisotropy for Zero Reflection (2 of 3)

Slide 35

The reflection coefficients reduce to

1 2TE

1 2

1 2TM

1 2

cos cos

cos cos

cos cos

cos cos

a b a br

a b a b

a b a br

a b a b

If  𝑏𝑐 1 is chosen, then the refraction equation reduces to

1 2 2 1 2sin sin sin bc

The amount of reflection is no longer a function of angle!! 

No refraction!

Designing Anisotropy for Zero Reflection (3 of 3)

Slide 36

TE

TM

0

0

a br

a b

a br

a b

Further, if 𝑎 𝑏 is chosen, the reflection equations reduce to

Recall the necessary conditions: 1 and bc a b

Reflection will always be zero regardless of frequency, angle of incidence, or polarization!!  

1b

c

Page 19: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

19

The PML Parameters (1 of 3)

Slide 37

1a b

c

So far, the tensors for the UPML are

r r

0 0

0 0

0 0

a

b

c

Thus, the PML in terms can be written in terms of just one parameter sz.

1

0 0

0 0

0 0

z

z z

z

s

S s

s

This is for a wave travelling in the +z direction incident on a z‐axis boundary.

This form of tensor is why we call this a uniaxial PML.

The PML Parameters (2 of 4)

Slide 38

Recall the complex permittivity 𝜀̃ is related to the conductivity 𝜎 and real‐valued permittivity 𝜀 through

r r0

j j

The PML parameters act like the complex relative permittivity 𝜀̃ so we already know how to adjust it to control loss.

r0

zsj

r PML fictitious relative permittivity

PML fictitious conductivity

For simplicity, set 𝜀 1.

0

1zsj

Many PML implementations use 𝜀 1 in order to better handle evanescent fields.

Page 20: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

20

The PML Parameters (3 of 4)

Slide 39

A UPML is potentially needed along all the borders.

1

1

1

0 0 0 0 0 0

0 0 0 0 0 0

0 0 0 0 0 0

x y z

x x y y z z

x y z

s s s

S s S s S s

s s s

These can be combined into a single tensor quantity.

0 0

0 0

0 0

y z

x

x zx y z

y

x y

z

s s

s

s sS S S S

s

s s

s

The PML Parameters (4 of 4)

Slide 40

The 3D PML can be visualized this way…

0 0

0 0

0 0

y z

x

x z

y

x y

z

s s

s

s sS

s

s s

s

1zs

1zs

1xs

1xs 1ys

1ys

x y

z

Page 21: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

21

Two‐Dimensional UPML

Slide 41

For 2D simulations in the x-y plane, sz = 1 and the UPML tensor reduces to

0 0

0 0

0 0

y

x

x

y

x y

s

s

sS

s

s s

x

y

1ys

1ys

1x ys s

Slide 42

Incorporating a UPML into Maxwell’s Equations

Page 22: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

22

Incorporating a UPML into Maxwell’s Equations

Slide 43

0 rE j H

H E j D

0 rD E

Before incorporating a PML, Maxwell’s equations in the frequency‐domain are

The PML  𝑆 can be incorporated independent of the actual materials on the grid as follows:

0 rE j H

H E j D

S

S

0 rD E

Normalize Maxwell’s Equations with UPML

Slide 44

Normalize the electric field quantities according to

Maxwell’s equations with the UPML and normalized fields are

r

0

00

E j S Hc

jH E S D

c

rD E

0

0 0

1E E E

0

0 0

1D D c D

Keeping  𝑆 separate from  𝜇and  𝜀 allows the UPML to be handled independently from the materials and devices being simulated.

Page 23: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

23

Matrix Form of Maxwell’s Equations

Slide 45

Maxwell’s equations can be written in matrix form as

x xx xy xz x

y yx yy yz y

z zx zy zz z

D E

D E

D E

1

1

0 1

0 0 01

0 0 0

0 0 0

0

0

0

z y x xx xy xz x y z x

y yx yy yz x y z yz x

z zx zy zz x y z zy x

z y x

yz x

y x

E s s s H

E j s s s Hc

E s s s H

H

H

H

1

10

0 1

0 0

0 0

0 0

xx xy xz x x y z x

yx yy yz y x y z y

z zx zy zz z x y z z

E s s s Dj

E s s s Dc

E s s s D

Assume Only Diagonal Tensors

Slide 46

To keep the FDTD algorithm simple, assume that [], [], and [] contain only diagonal terms.

x xx xy xz x

y yx yy yz y

z zx zy zz z

D E

D E

D E

1

1

0 1

0 0 01

0 0 0

0 0 0

0

0

0

z y x xx xy xz x y z x

y yx yy yz x y z yz x

z zx zy zz x y z zy x

z y x

yz x

y x

E s s s H

E j s s s Hc

E s s s H

H

H

H

1

10

0 1

0 0

0 0

0 0

xx xy xz x x y z x

yx yy yz y x y z y

z zx zy zz z x y z z

E s s s Dj

E s s s Dc

E s s s D

Page 24: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

24

Assume Only Diagonal Tensors

Slide 47

To keep the FDTD algorithm simple, assume that [], [], and [] contain only diagonal terms.

0 0

0 0

0 0

x xx x

y yy y

z zz z

D E

D E

D E

1

1

0 1

0 0 0 0 01

0 0 0 0 0

0 0 0 0 0

0

0

0

z y x xx x y z x

y yy x y z yz x

z zz x y z zy x

z y x

yz x

zy x

E s s s H

E j s s s Hc

E s s s H

H

H

H

1

10

0 1

0 0 0 0

0 0 0 0

0 0 0 0

xx x x y z x

yy y x y z y

zz z x y z z

E s s s Dj

E s s s Dc

E s s s D

Vector Expansion of Maxwell’s Equations

Slide 48

0

0

0

y y zz xxx

x

yyx z x zy

y

y x yx zzz

z

E s sEj H

y z c s

E E s sj H

z x c s

E s sEj H

x y c s

x xx x

y yy y

z zz z

D E

D E

D E

00

00

00

y y zzxx x x

x

x z x zyy y y

y

y x yxzz z z

z

H s sH jE D

y z c s

H H s sjE D

z x c s

H s sH jE D

x y c s

0

rE j s Hc

rD E

00

jH E s D

c

Page 25: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

25

Final Form of Maxwell’s Equations with UPML

Slide 49

1

0

0 0 0

1

0

0 0 0

0 0

1 1 1

1 1 1

1 1 1

y yzx zx

xx

y x zx zy

yy

yx

EEcj H

j j j y z

E Ecj H

j j j z x

jj j

1

0

0

y xzz

zz

E EcH

j x y

x xx x

y yy y

z zz z

D E

D E

D E

1

00 0 0 0

1

00 0 0 0

0 0

1 1 1

1 1 1

1 1

y yzx xxzx x

y yyx zx zy y

yx

HHj D c E

j j j y z

H Hj D c E

j j j z x

jj j

1

00 0

1 y xz zzz z

H HD c E

j x y

0

rE j s Hc

rD E

00

jH E s D

c

Slide 50

Convolutional Perfectly Matched Layer (CPML)

Page 26: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

26

The Uniaxial PML

Slide 51

0 rE k HS 0 rH k ES

Maxwell’s equations with uniaxial PML are:

0 0

0 0

0 0

y z

x

x z

y

x y

z

s s

s

s s

s

s s

S

s

Rearrange the Terms

Slide 52

0 r

1HS E k 0 r

1H k ES

The PML tensor can be brought to the left side of the equations and be associated with the curl operator.

The curl operator is now

1 1

1 1 1

1 1

1 1

1 1

1 1

0

0

0 0

0 0

0 0 0

0

0

0

x x

y z z y

y y

x z z x

z z

x y y x

z y

z x

y

z y x

z y x

z y x

s ss s s s

s s

s s s s

s ss s s

x

z y

z x

sy x

s s s

S s s s

s s s

Page 27: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

27

“Stretched” Coordinates

Slide 53

The new curl operator is

1 1

1 1 1

1 1

0

0

0

x x

y z z y

y y

x z z x

z z

x y y x

s ss s s s

s s

s s s s

s ss s s

z y

z x

y xs

S

The factors sx, sy, and sz are effectively “stretching” the coordinates, but they are “stretching” into a complex space.  Weird, huh?

Drop the Other Terms

Slide 54

Justification

0 x

y

s

s

s

1 x

z zs zss

1

y

y

x

s y

s

s

1 0 y

zzs z

s

s 1

z

x

x

s x

ss

1 z

y ys yss

1 1

1 1

1 11

0

0

00

z y

z x

y xx

s z s y

s z s x

s y s xs x

Drop the non‐stretching terms.

1 1z z

y

xs s s

s

z z Inside the z‐PML, sx = sy = 1.  This is valid everywhere except at the extreme corners of the grid 

where the PMLs overlap.

This also implies that the UPML and SC‐PML have nearly identical performance in terms of reflections, sensitivity to angle of incidence, polarization, etc.

Page 28: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

28

Maxwell’s Equations with a Stretched Coordinate PML (SC‐PML)

Slide 55

0 r

0 r

E k H

H k E

Maxwell’s equations before the PML is added are

0 r

0 r

s

s

E k H

H k E

r r xx xy xz xx xy xz

yx yy yz yx yy yz

zx zy zz zx zy zz

The SC‐PML is incorporated as follows.

1 1

1 1

1 1

0

0

0

z y

z x

y x

s z s y

s z x

s y s x

s s

Vector Expansion

Slide 56

0

0

0

0

0

1 1

1 1

1 1

1 1

1 1

1

yzxx x xy y xz z

y z

x zyx x yy y yz z

z x

y xzx x zy y zz z

x y

yzxx x xy y xz z

y z

x zyx x yy y yz z

z x

x

HHk E E E

s y s z

H Hk E E E

s z s x

H Hk E E E

s x s y

EEk H H H

s y s z

E Ek H H H

s z s x

s

0

1y xzx x zy y zz z

y

E Ek H H H

x s y

Fully Anisotropic Diagonally Anisotropic

0

0

0

0

0

0

1 1

1 1

1 1

1 1

1 1

1 1

yzxx x

y z

x zyy y

z x

y xzz z

x y

yzxx x

y z

x zyy y

z x

y xzz z

x y

HHk E

s y s z

H Hk E

s z s x

H Hk E

s x s y

EEk H

s y s z

E Ek H

s z s x

E Ek H

s x s y

Page 29: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

29

Convolutional PML (CPML)

Slide 57

A convolutional PML is a SC‐PML that is solved efficiently in the time‐domain.

0

0

0

0

0

0

1 1

1 1

1 1

1 1

1 1

1 1

yzxx x

y z

x zyy y

z x

y xzz z

x y

yzxx x

y z

x zyy y

z x

y xzz z

x y

HHk E

s y s z

H Hk E

s z s x

H Hk E

s x s y

EEk H

s y s z

E Ek H

s z s x

E Ek H

s x s y

We have a multiplication operation in the frequency‐domain.  

This becomes convolution in the time‐domain.

Why a UPML for This Course?

• A CPML (or SC‐PML) is currently the state‐of‐the‐art in FDTD.• A UPML offers benefits to frequency‐domain models that are useful for beginners.  • The models can be formulated and implemented without considering the PML.  The PML is incorporated simply by adjusting the values of permittivity and permeability at the edges of the grid.

• Implementing a UPML in this course offers better continuity going into the following course, Computational Electromagnetics.

Slide 58

Page 30: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

30

Slide 59

Calculating the PML Parameters

The Perfectly Matched Layer (PML)

Slide 60

The perfectly matched layer (PML) is an absorbing boundary condition (ABC) where the impedance is perfectly matched to the problem space.  Reflections entering the lossy regions are prevented because impedance is matched.  Reflections from the grid boundary are prevented because the outgoing waves are absorbed.

PML

PML

PMLP

ML

ProblemSpace

0y

0x

0x y z

0y

0x

Page 31: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

31

Typical Grid Schemes

Slide 61

20cells

20cells

Periodic Boundary

Perio

dic B

oundary

PML

PML

20 cells20 cells

PML

PML

PML

PML

spacerregion

Periodic Devices Finite Devices

Justification for the Spacer Regions

Slide 62

The refractive index is high inside the PML so evanescent waves can become propagating waves, giving an unintended escape path for power.

PML

PML

PML

PML

Page 32: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

32

Calculating the PML Loss Terms

Slide 63

For best performance, the loss terms should increase gradually into the PMLs.

3

0

3

0

3

0

2

2

2

xx

yy

zz

xx

t L

yy

t L

zz

t L

0

0

0

1

1

1

xx

yy

zz

xs x

j

ys y

j

zs z

j

? length of the PML in the ? directionL

Visualizing the PML Loss Terms – 2D

Slide 64

For best performance, the loss terms should increase gradually into the PMLs.

x x y y x

y

Page 33: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

33

Note About x/Lx,  y/Ly, and  z/Lz

Slide 65

and and x y z

x y z

L L L

The following ratios provide a single quantity that goes from 0 to 1 as you move through a PML region.

, , position within PML

, , size of PMLx y z

x y z

L L L

The same ratio can be calculated using integer indices from the grid.

nx = 1, 2, ... , NXLO nx nx or

nx = 1, 2, ... , NXHI NXLO NXHI

ny = 1, 2, ... , NYLO ny ny or

ny = 1, 2, ... , NYHI NYLO NYHI

nz = 1, 2, ... , NZLO nz nz or

nz = 1NZLO NZHI

x

y

z

x

L

y

L

z

L

, 2, ... , NZHI

0 1x

x

L

0 1x

x

L

Visualizing the Calculation of x in 2D

Slide 66

1

NXLO

Nx

x(x) = 0

% ADD XLO PMLfor nx = 1 : NXLO

…ox(NXLO-nx+1,:) = ...

end

% ADD XHI PMLfor nx = 1 : NXHI

…ox(Nx-NXHI+nx,:) = ...

end

x(x

) =

m

ax(x

/Lx)

3 x (x) =

m

ax (x/Lx ) 3

Page 34: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

34

Visualizing the Calculation of y in 2D

Slide 67

1

NYLO

Ny

Ny – NYHI + 1

% ADD YLO PMLfor ny = 1 : NYLO

…oy(:,NYLO-ny+1) = ...

end

% ADD YHI PMLfor ny = 1 : NYHI

…oy(:,Ny-NYHI+ny) = …

end

y(y) = 0

y(y) = max(y/Ly)3

y(y) = max(y/Ly)3

Procedure for Calculating x and y on a 2D Grid

Slide 68

1. Initialize x and y to all zeros.

, , 0x yx y x y

2. Fill in x‐axis PML regions using two for loops.

3. Fill in y‐axis PML regions using two for loops.

NXLO NXHI

NYLO

NYHI

Page 35: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

35

Slide 69

Final Notes About PMLs

PMLs Are Not Perfect

Slide 70

PML absorbing boundary conditions are not perfect absorbers.  They still reflect waves!

Reflection from PML

Page 36: Lecture -- The Perfectly Matched Layer - EMPossible

4/24/2021

36

The PML is Not a Boundary Condition

Slide 71

A numerical boundary condition is the rule you follow when a finite‐difference equation references a field from outside the grid.

The PML does not address this issue.

It is simply a way of incorporating loss while preventing reflections so as to absorb outgoing waves.

Sometimes it is called an absorbing boundary condition, but this is still a 

misleading title because the PML is not a boundary condition.

UPML Vs. SC‐PML

Slide 72

Uniaxial PML Stretched‐Coordinate PML

Benefits

• Has a physical interpretation• Models can be formulated and 

implemented without considering the PML in the frequency‐domain

Benefits

• Less computationally intensive in time‐domain

• More efficient implementation in the time‐domain

• Matrices are better conditioned.

Drawbacks

• Can be more computationally intensive to implement in time‐domain

• Resulting matrices are less well conditioned in the frequeny‐domain

Drawbacks

• Must be accounted for in the formulation and implementation of the numerical method.

• Not intuitive to understand