Change arcs_involving() into neighbors() (it makes a lot more sense, given the implementation of satisfies_constraint() now making it so it doesn't matter what order you pass in variables/values).