A body of mass m is dropped from a height of h. Simultaneously another body of mass 2m is thrown up vertically with such a velocity v that they collide at height h2. If the collision is perfectly inelastic, the velocity of combined mass at the time of collision with the ground will be-