constraints function

Create a constraints object