\documentclass{article}

\usepackage{ifthen}

\input{flatex}   % include all the FLaTeX commands

\begin{document}

% The below figure in the \LaTeX document will be filled in by 
% defining a number of commands.  

\resetsteps      % Reset all the commands to create a blank worksheet  

% I like defining these kinds of commands to make most of the source
% as generic as possible

\newcommand{\ArgOne}{L}
\newcommand{\ArgTwo}{B}

% Fill in the operation to be performed

\renewcommand{\operation}{ \ArgTwo \becomes \ArgOne^{-1} \ArgTwo }

% Step 1a: Fill in the precondition

\newcommand{\OrigTwo}{ \hat{\ArgTwo} }  % set \OrgTwo = \hat{B} 

\renewcommand{\precondition}{ 
\ArgTwo = \hat{\OrigTwo}                % B = \hat{B}
}

% Step 1b: Fill in the postcondition

\renewcommand{\postcondition}{ 
\ArgTwo = \ArgOne^{-1} \hat{\OrigTwo}   % B = L^{-1} \hat{B}
}

% Step 2: Fill in the loop-invariant

\newcommand{\PartArgTwo}{               % Partition B into top and bottom
\FlaTwoByOne 
  { \ArgTwo_{T} }
  { \ArgTwo_{B} }
}

\renewcommand{\invariant}{              % Give the invariant
\PartArgTwo
    =
\FlaTwoByOne 
  { L_{TL}^{-1} \hat{B}_{T} }
  { \hat{B}_{B} - L_{BL} L_{TL}^{-1} \hat{B}_T }
}

% Step 3: Fill in the loop-guard

\renewcommand{\guard}{
n( L_{TL} ) \neq n( L )
}

% Step 4: Fill in the initialization

\newcommand{\PartArgOne}{               % Partition L into quadrants
\FlaTwoByTwo
  { \ArgOne_{TL} }{   0     }
  { \ArgOne_{BL} }{ \ArgOne_{BR} }
}

\newcommand{\PartOrigTwo}{              % Partition \hat{B} into top and bottom
\FlaTwoByOne 
  { \OrigTwo_{T} }
  { \OrigTwo_{B} }
}

% Insert the partitionings into the nitialization

\renewcommand{\partitionings}{
$ \ArgOne \rightarrow \PartArgOne $,    % Partition L
$ \ArgTwo \rightarrow \PartArgTwo $,    % Partition B
\\                       % move to next line
and
$ \OrigTwo \rightarrow \PartOrigTwo $  % Partition B
}

% Insert the sizes of the partitionings into the initialization

\renewcommand{\partitionsizes}{
$ \ArgOne_{TL} $ is $ 0 \times 0 $, and 
$ \ArgTwo_{T} $ and $ \OrigTwo_{T} $
have $ 0 $ rows
}

% Typically, in a document, an algorithm will appear in a separate figure.
% For this we use the \LaTeX figure environment.  The optional arguments
% [tbp] indicate that the figure should be placed at the first of
% the top of a page, the bottom of a page, or on a page by itself, in
% that order.

\begin{figure}[tbp]

\begin{center}     % center the algorithm on the page

\worksheet         % this command generates the worksheet using the
                   % commands that were defined between the \resetsteps
                   % and the \worksheet command
\end{center}

% The following command creates a caption for the figure.

\caption{ Worksheet (incomplete) for deriving unblocked algorithm for
$ B \becomes L^{-1} B $ (Variant 2).}


% The following command creates a label so that the figure can
% be referenced by its number by inserting 
%  \ref{Trsm_llnn:annotated_unb_var2} in the \LaTeX source

\label{Trsm_llnn:annotated_unb_var2}

\end{figure}

\end{document}