</span> size(u,1) == 1
        u = u';
    <span class="keyword">end</span>
<span class="keyword">end</span>

<span class="keyword">if</span> nargin &lt; 6
    u = [];
<span class="keyword">end</span>
<span class="keyword">if</span> nargin &lt; 5
    l = [];
<span class="keyword">end</span>


<span class="comment">% verifying that there is a directed path between any pair of cells in at</span>
<span class="comment">% least one of the 2 graphs</span>

paths_H = adj_H;
paths_V = adj_V;
temp_H = adj_H^2;
temp_