PEGAS: Hydrodynamical code for numerical simulation of the gas components of interacting galaxies