\hrulefill

\textbf{Function: \textsf{setGeomSim.m}}, see Sec.~\ref{sec:guide:setGeomSim} (geometry and simulation):

\begin{compactitem}
\item Grid (CD and ROI) (Sec.~\ref{sec:guide:setGrid}) (\textsf{setGrid.m} $\mapsto$ \textsf{seti.grid}, \textsf{seti.gridROI}).
\item Experimental set-up (Sec.~\ref{sec:guide:expSetup}):
 \begin{compactitem}
 \item Transmitters' positions (\textsf{setIncPnts.m} $\mapsto$ \textsf{seti.incPnts}).
 \item Receivers' positions (\textsf{setMeasPnts.m} $\mapsto$ \textsf{seti.measPnts}).
 \item Incident field (\textsf{setIncField.m} $\mapsto$ \textsf{seti.incField}).
 \item Measurement kernel (\textsf{setMeasKer.m} $\mapsto$ \textsf{seti.measKer}).
 \end{compactitem}
 \item Contrast (Sec.~\ref{sec:guide:contrast}) ($\mapsto$ \textsf{seti.qROIexact}).
\end{compactitem}

\hrulefill

%% ----- minipage: start -----

\begin{minipage}[t]{\dimexpr.24\textwidth-\tabcolsep-.5pt}
% -- Column 1 --
\centerline{\emph{Auxiliary routines}}
\vspace*{-0.2cm}

\hrulefill

\ \\ \\
\vspace*{-0.2cm}

\hrulefill

\bigskip
\bigskip
\bigskip

\textsf{setGeomSim.m}\\
(see above)

\bigskip

\textsf{forward.m}:

\begin{enumerate}[topsep=0mm, itemsep=0mm, parsep=0mm, leftmargin=3mm, labelsep=0.5mm]
 \item \textsf{init.m}.
 \item \textsf{setGeomSim.m}.
 \item \textsf{forward.m}, Sec.~\ref{sec:guide:forward}: \\ $\mapsto \textsf{FFqMeas} = \F(q)$.\\
 (Underlying: \textsf{mimo.m}.)
\end{enumerate}

\vspace{2.0cm}
\vspace*{-0.2cm}

\hrulefill

\bigskip

\textsf{forward.m}, \textsf{derivative.m}:

\begin{enumerate}[topsep=0mm, itemsep=0mm, parsep=0mm, leftmargin=3mm, labelsep=0.5mm]
 \item \textsf{init.m}.
 \item \textsf{setGeomSim.m}.
 \item \textsf{forward.m}, Sec.~\ref{sec:guide:forward}: \\ $\mapsto \textsf{FFqMeas} = \F(q)$\\ 
 or\\
 \textsf{derivative.m}, Sec.~\ref{sec:guide:derivative}: \\ $\mapsto$ \textsf{JA}, \textsf{JB} to compute $\F'(q)[h] = \textsf{JA*}h\textsf{*JB}$.\\
 (Underlying: \textsf{mimo.m}).
\end{enumerate}

\end{minipage}
\hfill\begingroup\color{gray}\vrule width 1pt\endgroup\hfill
\begin{minipage}[t]{\dimexpr.56\textwidth-\tabcolsep-.5pt}
% -- Column 2 --

\centerline{\emph{Main program}}
\vspace*{-0.2cm}

\hrulefill

\centerline{\textbf{\textsf{init.m}}}

\centering (Initialization, see Sec.~\ref{sec:guidelines})

\centering $\downarrow$
\vspace*{-0.2cm}

\hrulefill

\centering \textbf{\textsf{setData.m}}

\centering (Sec.~\ref{sec:guide:addNoise} and~\ref{sec:guide:matchIncField})

\medskip
\centering $\swarrow$ \hspace*{3cm} $\searrow$
\medskip

\begin{minipage}[t]{\dimexpr.5\textwidth-\tabcolsep-.5pt}
\centering \emph{Simulated data with noise} \\ \ 
\smallskip

\begin{enumerate}[topsep=0mm, itemsep=0mm, parsep=0mm, leftmargin=3mm, labelsep=0.5mm]
 \item \textsf{setGeomSim.m}, Sec.~\ref{sec:guide:setGeomSim}: \\ $\mapsto$~\textsf{seti.incField},\\ $\mapsto$~\textsf{seti.qROIexact}.
 \item \textsf{forward.m}, Sec.~\ref{sec:guide:forward}: \\ $\mapsto$~\textsf{seti.FmeasExact}.
 \item \textsf{addNoise.m}, Sec.~\ref{sec:guide:addNoise}: \\ $\mapsto$ \textsf{seti.FmeasDelta}.
\end{enumerate}
\end{minipage}
%
\hfill\begingroup\color{gray}\vrule width 0.5pt\endgroup\hfill
%
\begin{minipage}[t]{\dimexpr.5\textwidth-\tabcolsep-.5pt}
\centering \emph{Real-world data (Fresnel)}\\ (\textsf{loadData.m}, Sec.~\ref{sec:guide:matchIncField})
\smallskip

\begin{enumerate}[topsep=0mm, itemsep=0mm, parsep=0mm, leftmargin=3mm, labelsep=0.5mm]
 \item \textsf{readRAWData.m}, Sec.~\ref{sec:guide:workingFresnel}: \\ 
 (via \textsf{uTotRX}, \textsf{uIncRX}) \\ $\mapsto$~\textsf{seti.FmeasDelta}.
 \item \textsf{setGeomSim.m}.
 \item \textsf{matchIncField.m}, Sec.~\ref{sec:guide:matchIncField}:\\ 
 (via \textsf{uIncROI}) \\ $\mapsto$ \textsf{seti.incField}.
\end{enumerate}
\end{minipage}

\bigskip

\centering $\mapsto$ \textsf{seti.FmeasDelta}

\centering (data---simulated data with noise or real-world data)

\centering $\downarrow$
\vspace*{-0.2cm}

\hrulefill

\begin{center}
 
\textbf{\textsf{setRecon.m}}\\

(Sets required fields in \textsf{seti}, Sec.~\ref{sec:guide:recon}.)

$\mapsto$~\textsf{seti.alpha}, \textsf{seti.beta}, \textsf{seti.physBounds}.

\centering $\downarrow$

\textbf{\textsf{recon.m}}

(Variational reconstruction, Sec.~\ref{sec:guide:recon}.)

\addtolength{\fboxsep}{-1pt} % instead of setlength because can be corrected later
\fbox{
\addtolength{\tabcolsep}{-5pt}
\begin{tabular}[t]{p{2.6cm} p{2.1cm} p{1.9cm}}
\fbox{Inner iteration} & by \textsf{pda.m} & $\mapsto \textsf{h}$\\
\quad \quad \quad $\downarrow$ $\uparrow$ & &\\
\fbox{Outer iteration} & by \textsf{minPda.m} & $\mapsto q := q + h$\\
 & \multicolumn{2}{l}{(with $q = \textsf{seti.qROIcomp}$ and $h = \textsf{h}$).}
\end{tabular}
\addtolength{\tabcolsep}{+5pt}
}
\addtolength{\fboxsep}{+1pt} % instead of setlength because can be corrected later

\medskip

$\mapsto$ \textsf{seti.qROIcomp}\\
(Reconstructed contrast as a vector.)
\end{center}

\end{minipage}
\hfill\begingroup\color{gray}\vrule width 1pt\endgroup\hfill
\begin{minipage}[t]{\dimexpr.20\textwidth-\tabcolsep-.5pt}
% -- Column 3 --

\centerline{\emph{Code}}
\vspace*{-0.2cm}

\hrulefill

\ \\
\textsf{init;}
\ \\
\vspace*{-0.2cm}

\hrulefill

\ \\
\textsf{seti = struct;}

\textsf{seti = setData(seti);}

\vspace{5.75cm}

\hrulefill

\ \\
\textsf{seti = setRecon(seti);}

\textsf{seti = recon(seti);}

\end{minipage}

\hrulefill

%% ----- minipage: end -----

