SALMON TUTORIAL, TSUKUBA, 2018

FDTD simulation
Exercise-4-4

Takashi Takeuchi
Center for Computational Sciences, University of Tsukuba
Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/

1

FDTD: Finite-Difference Finite-Time domain
Whatis FDTD
• Whatis FDTD??????
• The FDTD is a real-time and real-space method to solveclassical(macroscopic) electromagnetic problems.
• Whatcanwewedodo
byby
FDTD??????
What
canFDTD• can simulate optical and electrical devices
such as plasmonics, wave guide, antenna, electric circit, and so on.

Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/SALMON TUTORIAL, TSUKUBA, 20182

Demonstration of FDTD
• E and H in the Maxwell’s equations are simulated based on the spatial grids.
1 𝜕𝐃 𝜖 𝜕𝐄
4𝜋𝜎
4𝜋
=
=𝛻×𝐇−
𝐄−𝐉𝑐 𝜕𝑡 𝑐 𝜕𝑡𝑐𝑐
1 𝜕𝐁 𝜇 𝜕𝐇== −𝛻 × 𝐄𝑐 𝜕𝑡 𝑐 𝜕𝑡

Shape: arbitrary
Medium:① Constant 𝜖, 𝜇, and 𝜎② Drude model③ Perfect Electric Conductor(PEC)

Computational domain

Incident lightScatter

Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/
SALMON TUTORIAL, TSUKUBA, 20183

Input keywords in fdtd.inp• &units→ ‘A_eV_fs’ is used now.
(‘au’ and ‘A_eV_fs’ are available.)• &calculation• &control• &system→ In v.1.2.0, only iperiodic = 0 is allowed.

• &emfield → A y-polarized pulse(Ey component) is employed.
• &maxwell

Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/
SALMON TUTORIAL, TSUKUBA, 2018

4

Input keywords in fdtd.inp• &units• &calculation

theory = ‘Maxwell’→ Type of theory in the simulation.
→ Default is ‘TDDFT’.

• &control• &system• &emfield• &maxwell

directory = ‘./result/’→ Directory name for out put.
→ Default is ‘./’.

Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/
SALMON TUTORIAL, TSUKUBA, 20185

Input keywords in fdtd.inp
Computational domain• &unitsy• &calculation• &control

xIncident lightScatterz• &system• &emfield• &maxwell

al_em = 16.25d0, 16.25d0, 16.25d0→ Computational domain length.
dl_em = 0.25d0, 0.25d0, 0.25d0→ Spacing of real-space grids.
nt_em = 300→ Number of total time steps for real-time propagation.
! dt_em = **→ Time step (not necessary here).
Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/SALMON TUTORIAL, TSUKUBA, 2018

6

Input keywords in fdtd.inp
Computational domain• &units← source to generate a pulsey• &calculation• &controlx

Incident lightScatterz• &system• &emfield• &maxwell

wave_input = 'source‘→ Type how to generate pulse.
→ In v.1.2.0, this is ‘source’ only.
source_loc1 = -5.0d0, 0.0d0, 0.0d0→ Location of source 1.
ek_dir1 = 1.0d0, 0.0d0, 0.0d0→ Direction that the pulse propagates.
(x-direction, y-direction, z-direction)
Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/
SALMON TUTORIAL, TSUKUBA, 20187

Input keywords in fdtd.inp
Computational domain• &unitsy• &calculation• &control

xIncident light

Scatterz• &system• &emfield• &maxwell

imedia_num = 1→Number of media.
shape_file = 'shape.cube‘→Name of shape-fileepsilon(1) = 2.0d0→Relative permittivity.
→ rmu and sigma are permeability and conductivity.
→ type_media = ‘pec’ or ‘drude’.
→If ‘drude’, set omega_p_d and gamma_d.
Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/SALMON TUTORIAL, TSUKUBA, 2018

8

SALMON utilities→usage: ./make_shape.py

https://salmon-tddft.jp/utilities.html

Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/SALMON TUTORIAL, TSUKUBA, 20189

FDTD simulation by fdtd.inp
Computational domain• &unitsy• &calculation• &controlx

Incident lightScatterz• &system• &emfield• &maxwell

iobs_num_em = 1→ Number of observation points.
iobs_samp_em = 5→ Sampling time step.
obs_loc_em(1,:) = 0.0d0, 0.0d0, 0.0d0→ Coordinate of the observation point.
Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/
SALMON TUTORIAL, TSUKUBA, 201810

Check of calculation by fdtd.inp
Computational domain

PML(Absorbing boundary condition)yx

Incident lightScatterz• out_fdtd.log→ Standard output file.
**************************
From CFL condition, dt_em is determined byin the unit system, A_eV_fs.
**************************

4.766437173888290E-005**************************PML has been set for x-direction: -8.00000E+00 to -6.00000E+00.
PML has been set for x-direction: 6.00000E+00 to 8.00000E+00.
PML has been set for y-direction: -8.00000E+00 to -6.00000E+00.
PML has been set for y-direction: 6.00000E+00 to 8.00000E+00.
PML has been set for z-direction: -8.00000E+00 to -6.00000E+00.
PML has been set for z-direction: 6.00000E+00 to 8.00000E+00.
**************************
Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/
SALMON TUTORIAL, TSUKUBA, 201811

SALMON utilities→usage: ./make_figani.py

https://salmon-tddft.jp/utilities.html

Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/
SALMON TUTORIAL, TSUKUBA, 201812

Result: Temporal profile of E by fdtd.inp./make_figani.py

Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/
SALMON TUTORIAL, TSUKUBA, 201813

Result: Temporal profile of H by fdtd.inp./make_figani.py

Scalable Ab-initio Light-Matter simulator for Optics and Nanoscience
http://salmon-tddft.jp/
SALMON TUTORIAL, TSUKUBA, 201814