gammas = new double[ A.numCols() ];
for( int i = 0; i < N; i++ ) {
// use extract matrix to get the column that is to be zeroed
SimpleMatrix v = QR.extractMatrix(i, END,i,i+1);
double max = v.elementMaxAbs();
if( max > 0 && v.getNumElements() > 1 ) {
// normalize to reduce overflow issues
v = v.divide(max);