numerical simulation for two dimensional gravity wave in the vertical and horizontal