evacuation-i.mod 292 B

1234567891011121314151617
  1. # SETS
  2. set V;
  3. set T within V;
  4. set E within {V,V};
  5. set A within {V,V} :=
  6. E union setof{(i,j) in E} (j,i);
  7. # PARAMS
  8. param s symbolic in T;
  9. param c{(i,j) in A} >= 0, default if (j,i) in E then c[j,i];
  10. param b{h in V} =
  11. (if h = s then card(T)-1
  12. else if h in T then -1
  13. else 0);