\hypertarget{group__local__pf__fold}{
\section{Partition functions for locally stable secondary structures}
\label{group__local__pf__fold}\index{Partition functions for locally stable secondary structures@{Partition functions for locally stable secondary structures}}
}


Collaboration diagram for Partition functions for locally stable secondary structures:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=306pt]{group__local__pf__fold}
\end{center}
\end{figure}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{group__local__pf__fold_ga5a019014d37fe6105131dfc2fc447880}{update\_\-pf\_\-paramsLP} (int length)
\item 
\hyperlink{structplist}{plist} $\ast$ \hyperlink{group__local__pf__fold_gaa1ecd401617ebc748a0220026543c777}{pfl\_\-fold} (char $\ast$sequence, int winSize, int pairSize, float cutoffb, double $\ast$$\ast$pU, struct \hyperlink{structplist}{plist} $\ast$$\ast$dpp2, FILE $\ast$pUfp, FILE $\ast$spup)
\begin{DoxyCompactList}\small\item\em Compute partition functions for locally stable secondary structures. \item\end{DoxyCompactList}\item 
\hypertarget{group__local__pf__fold_gab354507e8028f3e1c52ef96bb1eb9df8}{
\hyperlink{structplist}{plist} $\ast$ \hyperlink{group__local__pf__fold_gab354507e8028f3e1c52ef96bb1eb9df8}{pfl\_\-fold\_\-par} (char $\ast$sequence, int winSize, int pairSize, float cutoffb, double $\ast$$\ast$pU, struct \hyperlink{structplist}{plist} $\ast$$\ast$dpp2, FILE $\ast$pUfp, FILE $\ast$spup, \hyperlink{structpf__paramT}{pf\_\-paramT} $\ast$parameters)}
\label{group__local__pf__fold_gab354507e8028f3e1c52ef96bb1eb9df8}

\begin{DoxyCompactList}\small\item\em Compute partition functions for locally stable secondary structures. \item\end{DoxyCompactList}\item 
void \hyperlink{group__local__pf__fold_ga0bcb751860bbf34e3dfee8c2fbdb3ef3}{putoutpU\_\-prob} (double $\ast$$\ast$pU, int length, int ulength, FILE $\ast$fp, int energies)
\begin{DoxyCompactList}\small\item\em Writes the unpaired probabilities (pU) or opening energies into a file. \item\end{DoxyCompactList}\item 
void \hyperlink{group__local__pf__fold_ga9acb00ee10e96b1ca4ea394cd8bcec75}{putoutpU\_\-prob\_\-bin} (double $\ast$$\ast$pU, int length, int ulength, FILE $\ast$fp, int energies)
\begin{DoxyCompactList}\small\item\em Writes the unpaired probabilities (pU) or opening energies into a binary file. \item\end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Function Documentation}
\hypertarget{group__local__pf__fold_ga5a019014d37fe6105131dfc2fc447880}{
\index{local\_\-pf\_\-fold@{local\_\-pf\_\-fold}!update\_\-pf\_\-paramsLP@{update\_\-pf\_\-paramsLP}}
\index{update\_\-pf\_\-paramsLP@{update\_\-pf\_\-paramsLP}!local_pf_fold@{local\_\-pf\_\-fold}}
\subsubsection[{update\_\-pf\_\-paramsLP}]{\setlength{\rightskip}{0pt plus 5cm}void update\_\-pf\_\-paramsLP (int {\em length})}}
\label{group__local__pf__fold_ga5a019014d37fe6105131dfc2fc447880}

\begin{DoxyParams}{Parameters}
\item[{\em length}]\end{DoxyParams}
\hypertarget{group__local__pf__fold_gaa1ecd401617ebc748a0220026543c777}{
\index{local\_\-pf\_\-fold@{local\_\-pf\_\-fold}!pfl\_\-fold@{pfl\_\-fold}}
\index{pfl\_\-fold@{pfl\_\-fold}!local_pf_fold@{local\_\-pf\_\-fold}}
\subsubsection[{pfl\_\-fold}]{\setlength{\rightskip}{0pt plus 5cm}{\bf plist}$\ast$ pfl\_\-fold (char $\ast$ {\em sequence}, \/  int {\em winSize}, \/  int {\em pairSize}, \/  float {\em cutoffb}, \/  double $\ast$$\ast$ {\em pU}, \/  struct {\bf plist} $\ast$$\ast$ {\em dpp2}, \/  FILE $\ast$ {\em pUfp}, \/  FILE $\ast$ {\em spup})}}
\label{group__local__pf__fold_gaa1ecd401617ebc748a0220026543c777}


Compute partition functions for locally stable secondary structures. pfl\_\-fold computes partition functions for every window of size 'winSize' possible in a RNA molecule, allowing only pairs with a span smaller than 'pairSize'. It returns the mean pair probabilities averaged over all windows containing the pair in 'pl'. 'winSize' should always be $>$= 'pairSize'. Note that in contrast to \hyperlink{group__local__mfe__fold_ga16e5a70e60835bb969eaecbe6482f1be}{Lfold()}, bases outside of the window do not influence the structure at all. Only probabilities higher than 'cutoffb' are kept.

If 'pU' is supplied (i.e is not the NULL pointer), \hyperlink{group__local__pf__fold_gaa1ecd401617ebc748a0220026543c777}{pfl\_\-fold()} will also compute the mean probability that regions of length 'u' and smaller are unpaired. The parameter 'u' is supplied in 'pup\mbox{[}0\mbox{]}\mbox{[}0\mbox{]}'. On return the 'pup' array will contain these probabilities, with the entry on 'pup\mbox{[}x\mbox{]}\mbox{[}y\mbox{]}' containing the mean probability that x and the y-\/1 preceding bases are unpaired. The 'pU' array needs to be large enough to hold n+1 float$\ast$ entries, where n is the sequence length.

If an array dpp2 is supplied, the probability of base pair (i,j) given that there already exists a base pair (i+1,j-\/1) is also computed and saved in this array. If pUfp is given (i.e. not NULL), pU is not saved but put out imediately. If spup is given (i.e. is not NULL), the pair probabilities in pl are not saved but put out imediately.


\begin{DoxyParams}{Parameters}
\item[{\em sequence}]RNA sequence \item[{\em winSize}]size of the window \item[{\em pairSize}]maximum size of base pair \item[{\em cutoffb}]cutoffb for base pairs \item[{\em pU}]array holding all unpaired probabilities \item[{\em dpp2}]array of dependent pair probabilities \item[{\em pUfp}]file pointer for pU \item[{\em spup}]file pointer for pair probabilities \end{DoxyParams}
\begin{DoxyReturn}{Returns}
list of pair probabilities 
\end{DoxyReturn}
\hypertarget{group__local__pf__fold_ga0bcb751860bbf34e3dfee8c2fbdb3ef3}{
\index{local\_\-pf\_\-fold@{local\_\-pf\_\-fold}!putoutpU\_\-prob@{putoutpU\_\-prob}}
\index{putoutpU\_\-prob@{putoutpU\_\-prob}!local_pf_fold@{local\_\-pf\_\-fold}}
\subsubsection[{putoutpU\_\-prob}]{\setlength{\rightskip}{0pt plus 5cm}void putoutpU\_\-prob (double $\ast$$\ast$ {\em pU}, \/  int {\em length}, \/  int {\em ulength}, \/  FILE $\ast$ {\em fp}, \/  int {\em energies})}}
\label{group__local__pf__fold_ga0bcb751860bbf34e3dfee8c2fbdb3ef3}


Writes the unpaired probabilities (pU) or opening energies into a file. Can write either the unpaired probabilities (accessibilities) pU or the opening energies -\/log(pU)kT into a file


\begin{DoxyParams}{Parameters}
\item[{\em pU}]pair probabilities \item[{\em length}]length of RNA sequence \item[{\em ulength}]maximum length of unpaired stretch \item[{\em fp}]file pointer of destination file \item[{\em energies}]switch to put out as opening energies \end{DoxyParams}
\hypertarget{group__local__pf__fold_ga9acb00ee10e96b1ca4ea394cd8bcec75}{
\index{local\_\-pf\_\-fold@{local\_\-pf\_\-fold}!putoutpU\_\-prob\_\-bin@{putoutpU\_\-prob\_\-bin}}
\index{putoutpU\_\-prob\_\-bin@{putoutpU\_\-prob\_\-bin}!local_pf_fold@{local\_\-pf\_\-fold}}
\subsubsection[{putoutpU\_\-prob\_\-bin}]{\setlength{\rightskip}{0pt plus 5cm}void putoutpU\_\-prob\_\-bin (double $\ast$$\ast$ {\em pU}, \/  int {\em length}, \/  int {\em ulength}, \/  FILE $\ast$ {\em fp}, \/  int {\em energies})}}
\label{group__local__pf__fold_ga9acb00ee10e96b1ca4ea394cd8bcec75}


Writes the unpaired probabilities (pU) or opening energies into a binary file. Can write either the unpaired probabilities (accessibilities) pU or the opening energies -\/log(pU)kT into a file


\begin{DoxyParams}{Parameters}
\item[{\em pU}]pair probabilities \item[{\em length}]length of RNA sequence \item[{\em ulength}]maximum length of unpaired stretch \item[{\em fp}]file pointer of destination file \item[{\em energies}]switch to put out as opening energies \end{DoxyParams}
