Constraint-based Analysis and Design of Organizations