add n,m,h update method