add flow constraint