v class = 'SectionBlock containment'><div class = "S1"><span class = "S2"><span class="S0">We subtract off its projection in the previous direction. The remainder is rescaled to give us the next orthonormal column.</span></span></div><div class = 'CodeBlock contiguous'><div class = 'inlineWrapper'><div class = "S4 lineNode"><span class = "S5"><span class="S0">v = Aq - (Q(:,1)'*Aq)*Q(:,1);</span></span></div></div><div class = 'inlineWrapper'><div class = "S4 lineNode"><span class = "S5"><span class="S0">Q(: