NRsparseMat bs=as.transpose();
ADAT c = new ADAT(as,bs);
double[] d = new double[M]; // Random diagonal matrix
ranvec(d);
c.updateD(d); // Update ADAT object
NRsparseMat cs=c.ref(); // cs represents N x N matrix
// Next, compute the N x N matrix by brute force
double[][] e = new double[M][N];
for (i=0;i<M;i++)