Added kruskals random matix algorithm