matrixdim(x,x) is now implemented correctly into findxw