how check a function satisfy lipschitz condition