Added constrainedby and improved documentation