Hu Algorithm