function [mapW, vmapW, mapI, vmapI, mapO, vmapO] = BuildBCMaps()

% create boundary maps

Globals2D;

boundary_points = length(mapB);
mapW = zeros(boundary_points,1);
mapF = zeros(boundary_points,1);
wall_temp = 0;
far_temp = 0;
for i = 1:boundary_points
    if ((y(vmapB(i)) <= y_l + NODETOL) && (n_y(mapB(i)) == -1))
        wall_temp = wall_temp + 1;
        mapW(wall_temp) = mapB(i);
    end
    if (((x(vmapB(i)) >= x_u - NODETOL) && (n_x(mapB(i)) == 1)) || ((x(vmapB(i)) <= x_l + NODETOL) && (n_x(mapB(i)) == -1)) || ((y(vmapB(i)) >= y_u - NODETOL) && (n_y(mapB(i)) == 1)))
        far_temp = far_temp + 1;
        mapF(far_temp) = mapB(i);
    end
end
mapW((wall_temp + 1):boundary_points) = [];
mapF((far_temp + 1):boundary_points) = [];
vmapW = vmapM(mapW);
vmapF = vmapM(mapF);

dotproducts = u_0 * n_x(mapF) + v_0 * n_y(mapF);
mapI_ind = find(dotproducts < -1e-10);
mapI = mapF(mapI_ind);
vmapI = vmapM(mapI);
mapO = setdiff(mapF,mapI);
vmapO = vmapM(mapO);

end