\documentclass[tikz,border=5pt]{standalone}
\usepackage{amsmath,amssymb}
\usepackage{xcolor}
\usepackage{tikz}
\usetikzlibrary{shapes.geometric, arrows, fit}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\begin{document}
\begin{tikzpicture}[node distance=7ex,thick,scale=0.8, every node/.style={scale=0.8}]
\tikzstyle{startstop} = [rectangle, rounded corners=1.2ex, minimum width=10ex, minimum height=2ex, text centered, draw=black, fill=red!30]
\tikzstyle{io} = [trapezium, trapezium left angle=70, trapezium right angle=110, minimum width=10ex, minimum height=2ex, text centered, draw=black, fill=blue!30]
\tikzstyle{process} = [rectangle, minimum width=10ex, minimum height=2ex, text centered, draw=black, fill=orange!30]
\tikzstyle{decision} = [diamond, minimum width=10ex, minimum height=2ex, aspect=2, text centered, draw=black, fill=green!30, inner sep=1pt]
\tikzstyle{arrow} = [thick,->,>=stealth]
\node (start) [startstop] {Start};
\node (pre) [process, below of=start, text width=20ex] {FDTD preprosses and fields initializations};
\draw [arrow] (start) -- (pre);
\node (init0) [process, below of=pre,yshift=-1ex] {$i=0$};
\draw [arrow] (pre) -- (init0);
\node (init1) [process, below of=init0, text width=22ex] {initialize populations\\ $n_{0i}=1,n_{1i}=0,n_{2i}=0$};
\draw [arrow] (init0) -- (init1);
\node (init) [process, text width=22ex, below of=init1,yshift=-1.5ex] {initialize populations\\ $\mathbf{p}_i=0,\mathbf{\dot{p}}_i=0$};
\draw [arrow] (init1) -- (init);
\node (initd) [decision, below of=init,yshift=-6ex, inner sep=0pt, text width=11ex] {{\small $i\overset{?}{<}$ number of emitters}};
\draw [arrow] (init) -- (initd);
\node (init2) [process, above of=initd, xshift=-15ex, yshift=-1ex] {$i=i+1$};
\draw [arrow] (initd) -| node[below,xshift=2ex]{yes} (init2);
\draw [arrow] (init2) |- (init1);
\tikzset{blue dotted/.style={draw=blue!50!white, line width=1pt, dashed, inner sep=6ex, rectangle, rounded corners}}
\node (first dotted box) [blue dotted, fit = (init0) (init1) (init) (initd) (init2)] {};
\node at (first dotted box.west) [above, inner sep=1ex, rotate=90] {{emitters initialization}};
\node (pro0) [process, below of=initd, yshift=-6ex] {$t=0$};
\draw [arrow] (initd) -- node[right,yshift=1.2ex]{no} (pro0);
\node (pro1) [process, below of=pro0, yshift=-1.5ex, text width=20ex, inner xsep=1pt] {FDTD updates for EM fields, metals, PMLs, sources, ...};
\draw [arrow] (pro0) -- (pro1);
\node (pro2) [blue dotted, draw=blue!90!white, below of=pro1, yshift=-6ex, text width=22ex, inner sep=5pt] {{\textbf{emitters state-updating} \\(depicted in Fig.~\ref{fig:Flow2})}};
\draw [arrow] (pro1) -- (pro2);
\node (mtl) [decision, below of=pro2, yshift=-8ex, inner sep=1pt] {{\small $t\overset{?}{\leqslant}$ final time step}};
\draw [arrow] (pro2) -- (mtl);
\node (pro3) [process, above of=mtl, xshift=-15ex, yshift=-1ex] {$t=t+\delta t$};
\draw [arrow] (mtl) -| node[below,xshift=2ex]{yes} (pro3);
\draw [arrow] (pro3) |- (pro1);
\node (second dotted box) [blue dotted, fit = (pro0) (pro1) (pro2) (pro3) (mtl)] {};
\node at (second dotted box.west) [above, inner sep=1ex, rotate=90] {{FDTD time-marching loop}};
\node (post) [process, below of=mtl, yshift =-5ex, text width=20ex] {FDTD postprossing};
\draw [arrow] (mtl) -- node[right,yshift=1.0ex]{no} (post);
\node (out1) [io, below of=post, yshift=.5ex] {Output};
\draw [arrow] (post) -- (out1);
\node (stop) [startstop, below of=out1, yshift=.5ex] {Stop};
\draw [arrow] (out1) -- (stop);
\end{tikzpicture}
\end{document}