Simulation of transient flow in hydroelectric power plants using unsteady friction