Response of a beam to a moving mass