You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: SteadyLidDrivenCavityExample.m
    path of file: ./repos/FVTool/Examples/External/SteadyLidDrivenCavityProblem
    
    the code of the file until where you have to start completion: function SteadyLidDrivenCavityExample( varargin )
%SteadyLidDrivenCavityExample() solves the steady Lid-driven cavity problem

    
function SteadyLidDrivenCavityExample( varargin )
%SteadyLidDrivenCavityExample() solves the steady Lid-driven cavity problem
%   In this 2D example, the momentum equation is solved for velocity and 
%   pressure using a collocated grid with rhie chow interpolation of the 
%   velocies to the cellfaces and the SIMPLE algorithm. The results are
%   then compared to a reference solution given by:
%     Ghia, U. K. N. G., Kirti N. Ghia, and C. T. Shin. 
%     "High-Re solutions for incompressible flow using the Navier-Stokes 
%     equations and a multigrid method."
%     Journal of computational physics 48.3 (1982): 387-411.
%
%   See also MomentumEq, RhieChow, GhiaSolution.
%
%   Date:   18.10.2015
%   Author: Kai Schueller
%
%   Known problems: - works only for equidistant dx dy
%                   - it works for both Rhie Chow and arithmetic mean
%                     interpolation? Maybe checkerboarding effect is not
%                     that big for the considered problem
%                   - it seems that there is no difference when using
%                     arithmetic mean or central difference for Rhie Chow,
%                     but in literature, Rhie Chow needs central difference
%                     to work properly

close all; % closes all figures

addpath('Functions'); % add Functions folder to the search path

% get the reference solution values
testSol=GhiaSolution;

%% User Input
USE_CHOW_INTERP=1;             % flag to choose the rhie-chow interpolation
p_relax=1;                     % pressure relaxation
velo_relax=0.9;                % velocity relaxation
u_init=0;                      % initial guess for x-velocity
v_init=0;                      % initial guess for y-velocity
p_init=0;                      % initial guess for pressure
Re=100;                        % Reynolds number % 100, 400 and 1000 is possible
lidVelo=1;                     % velocity of the lid [m/s]
rho=1000;                      % density [kg/m^3]
cavityLength=0.1;              % length of one edge of the quare cavity [m]
mu=rho*cavityLength*lidVelo/Re;% dynamic viscosity
nIter=250;                     % number of iterations

% First create the mesh
m=createMesh2D(51,51,cavityLength,cavityLength);
%visualizeMesh2D(m); % Uncomment if mesh should be displayed

%% Boundary Conditions
% Since the momentum equation is solved for both, u (velocity in x) and v
% (velocity in y), we need two separate sets of boundaries (u and v)
U_BC = createBC(m);
V_BC = createBC(m);

% Assign boundary conditions u-momentum equation
U_BC.top.a(:) = 0; U_BC.top.b(:)=1; U_BC.top.c(:)=lidVelo;    % lid velocity in x-direction at the top of the cavity
U_BC.left.a(:) = 0; U_BC.left.b(:)=1; U_BC.left.c(:)=0;       % zero x-velocity at left boundary 
U_BC.right.a(:) = 0; U_BC.right.b(:)=1; U_BC.right.c(:)=0;    % zero x-velocity right boundary 
U_BC.bottom.a(:) = 0; U_BC.bottom.b(:)=1; U_BC.bottom.c(:)=0; % no-slip at bottom boundary 

% Assign boundary conditions for v-momentum equation
V_BC.top.a(:) = 0; V_BC.top.b(:)=1; V_BC.top.c(:)=0;          % zero y-velocity at top boundary
V_BC.bottom.a(:) = 0; V_BC.bottom.b(:)=1; V_BC.bottom.c(:)=0; % zero y-velocity at bottom boundary
V_BC.left.a(:) = 0; V_BC.left.b(:)=1; V_BC.left.c(:)=0;       % no-slip at left boundary 
V_BC.right.a(:) = 0; V_BC.right.b(:)=1; V_BC.right.c(:)=0;    % no-slip at right boundary 

% Assign boundary conditions for the pressure correction equation
P_BC = createBC(m); % this automatically creates all Neumann, which is needed here
% we need to set a refence pressure, because otherwise matlab throws the
% following warning for pressure correction: Matrix is close to singular or
% badly scaled. Results may be inaccurate.
P_BC.bottom.a(end