\section{Implemented model functions}
\label{sec:imple}
This is an overview of all the model functions that are  implemented in \textit{PyCorrFit}. To each model a unique model ID is assigned. Most of the following information is also accessible from within \textit{PyCorrFit} using the \textit{Page info} tool.

\subsection{Confocal FCS}
\label{sec:imple.confo}

% 2D diffusion
%\noindent \begin{tabular}{lp{.7\textwidth}}
%Name & \textbf{2D (Gauß)} \\ 
%ID & \textbf{6001} \\ 
%Descr. &  Two-dimensional diffusion with a Gaussian laser profile\cite{Aragon1976, Qian1991, Rigler1993}. \\ 
%\end{tabular}
%\begin{align}
%G(\tau) = A_0 + \frac{1}{N} \frac{1}{(1+\tau/\tau_\mathrm{diff})}
%\end{align} 
%\begin{center}
%\begin{tabular}{ll}
%$A_0$ & Offset \\ 
%$N$ & Effective number of particles in confocal area \\ 
%$\tau_\mathrm{diff}$ &   Characteristic residence time in confocal area \\
%\end{tabular} \\
%\end{center}
%\vspace{2em}




% 3D diffusion
%\noindent \begin{tabular}{lp{.7\textwidth}}
%Name & \textbf{3D (Gauß)} \\ 
%ID & \textbf{6012} \\ 
%Descr. &  Three-dimensional free diffusion with a Gaussian laser profile (eliptical)\cite{Aragon1976, Qian1991, Rigler1993}. \\ 
%\end{tabular}
%\begin{align}
%G(\tau) = A_0 + \frac{1}{N} \frac{1}{(1+\tau/\tau_\mathrm{diff})} \frac{1}{\sqrt{1+\tau/(\mathit{SP}^2 \tau_\mathrm{diff})}}
%\end{align} 
%\begin{center}
%\begin{tabular}{ll}
%$A_0$ & Offset \\ 
%$N$ & Effective number of particles in confocal volume \\ 
%$\tau_\mathrm{diff}$ &  Characteristic residence time in confocal volume \\ 
%$\mathit{SP}$ & Structural parameter, describes elongation of the confocal volume \\
%\end{tabular}
%\end{center}
%\vspace{2em}


% 3D diffusion + triplet
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{Confocal (Gaussian) T+3D} \\ 
ID & \textbf{6011} \\ 
Descr. &  Three-dimensional free diffusion with a Gaussian laser profile (eliptical), including a triplet component\cite{Widengren1994, Widengren1995, Haupts1998}. \\ 
\end{tabular}
\begin{align}
G(\tau) = A_0 + \frac{1}{n} \frac{1}{(1+\tau/\tau_\mathrm{diff})} \frac{1}{\sqrt{1+\tau/(\mathit{SP}^2 \tau_\mathrm{ diff})}} \left(1 + \frac{T e^{-\tau/\tau_\mathrm{trip}}}{1-T}  \right)
\end{align} 
\begin{center}
\begin{tabular}{ll}
$A_0$ & Offset \\ 
$n$ & Effective number of particles in confocal volume \\ 
$\tau_\mathrm{diff}$ &  Characteristic residence time in confocal volume \\ 
$\mathit{SP}$ & Structural parameter, describes elongation of the confocal volume \\
$T$ &  Fraction of particles in triplet (non-fluorescent) state\\ 
$\tau_\mathrm{trip}$ &  Characteristic residence time in triplet \\
\end{tabular}
\end{center}
\vspace{2em}



% 3D+3D diffusion + triplett
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{Confocal (Gaussian) T+3D+3D} \\ 
ID & \textbf{6030} \\ 
Descr. &  Two-component three-dimensional free diffusion with a Gaussian laser profile, including a triplet component\cite{Elson1974, Aragon1976, Palmer1987}. \\ 
\end{tabular}
\begin{align}
G(\tau) &= A_0 + \frac{1}{n (F + \alpha (1-F))²}  \left(1 + \frac{T e^{-\tau/\tau_\mathrm{trip}}}{1-T}  \right)  \times \\
\notag &\times  \left[ \frac{F}{(1+\tau/\tau_1)}  \frac{1}{\sqrt{1+\tau/(\mathit{SP}^2 \tau_1)}} + \alpha^2 \frac{1-F}{ (1+\tau/\tau_2) }  \frac{1}{\sqrt{1+\tau/(\mathit{SP}^2 \tau_2)}} \right]
\end{align} 
\begin{center}
\begin{tabular}{ll}
$A_0$ & Offset \\ 
$n$ & Effective number of particles in confocal volume ($n = n_1+n_2$) \\ 
$\tau_1$ &  Diffusion time of particle species 1 \\ 
$\tau_2$ &  Diffusion time of particle species 2 \\ 
$F$ & Fraction of molecules of species 1 ($n_1 = F n$) \\
$\alpha$ & Relative molecular brightness of particles 1 and 2 ($ \alpha = q_2/q_1$) \\
$\mathit{SP}$ & Structural parameter, describes elongation of the confocal volume \\
$T$ &  Fraction of particles in triplet (non-fluorescent) state\\ 
$\tau_\mathrm{trip}$ &  Characteristic residence time in triplet state \\ 
\end{tabular}
\end{center}
\vspace{2em}



% 2D diffusion + triplett
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{Confocal (Gaussian) T+2D} \\ 
ID & \textbf{6002} \\ 
Descr. &  Two-dimensional diffusion with a Gaussian laser profile, including a triplet component\cite{Aragon1976, Qian1991, Rigler1993,Widengren1994, Widengren1995, Haupts1998}. \\ 
\end{tabular}
\begin{align}
G(\tau) = A_0 + \frac{1}{n} \frac{1}{(1+\tau/\tau_\mathrm{diff})}  \left(1 + \frac{T e^{-\tau/\tau_\mathrm{trip}}}{1-T}  \right)
\end{align} 
\begin{center}
\begin{tabular}{ll}
$A_0$ & Offset \\ 
$n$ & Effective number of particles in confocal area \\ 
$\tau_\mathrm{diff}$ &  Characteristic residence time in confocal area \\ 
$T$ &  Fraction of particles in triplet (non-fluorescent) state\\ 
$\tau_\mathrm{trip}$ &  Characteristic residence time in triplet state \\ 
\end{tabular}
\end{center}
\vspace{2em}



% 2D+2D diffusion + triplett
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{Confocal (Gaussian) T+2D+2D} \\ 
ID & \textbf{6031} \\ 
Descr. &  Two-component, two-dimensional diffusion with a Gaussian laser profile, including a triplet component\cite{Elson1974, Aragon1976, Palmer1987}. \\ 
\end{tabular}
\begin{align}
G(\tau) = A_0 + \frac{1}{n (F + \alpha (1-F))²} \left[ \frac{F}{1+\tau/\tau_1} + \alpha^2 \frac{1-F}{ 1+\tau/\tau_2 } \right] \left(1 + \frac{T e^{-\tau/\tau_\mathrm{trip}}}{1-T}  \right) 
\end{align} 
\begin{center}
\begin{tabular}{ll}
$A_0$ & Offset \\ 
$n$ & Effective number of particles in confocal area ($n = n_1+n_2$) \\ 
$\tau_1$ &  Diffusion time of particle species 1 \\ 
$\tau_2$ &  Diffusion time of particle species 2 \\ 
$F$ & Fraction of molecules of species 1 ($n_1 = F n$) \\
$\alpha$ & Relative molecular brightness of particles 1 and 2 ($ \alpha = q_2/q_1$) \\
$T$ &  Fraction of particles in triplet (non-fluorescent) state\\ 
$\tau_\mathrm{trip}$ &  Characteristic residence time in triplet state \\ 
\end{tabular}
\end{center}
\vspace{2em}



% 3D+2D diffusion + triplett
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{Confocal (Gaussian) T+3D+2D} \\ 
ID & \textbf{6032} \\ 
Descr. &  Two-component, two- and three-dimensional diffusion with a Gaussian laser profile, including a triplet component\cite{Elson1974, Aragon1976, Palmer1987}. \\ 
\end{tabular}
\begin{align}
G(\tau) = A_0 + \frac{1}{n (1 - F + \alpha F)²} \left[ \frac{1-F}{1+\tau/\tau_\mathrm{2D}} + \frac{ \alpha^2 F}{ (1+\tau/\tau_\mathrm{3D}) } \frac{1}{\sqrt{1+\tau/(\mathit{SP}^2 \tau_\mathrm{3D})}} \right] \left(1 + \frac{T e^{-\tau/\tau_\mathrm{trip}}}{1-T}  \right) 
\end{align} 
\begin{center}
\begin{tabular}{ll}
$A_0$ & Offset \\ 
$n$ & Effective number of particles in confocal volume ($n = n_\mathrm{2D}+n_\mathrm{3D}$) \\ 
$\tau_\mathrm{2D}$ &  Diffusion time of surface bound particles \\ 
$\tau_\mathrm{3D}$ &  Diffusion time of freely diffusing particles \\ 
$F$ & Fraction of molecules of the freely diffusing species ($n_\mathrm{3D} = F n$) \\
$\alpha$ & Relative molecular brightness of particle species ($ \alpha = q_\mathrm{3D}/q_\mathrm{2D}$) \\
$\mathit{SP}$ & Structural parameter, describes elongation of the confocal volume \\
$T$ &  Fraction of particles in triplet (non-fluorescent) state\\ 
$\tau_\mathrm{trip}$ &  Characteristic residence time in triplet state \\ 
\end{tabular}
\end{center}
\vspace{2em}

\subsection{TIR-FCS}
\label{sec:imple.tirfc}
The model functions make use of the Faddeeva function (complex error function)\footnote{In user-defined model functions (\hyref{Section}{sec:hacke.extmod}), the Faddeeva function is accessible through \texttt{wofz()}. For convenience, the function \texttt{wixi()} can be used which only takes $\xi$ as an argument and the imaginary $i$ can be omitted.}:
\begin{align}
w\!(i\xi) &= e^{\xi^2} \mathrm{erfc}(\xi) \\
\notag &= e^{\xi^2} \cdot  \frac{2}{\sqrt{\pi}} \int_\xi^\infty \mathrm{e}^{-\alpha^2} \mathrm{d\alpha} \label{eq:faddeeva}
\end{align} 
The lateral detection area has the same shape as in confocal FCS. Thus, correlation functions for two-dimensional diffusion of the confocal case apply and are not mentioned here.

\subsubsection{TIR-FCS with Gaussian-shaped lateral detection volume}


% 3D diffusion (Gauß/exp)
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{TIR (Gaussian/Exp.) T+3D} \\ 
ID & \textbf{6014} \\ 
Descr. &  Three-dimensional free diffusion with a Gaussian lateral detection profile and an exponentially decaying profile in axial direction, including a triplet component\cite{Starr2001, Hassler2005, Ohsugi2006}. \\ 
\end{tabular}
\begin{align}
G(\tau) = \frac{1}{C}  \frac{ \kappa^2}{ \pi (R_0^2 +4D\tau)} \left(1 + \frac{T e^{-\tau/\tau_\mathrm{trip}}}{1-T}  \right)
 \left( \sqrt{\frac{D \tau}{\pi}} + \frac{1 - 2 D \tau \kappa^2}{2 \kappa}  w\!\left(i \sqrt{D \tau} \kappa\right) \right)
\end{align} 
\begin{center}
\begin{tabular}{ll}
$C$ & Particle concentration in confocal volume \\ 
$\kappa$ &  Evanescent decay constant ($\kappa = 1/d_\mathrm{eva}$)\\ 
$R_0$ & Lateral extent of the detection volume \\
$D$ & Diffusion coefficient  \\
$T$ &  Fraction of particles in triplet (non-fluorescent) state\\ 
$\tau_\mathrm{trip}$ &  Characteristic residence time in triplet state \\ 
\end{tabular}
\end{center}
\vspace{2em}


% 3D+3D+T diffusion (Gauß/exp)
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{TIR (Gaussian/Exp.) T+3D+3D} \\ 
ID & \textbf{6034} \\ 
Descr. &  Two-component three-dimensional diffusion with a Gaussian lateral detection profile and an exponentially decaying profile in axial direction, including a triplet component\cite{Starr2001, Hassler2005, Ohsugi2006}. \\
\end{tabular}
\begin{align}
G(\tau) = &A_0 + \frac{1}{n (1-F + \alpha F)^2} \left(1 + \frac{T e^{-\tau/\tau_\mathrm{trip}}}{1-T}  \right)  \times \\
\notag \times  \Bigg[ \,\, & 
\frac{F \kappa}{1+ 4 D_1 \tau/R_0^2} 
\left( \sqrt{\frac{D_1 \tau}{\pi}} + \frac{1 - 2 D_1 \tau \kappa^2}{2 \kappa}  w\!\left(i \sqrt{D_1 \tau} \kappa\right) \right) + \\
 \notag + &
\frac{(1-F) \alpha^2 \kappa}{1+ 4 D_2 \tau/R_0^2} 
\left( \sqrt{\frac{D_2 \tau}{\pi}} + \frac{1 - 2 D_2 \tau \kappa^2}{2 \kappa}  w\!\left(i \sqrt{D_2 \tau} \kappa\right) \right) \,\, \Bigg]
\end{align} 
\begin{center}
\begin{tabular}{ll}
$A_0$ & Offset \\ 
$n$ & Effective number of particles in confocal volume ($n = n_1+n_2$) \\ 
$D_1$ &  Diffusion coefficient of species 1 \\ 
$D_2$ &  Diffusion coefficient of species 2 \\ 
$F$ & Fraction of molecules of species 1 ($n_1 = F n$) \\
$\alpha$ & Relative molecular brightness of particle species ($ \alpha = q_2/q_1$) \\
$R_0$ & Lateral extent of the detection volume \\
$\kappa$ &  Evanescent decay constant ($\kappa = 1/d_\mathrm{eva}$)\\ 
$T$ &  Fraction of particles in triplet (non-fluorescent) state\\ 
$\tau_\mathrm{trip}$ &  Characteristic residence time in triplet state \\ 
\end{tabular}
\end{center}
\vspace{2em}




% 2D+3D+T diffusion (Gauß/exp)
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{TIR (Gaussian/Exp.) T+3D+2D} \\ 
ID & \textbf{6033} \\ 
Descr. &  Two-component, two- and three-dimensional diffusion with a Gaussian lateral detection profile and an exponentially decaying profile in axial direction, including a triplet component\cite{Starr2001, Hassler2005, Ohsugi2006}. \\ 
\end{tabular}
\begin{align}
G(\tau) &= A_0 + \frac{1}{n (1-F + \alpha F)^2} \left(1 + \frac{T e^{-\tau/\tau_\mathrm{trip}}}{1-T}  \right)  \times \\
& \notag \times  \left[
\frac{1-F}{1+ 4 D_\mathrm{2D} \tau/R_0^2} + 
\frac{\alpha^2 F \kappa}{1+ 4 D_\mathrm{3D} \tau/R_0^2} 
\left( \sqrt{\frac{D_\mathrm{3D} \tau}{\pi}} + \frac{1 - 2 D_\mathrm{3D} \tau \kappa^2}{2 \kappa}  w\!\left(i \sqrt{D_\mathrm{3D} \tau} \kappa\right) \right) \right]
\end{align} 
\begin{center}
\begin{tabular}{ll}
$A_0$ & Offset \\ 
$n$ & Effective number of particles in confocal volume ($n = n_\mathrm{2D}+n_\mathrm{3D}$) \\ 
$D_\mathrm{2D}$ &  Diffusion coefficient of surface bound particles \\ 
$D_\mathrm{3D}$ &  Diffusion coefficient of freely diffusing particles \\ 
$F$ & Fraction of molecules of the freely diffusing species ($n_\mathrm{3D} = F n$) \\
$\alpha$ & Relative molecular brightness of particle species ($ \alpha = q_\mathrm{3D}/q_\mathrm{2D}$) \\
$R_0$ & Lateral extent of the detection volume \\
$\kappa$ &  Evanescent decay constant ($\kappa = 1/d_\mathrm{eva}$)\\ 
$T$ &  Fraction of particles in triplet (non-fluorescent) state\\ 
$\tau_\mathrm{trip}$ &  Characteristic residence time in triplet state \\ 
\end{tabular}
\end{center}
\vspace{2em}




\subsubsection{TIR-FCS with a square-shaped lateral detection volume}


% 3D TIRF diffusion (□xσ)
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{TIR (□x$\upsigma$/Exp.) 3D} \\ 
ID & \textbf{6010} \\ 
Descr. &  Three-dimensional diffusion with a square-shaped lateral detection area taking into account the size of the point spread function; and an exponential decaying profile in axial direction\cite{Ries2008, Yordanov2011}. \\ 
\end{tabular}
\begin{align}
G(\tau) =  \frac{\kappa^2}{C} &
\left( \sqrt{\frac{D \tau}{\pi}} + \frac{1 - 2 D \tau \kappa^2)}{2 \kappa} w\!\left(i \sqrt{D \tau} \kappa\right) \right) \times \\
\notag  \times \Bigg[ & \frac{2 \sqrt{\sigma^2+D \tau}}{\sqrt{\pi} a^2}
\left( \exp\left(-\frac{a^2}{4(\sigma^2+D \tau)}\right) - 1 \right) +
\frac{1}{a} \, \mathrm{erf}\left(\frac{a}{2 \sqrt{\sigma^2+D \tau}}\right) \Bigg]^2
\end{align} 
\begin{center}
\begin{tabular}{ll}
$C$ & Particle concentration in detection volume \\ 
$\sigma$ & Lateral size of the point spread function \\ 
$a$ & Side size of the square-shaped detection area \\
$\kappa$ &  Evanescent decay constant ($\kappa = 1/d_\mathrm{eva}$)\\ 
$D$ & Diffusion coefficient \\
\end{tabular} \\
\end{center}
\vspace{2em}


% 3D+3D TIRF diffusion (□xσ)
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{TIR (□x$\upsigma$/Exp.) 3D+3D} \\ 
ID & \textbf{6023} \\ 
Descr. &  Two-component three-dimensional free diffusion with a square-shaped lateral detection area taking into account the size of the point spread function; and an exponential decaying profile in axial direction. \newline
The correlation function is a superposition of three-dimensional model functions of the type \textbf{3D (□x$\upsigma$)} (6010)\cite{Ries2008, Yordanov2011}. \\
\end{tabular}
\vspace{2em}


% 2D TIRF diffusion (□xσ)
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{TIR (□x$\upsigma$) 2D} \\ 
ID & \textbf{6000} \\ 
Descr. &  Two-dimensional diffusion with a square-shaped lateral detection area taking into account the size of the point spread function\cite{Ries2008, Yordanov2011}\footnote{The reader is made aware, that reference \cite{Ries2008} contains several unfortunate misprints.}. \\ 
\end{tabular}
\begin{align}
G(\tau) = \frac{1}{C} \left[
\frac{2 \sqrt{\sigma^2+D \tau}}{\sqrt{\pi} a^2}
\left( \exp\left(-\frac{a^2}{4(\sigma^2+D \tau)}\right) - 1 \right) +
\frac{1}{a} \, \mathrm{erf}\left(\frac{a}{2 \sqrt{\sigma^2+D \tau}}\right)
\right]^2
\end{align} 
\begin{center}
\begin{tabular}{ll}
$C$ & Particle concentration in detection area \\ 
$\sigma$ & Lateral size of the point spread function \\ 
$a$ & Side size of the square-shaped detection area \\
$D$ & Diffusion coefficient \\
\end{tabular} \\
\end{center}
\vspace{2em}


% 2D+2D TIRF diffusion (□xσ)
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{TIR (□x$\upsigma$) 2D+2D} \\ 
ID & \textbf{6022} \\ 
Descr. &  Two-component two-dimensional diffusion with a square-shaped lateral detection area taking into account the size of the point spread function. \newline
The correlation function is a superposition of two-dimensional model functions of the type \textbf{2D (□x$\upsigma$)} (6000)\cite{Ries2008, Yordanov2011}. \\
\end{tabular}
\vspace{2em}


% 3D+2D TIRF diffusion (□xσ)
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{TIR (□x$\upsigma$/Exp.) 3D+2D} \\ 
ID & \textbf{6020} \\ 
Descr. &  Two-component two- and three-dimensional diffusion with a square-shaped lateral detection area taking into account the size of the point spread function; and an exponential decaying profile in axial direction.  \newline
The correlation function is a superposition of the two-dimensional model function \textbf{2D (□x$\upsigma$)} (6000) and the three-dimensional model function \textbf{3D (□x$\upsigma$)} (6010)\cite{Ries2008, Yordanov2011}.
\end{tabular}
\vspace{2em}


% 3D+2D+kin TIRF diffusion (□xσ)
\noindent \begin{tabular}{lp{.7\textwidth}}
Name & \textbf{TIR (□x$\upsigma$/Exp.) 3D+2D+kin} \\ 
ID & \textbf{6021} \\ 
Descr. &  Two-component two- and three-dimensional diffusion with a square-shaped lateral detection area taking into account the size of the point spread function; and an exponential decaying profile in axial direction. This model covers binding and unbinding kintetics.  \newline 
The correlation function for this model was introduced in \cite{Ries2008}. Because approximations are made in the derivation, please verify if this model is applicable to your problem before using it.
\end{tabular}


