Crack effect on dynamic stability of beams under conservative and nonconservative forces