let complement = function | F -> T | Pos -> Nonpos | Neg -> Nonneg | Nonneg -> Neg | Nonpos -> Pos | T -> F | _ -> raise (Invalid_argument "not complementable")