A Constraint Solver for Flexible Protein Model