SHARE
TWEET

Untitled

a guest Sep 6th, 2019 94 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. type expr =
  2.         Implication of (expr * expr) |
  3.         Conjunction of (expr * expr) |
  4.         Disjunction of (expr * expr) |
  5.         Negation of expr |
  6.         Forall of (string * expr) |
  7.         Exists of (string * expr) |
  8.         Predicate of (string * term list) |
  9.         Equals of (term * term)
  10. and term =
  11.         Add of (term * term) |
  12.         Multiply of (term * term) |
  13.         Var of string |
  14.         Increment of term |
  15.         Zero |
  16.         Function of (string * term list)
  17. and document = Document of (expr list * expr * expr list);;
  18.  
  19. let take s ind = if String.length s <= ind || ind < 0 then None else Some (String.get s ind);;
  20.  
  21. let rec trim s =
  22.         match take s 0 with
  23.         | Some ' ' -> trim (String.sub s 1 (String.length s - 1))
  24.         | _ -> s;;
  25.  
  26. let rec trim_end s =
  27.         match take s (String.length s - 1) with
  28.         | Some ' ' | Some '\n' | Some '\t' -> trim_end (String.sub s 0 (String.length s - 1))
  29.         | _ -> s;;
  30.  
  31. let rec printTerm term =
  32.         match term with
  33.         | Add (a, b) -> "(" ^ (printTerm a) ^ "+" ^ (printTerm b) ^ ")"
  34.         | Multiply (a, b) -> "(" ^ (printTerm a) ^ "*" ^ (printTerm b) ^ ")"
  35.         | Var name -> name
  36.         | Increment a -> (printTerm a) ^ "'"
  37.         | Zero -> "0"
  38.         | Function (name, terms) -> name ^ "(" ^ (String.concat "," (List.map printTerm terms)) ^ ")";;
  39.  
  40. let rec printExpr expr =
  41.         match expr with
  42.         | Implication (a, b) -> "(" ^ (printExpr a) ^ "->" ^ (printExpr b) ^ ")"
  43.         | Conjunction (a, b) -> "(" ^ (printExpr a) ^ "&" ^ (printExpr b) ^ ")"
  44.         | Disjunction (a, b) -> "(" ^ (printExpr a) ^ "|" ^ (printExpr b) ^ ")"
  45.         | Negation a -> "!" ^ (printExpr a)
  46.         | Forall (name, e) -> "(@" ^ name ^ "." ^ (printExpr e) ^ ")"
  47.         | Exists (name, e) -> "(?" ^ name ^ "." ^ (printExpr e) ^ ")"
  48.         | Predicate (name, es) -> name ^ "(" ^ (String.concat "," (List.map printTerm es)) ^ ")"
  49.         | Equals (a, b) -> (printTerm a) ^ "=" ^ (printTerm b);;
  50.  
  51. let rec parseImplication s =
  52.         match parseDisjunction s with
  53.         | Some (dis, s) ->
  54.                 let s = trim s in
  55.                 (match (take s 0, take s 1) with
  56.                 | (Some '-', Some '>') ->
  57.                         let s = String.sub s 2 (String.length s - 2) in
  58.                         (match parseImplication s with
  59.                         | Some (impl, s) -> Some (Implication (dis, impl), s)
  60.                         | None -> None)
  61.                 | _ -> Some (dis, s))
  62.         | None -> None
  63. and parseDisjunction s =
  64.         match parseConjunction s with
  65.         | Some (conj, s) ->
  66.                 let rec func prev s =
  67.                         let s = trim s in
  68.                         match take s 0 with
  69.                         | Some '|' ->
  70.                                 let s = String.sub s 1 (String.length s - 1) in
  71.                                 (match parseConjunction s with
  72.                                 | Some (conj, s) -> func (Disjunction (prev, conj)) s
  73.                                 | None -> None)
  74.                         | _ -> Some (prev, s) in
  75.                 func conj s
  76.         | None -> None
  77. and parseConjunction s =
  78.         match parseUnary s with
  79.         | Some (unary, s) ->
  80.                 let rec func prev s =
  81.                         let s = trim s in
  82.                         match take s 0 with
  83.                         | Some '&' ->
  84.                                 let s = String.sub s 1 (String.length s - 1) in
  85.                                 (match parseUnary s with
  86.                                 | Some (unary, s) -> func (Conjunction (prev, unary)) s
  87.                                 | None -> None)
  88.                         | _ -> Some (prev, s) in
  89.                 func unary s
  90.         | None -> None
  91. and parseUnary s =
  92.         let s = trim s in
  93.         match take s 0 with
  94.         | Some '(' ->
  95.                 (match parseImplication (String.sub s 1 (String.length s - 1)) with
  96.                 | Some (impl, s) ->
  97.                         let s = trim s in
  98.                         (match take s 0 with
  99.                         | Some ')' -> Some (impl, String.sub s 1 (String.length s - 1))
  100.                         | _ -> None)
  101.                 | None -> parsePredicate s)
  102.         | Some '!' -> (match parseUnary (String.sub s 1 (String.length s - 1)) with
  103.                 | Some (unary, s) -> Some (Negation unary, s)
  104.                 | None -> None)
  105.         | Some '@' | Some '?' ->
  106.                 let construct var expr = if take s 0 = Some '@' then Forall (var, expr) else Exists (var, expr) in
  107.                 (match parseVar (String.sub s 1 (String.length s - 1)) with
  108.                 | Some (Var var, s) ->
  109.                         let s = trim s in
  110.                         (match take s 0 with
  111.                         | Some '.' ->
  112.                                 (match parseUnary (String.sub s 1 (String.length s - 1)) with
  113.                                 | Some (impl, s) -> Some (construct var impl, s)
  114.                                 | None -> None)
  115.                         | _ -> None)
  116.                 | _ -> None)
  117.  
  118.         | _ ->
  119.                 parsePredicate s
  120. and parseVar s =
  121.         let s = trim s in
  122.         match take s 0 with
  123.         | Some a ->
  124.                 (match a with
  125.                 | 'a'..'z' ->
  126.                         let rec func have s =
  127.                                 match take s 0 with
  128.                                 | Some a ->
  129.                                         (match a with
  130.                                         | '0'..'9' ->
  131.                                                 func (have ^ (Char.escaped a)) (String.sub s 1 (String.length s - 1))
  132.                                         | _ -> (have, s))
  133.                                 | None -> (have, s) in
  134.                         let (name, s) = func (Char.escaped a) (String.sub s 1 (String.length s - 1)) in
  135.                         Some (Var name, s)
  136.                 | _ -> None)
  137.         | None -> None
  138. and parsePredicate s =
  139.         let s = trim s in
  140.         match take s 0 with
  141.         | Some a ->
  142.                 (match a with
  143.                 | 'A'..'Z' ->
  144.                         let rec func have s =
  145.                                 match take s 0 with
  146.                                 | Some a ->
  147.                                         (match a with
  148.                                         | '0'..'9' -> func (have ^ Char.escaped a) (String.sub s 1 (String.length s - 1))
  149.                                         | _ -> (have, s))
  150.                                 | None -> (have, s) in
  151.                         let (name, s) = func (Char.escaped a) (String.sub s 1 (String.length s - 1)) in
  152.                         (match take s 0 with
  153.                         | Some '(' ->
  154.                                 let s = String.sub s 1 (String.length s - 1) in
  155.                                 (match parseTerm s with
  156.                                 | Some (term, s) ->
  157.                                         let rec func s =
  158.                                                 let s = trim s in
  159.                                                 match take s 0 with
  160.                                                 | Some ',' ->
  161.                                                         (match parseTerm (String.sub s 1 (String.length s - 1)) with
  162.                                                         | Some (term, s) ->
  163.                                                                 (match func s with
  164.                                                                 | Some (terms, s) ->
  165.                                                                         Some (term :: terms, s)
  166.                                                                 | None -> None)
  167.                                                         | None -> None)
  168.                                                 | _ -> Some ([], s) in
  169.                                         (match func s with
  170.                                         | Some (terms, s) ->
  171.                                                 let s = trim s in
  172.                                                 (match take s 0 with
  173.                                                 | Some ')' ->
  174.                                                         Some (Predicate (name, term :: terms), String.sub s 1 (String.length s - 1))
  175.                                                 | _ -> None)
  176.                                         | None -> None)
  177.                                 | None -> None)
  178.                         | _ -> None)
  179.                 | _ ->
  180.                         (match parseTerm s with
  181.                         | Some (term, s) ->
  182.                                 let s = trim s in
  183.                                 (match take s 0 with
  184.                                 | Some '=' ->
  185.                                         (match parseTerm (String.sub s 1 (String.length s - 1)) with
  186.                                         | Some (term1, s) ->
  187.                                                 Some (Equals (term, term1), s)
  188.                                         | None -> None)
  189.                                 | _ -> None)
  190.                         | None -> None))
  191.         | None -> None
  192. and parseTerm s =
  193.         match parseSummand s with
  194.         | Some (summand, s) ->
  195.                 let rec func have s =
  196.                         let s = trim s in
  197.                         match take s 0 with
  198.                         | Some '+' ->
  199.                                 let s = String.sub s 1 (String.length s - 1) in
  200.                                 (match parseSummand s with
  201.                                 | Some (summand, s) ->
  202.                                         func (Add (have, summand)) s
  203.                                 | None -> None)
  204.                         | _ -> Some (have, s) in
  205.                 func summand s
  206.         | None -> None
  207. and parseSummand s =
  208.         match parseInc s with
  209.         | Some (mul, s) ->
  210.                 let rec func have s =
  211.                         let s = trim s in
  212.                         match take s 0 with
  213.                         | Some '*' ->
  214.                                 let s = String.sub s 1 (String.length s - 1) in
  215.                                 (match parseInc s with
  216.                                 | Some (mul, s) ->
  217.                                         func (Multiply (have, mul)) s
  218.                                 | None -> None)
  219.                         | _ -> Some (have, s) in
  220.                 func mul s
  221.         | None -> None
  222. and parseInc s =
  223.         match parseMultiplying s with
  224.         | Some (now, s) ->
  225.                 let rec func have s =
  226.                         let s = trim s in
  227.                         match take s 0 with
  228.                         | Some '\'' ->
  229.                                 func (Increment have) (String.sub s 1 (String.length s - 1))
  230.                         | _ -> (have, s) in
  231.                 let (now, s) = func now s in
  232.                 Some (now, s)
  233.         | None -> None
  234. and parseMultiplying s =
  235.         let s = trim s in
  236.         match take s 0 with
  237.         | Some a ->
  238.                 (match a with
  239.                 | '0' -> Some (Zero, String.sub s 1 (String.length s - 1))
  240.                 | '(' ->
  241.                         let s = String.sub s 1 (String.length s - 1) in
  242.                         (match parseTerm s with
  243.                         | Some (term, s) ->
  244.                                 let s = trim s in
  245.                                 (match take s 0 with
  246.                                 | Some ')' ->
  247.                                         Some (term, String.sub s 1 (String.length s - 1))
  248.                                 | _ -> None)
  249.                         | None -> None)
  250.                 | _ ->
  251.                         (match parseVar s with
  252.                         | Some (Var name, s) ->
  253.                                 (match take s 0 with
  254.                                 | Some '(' ->
  255.                                         let s = String.sub s 1 (String.length s - 1) in
  256.                                         (match parseTerm s with
  257.                                         | Some (term, s) ->
  258.                                                 let rec func s =
  259.                                                         let s = trim s in
  260.                                                         match take s 0 with
  261.                                                         | Some ',' ->
  262.                                                                 (match parseTerm (String.sub s 1 (String.length s - 1)) with
  263.                                                                 | Some (term, s) ->
  264.                                                                         (match func s with
  265.                                                                         | Some (terms, s) ->
  266.                                                                                 Some (term :: terms, s)
  267.                                                                         | None -> None)
  268.                                                                 | None -> None)
  269.                                                         | _ -> Some ([], s) in
  270.                                                 (match func s with
  271.                                                 | Some (terms, s) ->
  272.                                                         let s = trim s in
  273.                                                         (match take s 0 with
  274.                                                         | Some ')' ->
  275.                                                                 Some (Function (name, term :: terms), String.sub s 1 (String.length s - 1))
  276.                                                         | _ -> None)
  277.                                                 | None -> None)
  278.                                         | None -> None)
  279.                                 | _ -> Some (Var name, s))
  280.                         | _ -> None))
  281.         | None -> None;;
  282.  
  283. let parse s =
  284.         match parseImplication s with
  285.         | Some (expr, s) ->
  286.                 let s = trim s in
  287.                 if String.length s = 0 then Some expr else None
  288.         | None -> None;;
  289.  
  290. let find_barrier s =
  291.         let rec find_barrier_int s ind =
  292.                 match take s 0 with
  293.                 | Some '|' ->
  294.                         (match take s 1 with
  295.                         | Some '-' ->
  296.                                 Some ind
  297.                         | _ ->
  298.                                 find_barrier_int (String.sub s 1 (String.length s - 1)) (ind + 1))
  299.                 | Some a ->
  300.                         find_barrier_int (String.sub s 1 (String.length s - 1)) (ind + 1)
  301.                 | None -> None in
  302.         find_barrier_int s 0;;
  303.  
  304. let parseDocument s =
  305.         let rec func c s =
  306.                 match parseImplication s with
  307.                 | Some (impl, s) ->
  308.                         let s = trim s in
  309.                         if take s 0 = Some c then
  310.                                 (match func c (String.sub s 1 (String.length s - 1)) with
  311.                                 | Some (last, s) ->
  312.                                         Some (impl :: last, s)
  313.                                 | None -> None)
  314.                         else if take s 0 = None then
  315.                                 Some (impl :: [], s)
  316.                         else None
  317.                 | None -> None in
  318.         match find_barrier s with
  319.         | Some ind ->
  320.                 let s1 = trim (String.sub s 0 ind) in
  321.                 let s = trim_end (trim (String.sub s (ind + 2) (String.length s - ind - 2))) in
  322.                 (match ((if String.length s1 = 0 then Some ([], "") else func ',' s1), func '\n' s) with
  323.                 | (Some (d1, _) , Some (d2 :: d3, _)) ->
  324.                         Some (Document (d1, d2, d3))
  325.                 | _ -> None)
  326.         | None -> None;;
  327.  
  328. let printDocument (Document (d1, d2, d3)) = (String.concat "," (List.map printExpr d1)) ^ "|-" ^ (printExpr d2) ^ "\n" ^ (String.concat "\n" (List.map printExpr d3));;
  329.  
  330. let parse_bad s =
  331.         match parse s with
  332.         | Some x -> x
  333.         | None -> failwith "Bad expression"
  334. and parseDocument_bad s =
  335.         match parseDocument s with
  336.         | Some x -> x
  337.         | None -> failwith "Bad document";;
  338.  
  339. let rawSchemes =
  340.         ["A(0) -> B(0) -> A(0)";
  341.         "(A(0) -> B(0)) -> (A(0) -> B(0) -> C(0)) -> (A(0) -> C(0))";
  342.         "A(0) -> B(0) -> A(0) & B(0)";
  343.         "A(0) & B(0) -> A(0)";
  344.         "A(0) & B(0) -> B(0)";
  345.         "A(0) -> A(0) | B(0)";
  346.         "B(0) -> A(0) | B(0)";
  347.         "(A(0) -> C(0)) -> (B(0) -> C(0)) -> (A(0) | B(0) -> C(0))";
  348.         "(A(0) -> B(0)) -> (A(0) -> !B(0)) -> !A(0)";
  349.         "!!A(0) -> A(0)"];;
  350.  
  351. let schemes = List.map parse_bad rawSchemes;;
  352.  
  353. let rawAxioms =
  354.         ["a = b -> a' = b'";
  355.         "a = b -> a = c -> b = c";
  356.         "a' = b' -> a = b";
  357.         "!a' = 0";
  358.         "a + b' = (a + b)'";
  359.         "a + 0 = a";
  360.         "a * 0 = 0";
  361.         "a * b' = a * b + a"];;
  362.  
  363. let axioms = List.map parse_bad rawAxioms;;
  364.  
  365. module StringMap = Map.Make(String);;
  366. module ExprMap = Map.Make(struct type t = expr let compare = compare end);;
  367. module ExprSet = Set.Make(struct type t = expr let compare = compare end);;
  368. module StringSet = Set.Make(String);;
  369.  
  370. let rec freeVars e =
  371.         match e with
  372.         | Implication (a, b) | Conjunction (a, b) | Disjunction (a, b) ->
  373.                 StringSet.union (freeVars a) (freeVars b)
  374.         | Negation a ->
  375.                 freeVars a
  376.         | Exists (name, a) | Forall (name, a) ->
  377.                 StringSet.remove name (freeVars a)
  378.         | Predicate (_, l) ->
  379.                 List.fold_left (fun m a -> StringSet.union m (freeVarsTerm a)) StringSet.empty l
  380.         | Equals (a, b) ->
  381.                 StringSet.union (freeVarsTerm a) (freeVarsTerm b)
  382. and freeVarsTerm t =
  383.         match t with
  384.         | Add (a, b) | Multiply (a, b) ->
  385.                 StringSet.union (freeVarsTerm a) (freeVarsTerm b)
  386.         | Var name ->
  387.                 StringSet.singleton name
  388.         | Increment a ->
  389.                 freeVarsTerm a
  390.         | Zero ->
  391.                 StringSet.empty
  392.         | Function (_, l) ->
  393.                 List.fold_left (fun m a -> StringSet.union m (freeVarsTerm a)) StringSet.empty l;;
  394.  
  395. let upperPred e name =
  396.         let rec upperPredExpr e name =
  397.                 match e with
  398.                 | Implication (a, b) | Conjunction (a, b) | Disjunction (a, b) ->
  399.                         (match (upperPredExpr a name, upperPredExpr b name) with
  400.                         | (None, None) -> None
  401.                         | (a, b) -> Some (StringSet.union (takeOr a) (takeOr b)))
  402.                 | Negation a ->
  403.                         upperPredExpr a name
  404.                 | Exists (var, a) | Forall (var, a) ->
  405.                         (match upperPredExpr a name with
  406.                         | None -> None
  407.                         | Some b -> Some (StringSet.add var b))
  408.                 | Predicate (_, l) ->
  409.                         List.fold_left (fun m a ->
  410.                                 match m with
  411.                                 | None -> upperPredTerm a name
  412.                                 | Some b ->
  413.                                         Some (StringSet.union b (takeOr (upperPredTerm a name)))) None l
  414.                 | Equals (a, b) ->
  415.                         (match (upperPredTerm a name, upperPredTerm b name) with
  416.                         | (None, None) -> None
  417.                         | (a, b) -> Some (StringSet.union (takeOr a) (takeOr b)))
  418.         and upperPredTerm t name =
  419.                 match t with
  420.                 | Add (a, b) | Multiply (a, b) ->
  421.                         (match (upperPredTerm a name, upperPredTerm b name) with
  422.                         | (None, None) -> None
  423.                         | (a, b) -> Some (StringSet.union (takeOr a) (takeOr b)))
  424.                 | Var var ->
  425.                         if var = name then Some StringSet.empty else None
  426.                 | Increment a ->
  427.                         upperPredTerm a name
  428.                 | Zero ->
  429.                         None
  430.                 | Function (_, l) ->
  431.                         List.fold_left (fun m a ->
  432.                                 match m with
  433.                                 | None -> upperPredTerm a name
  434.                                 | Some b ->
  435.                                         Some (StringSet.union b (takeOr (upperPredTerm a name)))) None l
  436.  
  437.         and takeOr a =
  438.                 match a with
  439.                 | Some b -> b
  440.                 | None -> StringSet.empty in
  441.         takeOr (upperPredExpr e name);;
  442.  
  443. let println_string s = print_string (s ^ "\n");;
  444.  
  445. let rec transformTerm e was became =
  446.         let rec transform t =
  447.                 if t = was then became else
  448.                         match t with
  449.                         | Add (a, b) ->
  450.                                 Add (transform a, transform b)
  451.                         | Multiply (a, b) ->
  452.                                 Multiply (transform a, transform b)
  453.                         | Var name ->
  454.                                 Var name
  455.                         | Increment a ->
  456.                                 Increment (transform a)
  457.                         | Zero ->
  458.                                 Zero
  459.                         | Function (name, l) ->
  460.                                 Function (name, List.map transform l) in
  461.         let rec func e =
  462.                 match e with
  463.                 | Implication (a, b) ->
  464.                         Implication (func a, func b)
  465.                 | Conjunction (a, b) ->
  466.                         Conjunction (func a, func b)
  467.                 | Disjunction (a, b) ->
  468.                         Disjunction (func a, func b)
  469.                 | Negation a ->
  470.                         Negation (func a)
  471.                 | Forall (var, a) ->
  472.                         Forall (var, func a)
  473.                 | Exists (var, a) ->
  474.                         Exists (var, func a)
  475.                 | Predicate (name, l) ->
  476.                         Predicate (name, List.map (fun e -> transform e) l)
  477.                 | Equals (a, b) ->
  478.                         Equals (transform a, transform b) in
  479.         func e
  480. and transformExpr e was became =
  481.         let rec func e =
  482.                 if e = was then became else
  483.                         match e with
  484.                         | Implication (a, b) ->
  485.                                 Implication (func a, func b)
  486.                         | Conjunction (a, b) ->
  487.                                 Conjunction (func a, func b)
  488.                         | Disjunction (a, b) ->
  489.                                 Disjunction (func a, func b)
  490.                         | Negation a ->
  491.                                 Negation (func a)
  492.                         | Forall (var, a) ->
  493.                                 Forall (var, func a)
  494.                         | Exists (var, a) ->
  495.                                 Exists (var, func a)
  496.                         | Predicate (name, l) ->
  497.                                 Predicate (name, l)
  498.                         | Equals (a, b) ->
  499.                                 Equals (a, b) in
  500.         func e;;
  501.  
  502. let rec findTerm e1 e2 need =
  503.         let rec find t1 t2 =
  504.                 if t1 = need then Some t2 else
  505.                         match (t1, t2) with
  506.                         | (Add (a1, b1), Add (a2, b2)) | (Multiply (a1, b1), Multiply (a2, b2)) ->
  507.                                 let res = find a1 a2 in
  508.                                 if res = None then find b1 b2 else res
  509.                         | (Increment a1, Increment a2) ->
  510.                                 find a1 a2
  511.                         | (Function (name1, l1), Function (name2, l2)) ->
  512.                                 if name1 = name2 then
  513.                                         if List.length l1 = List.length l2 then
  514.                                                 List.fold_left (fun a (b1, b2) ->
  515.                                                         match a with
  516.                                                         | Some c -> Some c
  517.                                                         | None -> find b1 b2) None (List.combine l1 l2)
  518.                                         else None
  519.                                 else None
  520.                         | (_, _) -> None in
  521.         let rec func e1 e2 =
  522.                 match (e1, e2) with
  523.                 | (Implication (a1, b1), Implication (a2, b2))
  524.                 | (Conjunction (a1, b1), Conjunction (a2, b2))
  525.                 | (Disjunction (a1, b1), Disjunction (a2, b2)) ->
  526.                         let res = func a1 a2 in
  527.                         if res = None then func b1 b2 else res
  528.                 | (Negation a1, Negation a2) ->
  529.                         func a1 a2
  530.                 | (Forall (var1, a1), Forall (var2, a2))
  531.                 | (Exists (var1, a1), Exists (var2, a2)) ->
  532.                         if var1 = var2 then func a1 a2 else None
  533.                 | (Predicate (name1, l1), Predicate (name2, l2)) ->
  534.                         if name1 = name2 then
  535.                                 if List.length l1 = List.length l2 then
  536.                                         List.fold_left (fun a (b1, b2) ->
  537.                                                 match a with
  538.                                                 | Some c -> Some c
  539.                                                 | None -> find b1 b2) None (List.combine l1 l2)
  540.                                 else None
  541.                         else None
  542.                 | (Equals (a1, b1), Equals (a2, b2)) ->
  543.                         let res = find a1 a2 in
  544.                         if res = None then find b1 b2 else res
  545.                 | (_, _) -> None in
  546.         func e1 e2
  547. and findExpr e1 e2 need =
  548.         let rec func e1 e2 =
  549.                 if e1 = need then Some e2 else
  550.                         match (e1, e2) with
  551.                         | (Implication (a1, b1), Implication (a2, b2))
  552.                         | (Conjunction (a1, b1), Conjunction (a2, b2))
  553.                         | (Disjunction (a1, b1), Disjunction (a2, b2)) ->
  554.                                 let res = func a1 a2 in
  555.                                 if res = None then func b1 b2 else res
  556.                         | (Negation a1, Negation a2) ->
  557.                                 func a1 a2
  558.                         | (Forall (var1, a1), Forall (var2, a2))
  559.                         | (Exists (var1, a1), Exists (var2, a2)) ->
  560.                                 if var1 = var2 then func a1 a2 else None
  561.                         | (_, _) -> None in
  562.         func e1 e2;;
  563.  
  564. let is_scheme_axiom e ax =
  565.         let func e was became =
  566.                 match became with
  567.                 | None -> e
  568.                 | Some became -> transformExpr e was became in
  569.         let a = findExpr ax e (Predicate ("A", [Zero])) in
  570.         let b = findExpr ax e (Predicate ("B", [Zero])) in
  571.         let c = findExpr ax e (Predicate ("C", [Zero])) in
  572.         let za = func ax (Predicate ("A", [Zero])) a in
  573.         let zb = func za (Predicate ("B", [Zero])) b in
  574.         let zc = func zb (Predicate ("C", [Zero])) c in
  575.         zc = e;;
  576.  
  577. let enumerate l =
  578.         let rec func l a =
  579.                 match l with
  580.                 | [] -> []
  581.                 | x :: xs -> (x, a) :: (func xs (a + 1)) in
  582.         func l 0;;
  583.  
  584. let which_scheme_axiom e =
  585.         let eschemes = enumerate schemes in
  586.         let axs = List.map (fun (a, num) -> if is_scheme_axiom e a then Some num else None) eschemes in
  587.         List.fold_left (fun was now ->
  588.                 match was with
  589.                 | None -> now
  590.                 | Some a -> Some a) None axs;;
  591.  
  592. let print_scheme_number e =
  593.         match which_scheme_axiom e with
  594.         | None -> -1
  595.         | Some a -> a;;
  596.  
  597. let check11 e =
  598.         match e with
  599.         | Implication (Forall (var, c), b) ->
  600.                 (match findTerm c b (Var var) with
  601.                 | Some expr ->
  602.                         if StringSet.is_empty (StringSet.inter (freeVarsTerm expr) (upperPred c var)) then
  603.                                 transformTerm c (Var var) expr = b
  604.                         else false
  605.                 | None -> false)
  606.         | _ -> false;;
  607.  
  608. let check12 e =
  609.         match e with
  610.         | Implication (b, Exists (var, c)) ->
  611.                 (match findTerm c b (Var var) with
  612.                 | Some expr ->
  613.                         if StringSet.is_empty (StringSet.inter (freeVarsTerm expr) (upperPred c var)) then
  614.                                 transformTerm c (Var var) expr = b
  615.                         else false
  616.                 | None -> false)
  617.         | _ -> false;;
  618.  
  619. let checkInduction e =
  620.         match e with
  621.         | Implication (Conjunction (s, Forall (var, bb)), res) ->
  622.                 s = (transformTerm res (Var var) Zero) && bb = (Implication (res, transformTerm res (Var var) (Increment (Var var))))
  623.         | _ -> false;;
  624.  
  625. let checkAllAxioms e =
  626.         match which_scheme_axiom e with
  627.         | Some a -> Some ("Scheme " ^ (string_of_int (a + 1)))
  628.         | None ->
  629.                 if check11 e then Some "Scheme 11" else
  630.                 if check12 e then Some "Scheme 12" else
  631.                 if checkInduction e then Some "Induction" else
  632.                 let eaxioms = enumerate axioms in
  633.                 match List.find_opt (fun (now, _) -> now = e) eaxioms with
  634.                 | Some (_, num) -> Some ("Axiom " ^ (string_of_int (num + 1)))
  635.                 | None -> None;;
  636.  
  637. let printAllAxioms e =
  638.         match checkAllAxioms e with
  639.         | None -> "Nothing"
  640.         | Some a -> a;;
  641.  
  642. let rec checkProof (Document (was, need, proof)) =
  643.         let wasExprs = List.fold_left (fun set x -> ExprSet.add x set) ExprSet.empty was in
  644.         let func was needLeft needRight e =
  645.                 if match checkAllAxioms e with
  646.                 | Some _ -> true
  647.                 | None ->
  648.                         match e with
  649.                         | Implication (a, Forall (x, b)) ->
  650.                                 if (List.exists (fun v -> v = x) (StringSet.elements (freeVars a)) = false) && (ExprSet.mem (Implication (a, b)) was) then true
  651.                                 else (ExprSet.mem e wasExprs) || (ExprSet.mem e needRight)
  652.                         | Implication (Exists (x, b), a) ->
  653.                                 if (List.exists (fun v -> v = x) (StringSet.elements (freeVars a)) = false) && (ExprSet.mem (Implication (b, a)) was) then true
  654.                                 else (ExprSet.mem e wasExprs) || (ExprSet.mem e needRight)
  655.                         | _ ->
  656.                                 (ExprSet.mem e wasExprs) || (ExprSet.mem e needRight) then
  657.                         let was = ExprSet.add e was in
  658.                         let (needLeft, needRight) =
  659.                                 match ExprMap.find_opt e needLeft with
  660.                                 | Some l ->
  661.                                         (ExprMap.remove e needLeft, List.fold_left (fun need x -> ExprSet.add x need) needRight l)
  662.                                 | None ->
  663.                                         (needLeft, needRight) in
  664.                         let (needLeft, needRight) =
  665.                                 match e with
  666.                                 | Implication (a, b) ->
  667.                                         if ExprSet.mem a was then (needLeft, ExprSet.add b needRight)
  668.                                         else (ExprMap.add a (b :: (match ExprMap.find_opt a needLeft with
  669.                                         | Some a -> a
  670.                                         | None -> [])) needLeft, needRight)
  671.                                 | _ ->
  672.                                         (needLeft, needRight) in
  673.                         Some (was, needLeft, needRight)
  674.                 else None in
  675.         let rec repeat eproof was needLeft needRight =
  676.                 match eproof with
  677.                 | (x, num) :: xs ->
  678.                         (match func was needLeft needRight x with
  679.                         | Some (was, needLeft, needRight) ->
  680.                                 repeat xs was needLeft needRight
  681.                         | None -> Some num)
  682.                 | [] -> None in
  683.         match repeat (enumerate proof) ExprSet.empty ExprMap.empty ExprSet.empty with
  684.         | Some num -> "Line " ^ (string_of_int (num + 1)) ^ " can't be obtained"
  685.         | None -> if List.exists (fun v -> v = need) proof then "Proof is correct" else "Required hasn't been proven";;
  686.  
  687. let parseList l = parseDocument_bad ("|-" ^ (List.nth l (List.length l - 1)) ^ "\n" ^ (String.concat "\n" l));;
  688. let rec parseL l =
  689.         match l with
  690.         | x :: xs ->
  691.                 (match parse x with
  692.                 | Some _ -> parseL xs
  693.                 | None -> "Error on " ^ x)
  694.         | [] -> "No errors";;
  695. let zeroEqZero =
  696.         ["(a=b->a=c->b=c)->(0=0->0=0->0=0)->(a=b->a=c->b=c)";
  697.          "a=b->a=c->b=c";
  698.          "0=0->0=0->0=0";
  699.          "(0=0->0=0->0=0)->(a=b->a=c->b=c)";
  700.          "(0=0->0=0->0=0)->@c.(a=b->a=c->b=c)";
  701.          "(0=0->0=0->0=0)->@b.@c.(a=b->a=c->b=c)";
  702.          "(0=0->0=0->0=0)->@a.@b.@c.(a=b->a=c->b=c)";
  703.          "@a.@b.@c.(a=b->a=c->b=c)";
  704.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(0+0=b->0+0=c->b=c)";
  705.          "@b.@c.(0+0=b->0+0=c->b=c)";
  706.          "@b.@c.(0+0=b->0+0=c->b=c)->@c.(0+0=0->0+0=c->0=c)";
  707.          "@c.(0+0=0->0+0=c->0=c)";
  708.          "@c.(0+0=0->0+0=c->0=c)->(0+0=0->0+0=0->0=0)";
  709.          "0+0=0->0+0=0->0=0";
  710.          "(a+0=a)->(0=0->0=0->0=0)->(a+0=a)";
  711.          "a+0=a";
  712.          "(0=0->0=0->0=0)->(a+0=a)";
  713.          "(0=0->0=0->0=0)->@a.(a+0=a)";
  714.          "@a.(a+0=a)";
  715.          "@a.(a+0=a)->(0+0=0)";
  716.          "0+0=0";
  717.          "0+0=0->0=0";
  718.          "0=0"];;
  719. let equality = zeroEqZero @
  720.         ["(0=0)&@a.(a=a->a'=a')->a=a";
  721.          "(a=b->a'=b')->(0=0)->(a=b->a'=b')";
  722.          "a=b->a'=b'";
  723.          "(0=0)->(a=b->a'=b')";
  724.          "(0=0)->@b.(a=b->a'=b')";
  725.          "@b.(a=b->a'=b')";
  726.          "(0=0)->@a.@b.(a=b->a'=b')";
  727.          "@a.@b.(a=b->a'=b')";
  728.          "@b.(a=b->a'=b')->(a=a->a'=a')";
  729.          "a=a->a'=a'";
  730.          "(a=a->a'=a')->0=0->(a=a->a'=a')";
  731.          "0=0->(a=a->a'=a')";
  732.          "0=0->@a.(a=a->a'=a')";
  733.          "@a.(a=a->a'=a')";
  734.          "(0=0)->@a.(a=a->a'=a')->(0=0)&@a.(a=a->a'=a')";
  735.          "@a.(a=a->a'=a')->(0=0)&@a.(a=a->a'=a')";
  736.          "(0=0)&@a.(a=a->a'=a')";
  737.          "a=a";
  738.          "a=a->0=0->a=a";
  739.          "0=0->a=a";
  740.          "0=0->@a.(a=a)";
  741.          "@a.(a=a)"];;
  742. let commutativity = equality @
  743.         ["(a=b->a=c->b=c)->(0=0)->(a=b->a=c->b=c)";
  744.          "a=b->a=c->b=c";
  745.          "0=0->a=b->a=c->b=c";
  746.          "0=0->@c.(a=b->a=c->b=c)";
  747.          "@c.(a=b->a=c->b=c)";
  748.          "@c.(a=b->a=c->b=c)->(a=b->a=a->b=a)";
  749.          "a=b->a=a->b=a";
  750.          "(a=b->a=a)->(a=b->a=a->b=a)->(a=b->b=a)";
  751.          "a=a->a=b->a=a";
  752.          "a=b->a=a";
  753.          "(a=b->a=a->b=a)->(a=b->b=a)";
  754.          "a=b->b=a";
  755.          "(a=b->b=a)->0=0->(a=b->b=a)";
  756.          "0=0->a=b->b=a";
  757.          "0=0->@b.(a=b->b=a)";
  758.          "0=0->@a.@b.(a=b->b=a)";
  759.          "@a.@b.(a=b->b=a)"];;
  760. let a'pbEqapb' = commutativity @
  761.         ["a=b->a'=b'";
  762.          "(a=b->a'=b')->0=0->a=b->a'=b'";
  763.          "0=0->a=b->a'=b'";
  764.          "0=0->@b.(a=b->a'=b')";
  765.          "0=0->@a.@b.(a=b->a'=b')";
  766.          "@a.@b.(a=b->a'=b')";
  767.          "@a.@b.(a=b->a'=b')->@b.(a'+e=b->(a'+e)'=b')";
  768.          "@b.(a'+e=b->(a'+e)'=b')";
  769.          "@b.(a'+e=b->(a'+e)'=b')->(a'+e=(a+e)'->(a'+e)'=(a+e)'')";
  770.          "a'+e=(a+e)'->(a'+e)'=(a+e)''";
  771.          "a+b'=(a+b)'";
  772.          "a+b'=(a+b)'->0=0->a+b'=(a+b)'";
  773.          "0=0->a+b'=(a+b)'";
  774.          "0=0->@b.(a+b'=(a+b)')";
  775.          "0=0->@a.@b.(a+b'=(a+b)')";
  776.          "@a.@b.(a+b'=(a+b)')";
  777.          "@a.@b.(a+b'=(a+b)')->@b.(a'+b'=(a'+b)')";
  778.          "@b.(a'+b'=(a'+b)')";
  779.          "@b.(a'+b'=(a'+b)')->a'+e'=(a'+e)'";
  780.          "a'+e'=(a'+e)'";
  781.          "@a.@b.(a=b->b=a)->@b.(a'+e'=b->b=a'+e')";
  782.          "@b.(a'+e'=b->b=a'+e')";
  783.          "@b.(a'+e'=b->b=a'+e')->(a'+e'=(a'+e)'->(a'+e)'=a'+e')";
  784.          "a'+e'=(a'+e)'->(a'+e)'=a'+e'";
  785.          "(a'+e)'=a'+e'";
  786.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.((a'+e)'=b->(a'+e)'=c->b=c)";
  787.          "@b.@c.((a'+e)'=b->(a'+e)'=c->b=c)";
  788.          "@b.@c.((a'+e)'=b->(a'+e)'=c->b=c)->@c.((a'+e)'=a'+e'->(a'+e)'=c->a'+e'=c)";
  789.          "@c.((a'+e)'=a'+e'->(a'+e)'=c->a'+e'=c)";
  790.          "@c.((a'+e)'=a'+e'->(a'+e)'=c->a'+e'=c)->((a'+e)'=a'+e'->(a'+e)'=(a+e)''->a'+e'=(a+e)'')";
  791.          "(a'+e)'=a'+e'->(a'+e)'=(a+e)''->a'+e'=(a+e)''";
  792.          "(a'+e)'=(a+e)''->a'+e'=(a+e)''";
  793.          "((a'+e)'=(a+e)''->a'+e'=(a+e)'')->(a'+e=(a+e)')->((a'+e)'=(a+e)''->a'+e'=(a+e)'')";
  794.          "a'+e=(a+e)'->(a'+e)'=(a+e)''->a'+e'=(a+e)''";
  795.          "(a'+e=(a+e)'->(a'+e)'=(a+e)'')->(a'+e=(a+e)'->(a'+e)'=(a+e)''->a'+e'=(a+e)'')->(a'+e=(a+e)'->a'+e'=(a+e)'')";
  796.          "(a'+e=(a+e)'->(a'+e)'=(a+e)''->a'+e'=(a+e)'')->(a'+e=(a+e)'->a'+e'=(a+e)'')";
  797.          "a'+e=(a+e)'->a'+e'=(a+e)''";
  798.          "@a.@b.(a=b->b=a)->@b.(a'+e'=b->b=a'+e')";
  799.          "@b.(a'+e'=b->b=a'+e')";
  800.          "@b.(a'+e'=b->b=a'+e')->(a'+e'=(a+e)''->(a+e)''=a'+e')";
  801.          "a'+e'=(a+e)''->(a+e)''=a'+e'";
  802.          "(a'+e'=(a+e)''->(a+e)''=a'+e')->(a'+e=(a+e)')->(a'+e'=(a+e)''->(a+e)''=a'+e')";
  803.          "a'+e=(a+e)'->a'+e'=(a+e)''->(a+e)''=a'+e'";
  804.          "(a'+e=(a+e)'->a'+e'=(a+e)'')->(a'+e=(a+e)'->a'+e'=(a+e)''->(a+e)''=a'+e')->(a'+e=(a+e)'->(a+e)''=a'+e')";
  805.          "(a'+e=(a+e)'->a'+e'=(a+e)''->(a+e)''=a'+e')->(a'+e=(a+e)'->(a+e)''=a'+e')";
  806.          "a'+e=(a+e)'->(a+e)''=a'+e'";
  807.          "@a.@b.(a+b'=(a+b)')";
  808.          "@a.@b.(a+b'=(a+b)')->@b.(a+b'=(a+b)')";
  809.          "@b.(a+b'=(a+b)')";
  810.          "@b.(a+b'=(a+b)')->a+e'=(a+e)'";
  811.          "a+e'=(a+e)'";
  812.          "@a.@b.(a=b->a'=b')->@b.(a+e'=b->(a+e')'=b')";
  813.          "@b.(a+e'=b->(a+e')'=b')";
  814.          "@b.(a+e'=b->(a+e')'=b')->(a+e'=(a+e)'->(a+e')'=(a+e)'')";
  815.          "a+e'=(a+e)'->(a+e')'=(a+e)''";
  816.          "(a+e')'=(a+e)''";
  817.          "@a.@b.(a=b->b=a)->@b.((a+e')'=b->b=(a+e')')";
  818.          "@b.((a+e')'=b->b=(a+e')')";
  819.          "@b.((a+e')'=b->b=(a+e')')->((a+e')'=(a+e)''->(a+e)''=(a+e')')";
  820.          "(a+e')'=(a+e)''->(a+e)''=(a+e')'";
  821.          "(a+e)''=(a+e')'";
  822.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.((a+e)''=b->(a+e)''=c->b=c)";
  823.          "@b.@c.((a+e)''=b->(a+e)''=c->b=c)";
  824.          "@b.@c.((a+e)''=b->(a+e)''=c->b=c)->@c.((a+e)''=a'+e'->(a+e)''=c->a'+e'=c)";
  825.          "@c.((a+e)''=a'+e'->(a+e)''=c->a'+e'=c)";
  826.          "@c.((a+e)''=a'+e'->(a+e)''=c->a'+e'=c)->((a+e)''=a'+e'->(a+e)''=(a+e')'->a'+e'=(a+e')')";
  827.          "(a+e)''=a'+e'->(a+e)''=(a+e')'->a'+e'=(a+e')'";
  828.          "((a+e)''=a'+e'->(a+e)''=(a+e')'->a'+e'=(a+e')')->(a'+e=(a+e)')->((a+e)''=a'+e'->(a+e)''=(a+e')'->a'+e'=(a+e')')";
  829.          "(a'+e=(a+e)')->((a+e)''=a'+e'->(a+e)''=(a+e')'->a'+e'=(a+e')')";
  830.          "a'+e=(a+e)'->(a+e)''=a'+e'->(a+e)''=(a+e')'->a'+e'=(a+e')'";
  831.          "(a'+e=(a+e)'->(a+e)''=a'+e')->(a'+e=(a+e)'->(a+e)''=a'+e'->(a+e)''=(a+e')'->a'+e'=(a+e')')->(a'+e=(a+e)'->(a+e)''=(a+e')'->a'+e'=(a+e')')";
  832.          "(a'+e=(a+e)'->(a+e)''=a'+e'->(a+e)''=(a+e')'->a'+e'=(a+e')')->(a'+e=(a+e)'->(a+e)''=(a+e')'->a'+e'=(a+e')')";
  833.          "a'+e=(a+e)'->(a+e)''=(a+e')'->a'+e'=(a+e')'";
  834.          "(a+e)''=(a+e')'->a'+e=(a+e)'->(a+e)''=(a+e')'";
  835.          "a'+e=(a+e)'->(a+e)''=(a+e')'";
  836.          "(a'+e=(a+e)'->(a+e)''=(a+e')')->(a'+e=(a+e)'->(a+e)''=(a+e')'->a'+e'=(a+e')')->(a'+e=(a+e)'->a'+e'=(a+e')')";
  837.          "(a'+e=(a+e)'->(a+e)''=(a+e')'->a'+e'=(a+e')')->(a'+e=(a+e)'->a'+e'=(a+e')')";
  838.          "a'+e=(a+e)'->a'+e'=(a+e')'";
  839.          "(a'+e=(a+e)'->a'+e'=(a+e')')->0=0->(a'+e=(a+e)'->a'+e'=(a+e')')";
  840.          "0=0->(a'+e=(a+e)'->a'+e'=(a+e')')";
  841.          "0=0->@e.(a'+e=(a+e)'->a'+e'=(a+e')')";
  842.          "@e.(a'+e=(a+e)'->a'+e'=(a+e')')";
  843.          "a+0=a->0=0->a+0=a";
  844.          "0=0->a+0=a";
  845.          "0=0->@a.(a+0=a)";
  846.          "@a.(a+0=a)";
  847.          "@a.(a+0=a)->(a'+0=a')";
  848.          "a'+0=a'";
  849.          "@a.@b.(a=b->a'=b')->@b.(a+0=b->(a+0)'=b')";
  850.          "@b.(a+0=b->(a+0)'=b')";
  851.          "@b.(a+0=b->(a+0)'=b')->(a+0=a->(a+0)'=a')";
  852.          "a+0=a->(a+0)'=a'";
  853.          "(a+0)'=a'";
  854.          "@a.@b.(a=b->b=a)->@b.(a'+0=b->b=a'+0)";
  855.          "@b.(a'+0=b->b=a'+0)";
  856.          "@b.(a'+0=b->b=a'+0)->(a'+0=a'->a'=a'+0)";
  857.          "a'+0=a'->a'=a'+0";
  858.          "a'=a'+0";
  859.          "@a.@b.(a=b->b=a)->@b.((a+0)'=b->b=(a+0)')";
  860.          "@b.((a+0)'=b->b=(a+0)')";
  861.          "@b.((a+0)'=b->b=(a+0)')->((a+0)'=a'->a'=(a+0)')";
  862.          "(a+0)'=a'->a'=(a+0)'";
  863.          "a'=(a+0)'";
  864.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(a'=b->a'=c->b=c)";
  865.          "@b.@c.(a'=b->a'=c->b=c)";
  866.          "@b.@c.(a'=b->a'=c->b=c)->@c.(a'=a'+0->a'=c->a'+0=c)";
  867.          "@c.(a'=a'+0->a'=c->a'+0=c)";
  868.          "@c.(a'=a'+0->a'=c->a'+0=c)->(a'=a'+0->a'=(a+0)'->a'+0=(a+0)')";
  869.          "a'=a'+0->a'=(a+0)'->a'+0=(a+0)'";
  870.          "a'=(a+0)'->a'+0=(a+0)'";
  871.          "a'+0=(a+0)'";
  872.          "a'+0=(a+0)'->@e.(a'+e=(a+e)'->a'+e'=(a+e')')->a'+0=(a+0)'&@e.(a'+e=(a+e)'->a'+e'=(a+e')')";
  873.          "@e.(a'+e=(a+e)'->a'+e'=(a+e')')->a'+0=(a+0)'&@e.(a'+e=(a+e)'->a'+e'=(a+e')')";
  874.          "a'+0=(a+0)'&@e.(a'+e=(a+e)'->a'+e'=(a+e')')";
  875.          "a'+0=(a+0)'&@e.(a'+e=(a+e)'->a'+e'=(a+e')')->(a'+e=(a+e)')";
  876.          "a'+e=(a+e)'";
  877.          "(a'+e=(a+e)')->0=0->(a'+e=(a+e)')";
  878.          "0=0->(a'+e=(a+e)')";
  879.          "0=0->@e.(a'+e=(a+e)')";
  880.          "0=0->@a.@e.(a'+e=(a+e)')";
  881.          "@a.@e.(a'+e=(a+e)')";
  882.          "@a.@e.(a'+e=(a+e)')->@e.(a'+e=(a+e)')";
  883.          "@e.(a'+e=(a+e)')";
  884.          "@e.(a'+e=(a+e)')->(a'+b=(a+b)')";
  885.          "a'+b=(a+b)'";
  886.          "a'+b=(a+b)'->0=0->a'+b=(a+b)'";
  887.          "0=0->a'+b=(a+b)'";
  888.          "0=0->@b.(a'+b=(a+b)')";
  889.          "0=0->@a.@b.(a'+b=(a+b)')";
  890.          "@a.@b.(a'+b=(a+b)')"];;
  891. let zeroPlusAEqA = a'pbEqapb' @
  892.         ["@a.(a+0=a)->(0+0=0)";
  893.          "0+0=0";
  894.          "@a.@b.(a=b->a'=b')->@b.(0+a=b->(0+a)'=b')";
  895.          "@b.(0+a=b->(0+a)'=b')";
  896.          "@b.(0+a=b->(0+a)'=b')->(0+a=a->(0+a)'=a')";
  897.          "0+a=a->(0+a)'=a'";
  898.          "@a.@b.(a+b'=(a+b)')->@b.(0+b'=(0+b)')";
  899.          "@b.(0+b'=(0+b)')";
  900.          "@b.(0+b'=(0+b)')->(0+a'=(0+a)')";
  901.          "0+a'=(0+a)'";
  902.          "@a.@b.(a=b->b=a)->@b.(0+a'=b->b=0+a')";
  903.          "@b.(0+a'=b->b=0+a')";
  904.          "@b.(0+a'=b->b=0+a')->(0+a'=(0+a)'->(0+a)'=0+a')";
  905.          "0+a'=(0+a)'->(0+a)'=0+a'";
  906.          "(0+a)'=0+a'";
  907.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.((0+a)'=b->(0+a)'=c->b=c)";
  908.          "@b.@c.((0+a)'=b->(0+a)'=c->b=c)";
  909.          "@b.@c.((0+a)'=b->(0+a)'=c->b=c)->@c.((0+a)'=0+a'->(0+a)'=c->0+a'=c)";
  910.          "@c.((0+a)'=0+a'->(0+a)'=c->0+a'=c)";
  911.          "@c.((0+a)'=0+a'->(0+a)'=c->0+a'=c)->((0+a)'=0+a'->(0+a)'=a'->0+a'=a')";
  912.          "(0+a)'=0+a'->(0+a)'=a'->0+a'=a'";
  913.          "(0+a)'=a'->0+a'=a'";
  914.          "((0+a)'=a'->0+a'=a')->0+a=a->((0+a)'=a'->0+a'=a')";
  915.          "0+a=a->(0+a)'=a'->0+a'=a'";
  916.          "(0+a=a->(0+a)'=a')->(0+a=a->(0+a)'=a'->0+a'=a')->(0+a=a->0+a'=a')";
  917.          "(0+a=a->(0+a)'=a'->0+a'=a')->(0+a=a->0+a'=a')";
  918.          "0+a=a->0+a'=a'";
  919.          "(0+a=a->0+a'=a')->0=0->(0+a=a->0+a'=a')";
  920.          "0=0->(0+a=a->0+a'=a')";
  921.          "0=0->@a.(0+a=a->0+a'=a')";
  922.          "@a.(0+a=a->0+a'=a')";
  923.          "(0+0=0)->@a.(0+a=a->0+a'=a')->(0+0=0)&@a.(0+a=a->0+a'=a')";
  924.          "@a.(0+a=a->0+a'=a')->(0+0=0)&@a.(0+a=a->0+a'=a')";
  925.          "(0+0=0)&@a.(0+a=a->0+a'=a')";
  926.          "(0+0=0)&@a.(0+a=a->0+a'=a')->0+a=a";
  927.          "0+a=a";
  928.          "0+a=a->0=0->0+a=a";
  929.          "0=0->0+a=a";
  930.          "0=0->@a.(0+a=a)";
  931.          "@a.(0+a=a)"];;
  932. let helpful = zeroPlusAEqA @
  933.         ["(a=b->a=c->b=c)->b=a->a=b->a=c->b=c";
  934.          "b=a->a=b->a=c->b=c";
  935.          "@a.@b.(a=b->b=a)->@b.(d=b->b=d)";
  936.          "@b.(d=b->b=d)";
  937.          "@b.(d=b->b=d)->(d=e->e=d)";
  938.          "d=e->e=d";
  939.          "(d=e->e=d)->0=0->(d=e->e=d)";
  940.          "0=0->(d=e->e=d)";
  941.          "0=0->@e.(d=e->e=d)";
  942.          "0=0->@d.@e.(d=e->e=d)";
  943.          "@d.@e.(d=e->e=d)";
  944.          "@d.@e.(d=e->e=d)->@e.(b=e->e=b)";
  945.          "@e.(b=e->e=b)";
  946.          "@e.(b=e->e=b)->(b=a->a=b)";
  947.          "b=a->a=b";
  948.          "(b=a->a=b)->(b=a->a=b->a=c->b=c)->(b=a->a=c->b=c)";
  949.          "(b=a->a=b->a=c->b=c)->(b=a->a=c->b=c)";
  950.          "b=a->a=c->b=c";
  951.          "(b=a->a=c->b=c)->0=0->(b=a->a=c->b=c)";
  952.          "0=0->(b=a->a=c->b=c)";
  953.          "0=0->@c.(b=a->a=c->b=c)";
  954.          "0=0->@b.@c.(b=a->a=c->b=c)";
  955.          "0=0->@a.@b.@c.(b=a->a=c->b=c)";
  956.          "@a.@b.@c.(b=a->a=c->b=c)";
  957.          "@a.@b.(a=b->b=a)->@b.(c=b->b=c)";
  958.          "@b.(c=b->b=c)";
  959.          "@b.(c=b->b=c)->(c=a->a=c)";
  960.          "c=a->a=c";
  961.          "(a=c->b=c)->c=a->(a=c->b=c)";
  962.          "((a=c->b=c)->c=a->(a=c->b=c))->b=a->((a=c->b=c)->c=a->(a=c->b=c))";
  963.          "b=a->(a=c->b=c)->c=a->(a=c->b=c)";
  964.          "(b=a->a=c->b=c)->(b=a->(a=c->b=c)->(c=a->a=c->b=c))->(b=a->c=a->a=c->b=c)";
  965.          "(b=a->(a=c->b=c)->(c=a->a=c->b=c))->(b=a->c=a->a=c->b=c)";
  966.          "b=a->c=a->a=c->b=c";
  967.          "(c=a->a=c)->(c=a->a=c->b=c)->(c=a->b=c)";
  968.          "((c=a->a=c)->(c=a->a=c->b=c)->(c=a->b=c))->b=a->((c=a->a=c)->(c=a->a=c->b=c)->(c=a->b=c))";
  969.          "b=a->(c=a->a=c)->(c=a->a=c->b=c)->(c=a->b=c)";
  970.          "(c=a->a=c)->b=a->(c=a->a=c)";
  971.          "b=a->c=a->a=c";
  972.          "(b=a->c=a->a=c)->(b=a->(c=a->a=c)->(c=a->a=c->b=c)->(c=a->b=c))->(b=a->(c=a->a=c->b=c)->(c=a->b=c))";
  973.          "(b=a->(c=a->a=c)->(c=a->a=c->b=c)->(c=a->b=c))->(b=a->(c=a->a=c->b=c)->(c=a->b=c))";
  974.          "b=a->(c=a->a=c->b=c)->(c=a->b=c)";
  975.          "(b=a->c=a->a=c->b=c)->(b=a->(c=a->a=c->b=c)->(c=a->b=c))->(b=a->c=a->b=c)";
  976.          "(b=a->(c=a->a=c->b=c)->(c=a->b=c))->(b=a->c=a->b=c)";
  977.          "b=a->c=a->b=c";
  978.          "(b=a->c=a->b=c)->0=0->(b=a->c=a->b=c)";
  979.          "0=0->(b=a->c=a->b=c)";
  980.          "0=0->@c.(b=a->c=a->b=c)";
  981.          "0=0->@b.@c.(b=a->c=a->b=c)";
  982.          "0=0->@a.@b.@c.(b=a->c=a->b=c)";
  983.          "@a.@b.@c.(b=a->c=a->b=c)"];;
  984. let commutativity2 = helpful @
  985.         ["@a.@b.(a=b->b=a)->@b.(0+a=b->b=0+a)";
  986.          "@b.(0+a=b->b=0+a)";
  987.          "@b.(0+a=b->b=0+a)->(0+a=a->a=0+a)";
  988.          "0+a=a->a=0+a";
  989.          "a=0+a";
  990.          "@a.@b.(a=b->b=a)->@b.(a+0=b->b=a+0)";
  991.          "@b.(a+0=b->b=a+0)";
  992.          "@b.(a+0=b->b=a+0)->(a+0=a->a=a+0)";
  993.          "a+0=a->a=a+0";
  994.          "a=a+0";
  995.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(a=b->a=c->b=c)";
  996.          "@b.@c.(a=b->a=c->b=c)";
  997.          "@b.@c.(a=b->a=c->b=c)->@c.(a=a+0->a=c->a+0=c)";
  998.          "@c.(a=a+0->a=c->a+0=c)";
  999.          "@c.(a=a+0->a=c->a+0=c)->(a=a+0->a=0+a->a+0=0+a)";
  1000.          "a=a+0->a=0+a->a+0=0+a";
  1001.          "a=0+a->a+0=0+a";
  1002.          "a+0=0+a";
  1003.          "@a.@b.(a=b->a'=b')->@b.(a+e=b->(a+e)'=b')";
  1004.          "@b.(a+e=b->(a+e)'=b')";
  1005.          "@b.(a+e=b->(a+e)'=b')->(a+e=e+a->(a+e)'=(e+a)')";
  1006.          "a+e=e+a->(a+e)'=(e+a)'";
  1007.          "@a.@b.(a=b->b=a)->@b.(a'+e=b->b=a'+e)";
  1008.          "@b.(a'+e=b->b=a'+e)";
  1009.          "@b.(a'+e=b->b=a'+e)->(a'+e=(a+e)'->(a+e)'=a'+e)";
  1010.          "a'+e=(a+e)'->(a+e)'=a'+e";
  1011.          "(a+e)'=a'+e";
  1012.          "((a+e)'=a'+e)->0=0->((a+e)'=a'+e)";
  1013.          "0=0->((a+e)'=a'+e)";
  1014.          "0=0->@e.((a+e)'=a'+e)";
  1015.          "0=0->@a.@e.((a+e)'=a'+e)";
  1016.          "@a.@e.((a+e)'=a'+e)";
  1017.          "@a.@e.((a+e)'=a'+e)->@e.((b+e)'=b'+e)";
  1018.          "@e.((b+e)'=b'+e)";
  1019.          "@e.((b+e)'=b'+e)->(b+a)'=b'+a";
  1020.          "(b+a)'=b'+a";
  1021.          "(b+a)'=b'+a->0=0->(b+a)'=b'+a";
  1022.          "0=0->(b+a)'=b'+a";
  1023.          "0=0->@b.((b+a)'=b'+a)";
  1024.          "@b.((b+a)'=b'+a)";
  1025.          "@b.((b+a)'=b'+a)->(e+a)'=e'+a";
  1026.          "(e+a)'=e'+a";
  1027.          "@a.@b.(a=b->b=a)->@b.(a+e'=b->b=a+e')";
  1028.          "@b.(a+e'=b->b=a+e')";
  1029.          "@b.(a+e'=b->b=a+e')->(a+e'=(a+e)'->(a+e)'=a+e')";
  1030.          "a+e'=(a+e)'->(a+e)'=a+e'";
  1031.          "@a.@b.(a+b'=(a+b)')->@b.(a+b'=(a+b)')";
  1032.          "@b.(a+b'=(a+b)')";
  1033.          "@b.(a+b'=(a+b)')->a+e'=(a+e)'";
  1034.          "a+e'=(a+e)'";
  1035.          "(a+e)'=a+e'";
  1036.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.((a+e)'=b->(a+e)'=c->b=c)";
  1037.          "@b.@c.((a+e)'=b->(a+e)'=c->b=c)";
  1038.          "@b.@c.((a+e)'=b->(a+e)'=c->b=c)->@c.((a+e)'=a+e'->(a+e)'=c->a+e'=c)";
  1039.          "@c.((a+e)'=a+e'->(a+e)'=c->a+e'=c)";
  1040.          "@c.((a+e)'=a+e'->(a+e)'=c->a+e'=c)->((a+e)'=a+e'->(a+e)'=(e+a)'->a+e'=(e+a)')";
  1041.          "(a+e)'=a+e'->(a+e)'=(e+a)'->a+e'=(e+a)'";
  1042.          "(a+e)'=(e+a)'->a+e'=(e+a)'";
  1043.          "((a+e)'=(e+a)'->a+e'=(e+a)')->a+e=e+a->((a+e)'=(e+a)'->a+e'=(e+a)')";
  1044.          "a+e=e+a->(a+e)'=(e+a)'->a+e'=(e+a)'";
  1045.          "(a+e=e+a->(a+e)'=(e+a)')->(a+e=e+a->(a+e)'=(e+a)'->a+e'=(e+a)')->(a+e=e+a->a+e'=(e+a)')";
  1046.          "(a+e=e+a->(a+e)'=(e+a)'->a+e'=(e+a)')->(a+e=e+a->a+e'=(e+a)')";
  1047.          "a+e=e+a->a+e'=(e+a)'";
  1048.          "@a.@b.(a=b->b=a)->@b.(a+e'=b->b=a+e')";
  1049.          "@b.(a+e'=b->b=a+e')";
  1050.          "@b.(a+e'=b->b=a+e')->(a+e'=(e+a)'->(e+a)'=a+e')";
  1051.          "a+e'=(e+a)'->(e+a)'=a+e'";
  1052.          "(a+e'=(e+a)'->(e+a)'=a+e')->a+e=e+a->(a+e'=(e+a)'->(e+a)'=a+e')";
  1053.          "a+e=e+a->a+e'=(e+a)'->(e+a)'=a+e'";
  1054.          "(a+e=e+a->a+e'=(e+a)')->(a+e=e+a->a+e'=(e+a)'->(e+a)'=a+e')->(a+e=e+a->(e+a)'=a+e')";
  1055.          "(a+e=e+a->a+e'=(e+a)'->(e+a)'=a+e')->(a+e=e+a->(e+a)'=a+e')";
  1056.          "a+e=e+a->(e+a)'=a+e'";
  1057.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.((e+a)'=b->(e+a)'=c->b=c)";
  1058.          "@b.@c.((e+a)'=b->(e+a)'=c->b=c)";
  1059.          "@b.@c.((e+a)'=b->(e+a)'=c->b=c)->@c.((e+a)'=a+e'->(e+a)'=c->a+e'=c)";
  1060.          "@c.((e+a)'=a+e'->(e+a)'=c->a+e'=c)";
  1061.          "@c.((e+a)'=a+e'->(e+a)'=c->a+e'=c)->((e+a)'=a+e'->(e+a)'=e'+a->a+e'=e'+a)";
  1062.          "(e+a)'=a+e'->(e+a)'=e'+a->a+e'=e'+a";
  1063.          "((e+a)'=a+e'->(e+a)'=e'+a->a+e'=e'+a)->(a+e=e+a)->((e+a)'=a+e'->(e+a)'=e'+a->a+e'=e'+a)";
  1064.          "a+e=e+a->(e+a)'=a+e'->(e+a)'=e'+a->a+e'=e'+a";
  1065.          "(a+e=e+a->(e+a)'=a+e')->(a+e=e+a->(e+a)'=a+e'->(e+a)'=e'+a->a+e'=e'+a)->(a+e=e+a->(e+a)'=e'+a->a+e'=e'+a)";
  1066.          "(a+e=e+a->(e+a)'=a+e'->(e+a)'=e'+a->a+e'=e'+a)->(a+e=e+a->(e+a)'=e'+a->a+e'=e'+a)";
  1067.          "a+e=e+a->(e+a)'=e'+a->a+e'=e'+a";
  1068.          "(e+a)'=e'+a->a+e=e+a->(e+a)'=e'+a";
  1069.          "a+e=e+a->(e+a)'=e'+a";
  1070.          "(a+e=e+a->(e+a)'=e'+a)->(a+e=e+a->(e+a)'=e'+a->a+e'=e'+a)->(a+e=e+a->a+e'=e'+a)";
  1071.          "(a+e=e+a->(e+a)'=e'+a->a+e'=e'+a)->(a+e=e+a->a+e'=e'+a)";
  1072.          "a+e=e+a->a+e'=e'+a";
  1073.          "(a+e=e+a->a+e'=e'+a)->0=0->(a+e=e+a->a+e'=e'+a)";
  1074.          "0=0->(a+e=e+a->a+e'=e'+a)";
  1075.          "0=0->@e.(a+e=e+a->a+e'=e'+a)";
  1076.          "@e.(a+e=e+a->a+e'=e'+a)";
  1077.          "a+0=0+a->@e.(a+e=e+a->a+e'=e'+a)->a+0=0+a&@e.(a+e=e+a->a+e'=e'+a)";
  1078.          "@e.(a+e=e+a->a+e'=e'+a)->a+0=0+a&@e.(a+e=e+a->a+e'=e'+a)";
  1079.          "a+0=0+a&@e.(a+e=e+a->a+e'=e'+a)";
  1080.          "a+0=0+a&@e.(a+e=e+a->a+e'=e'+a)->a+e=e+a";
  1081.          "a+e=e+a";
  1082.          "a+e=e+a->0=0->a+e=e+a";
  1083.          "0=0->a+e=e+a";
  1084.          "0=0->@e.(a+e=e+a)";
  1085.          "@e.(a+e=e+a)";
  1086.          "@e.(a+e=e+a)->a+b=b+a";
  1087.          "a+b=b+a";
  1088.          "a+b=b+a->0=0->a+b=b+a";
  1089.          "0=0->a+b=b+a";
  1090.          "0=0->@b.(a+b=b+a)";
  1091.          "0=0->@a.@b.(a+b=b+a)";
  1092.          "@a.@b.(a+b=b+a)";
  1093.          "0=0->@a.@e.(a+e=e+a)";
  1094.          "@a.@e.(a+e=e+a)"];;
  1095. let additionDoesntChangeEquality = commutativity2 @
  1096.         ["@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=a->a=c->b=c)";
  1097.          "@b.@c.(b=a->a=c->b=c)";
  1098.          "@b.@c.(b=a->a=c->b=c)->@c.(a+0=a->a=c->a+0=c)";
  1099.          "@c.(a+0=a->a=c->a+0=c)";
  1100.          "@c.(a+0=a->a=c->a+0=c)->(a+0=a->a=d->a+0=d)";
  1101.          "a+0=a->a=d->a+0=d";
  1102.          "a=d->a+0=d";
  1103.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=d->c=d->b=c)";
  1104.          "@b.@c.(b=d->c=d->b=c)";
  1105.          "@b.@c.(b=d->c=d->b=c)->@c.(d+0=d->c=d->d+0=c)";
  1106.          "@c.(d+0=d->c=d->d+0=c)";
  1107.          "@c.(d+0=d->c=d->d+0=c)->(d+0=d->a+0=d->d+0=a+0)";
  1108.          "d+0=d->a+0=d->d+0=a+0";
  1109.          "@a.(a+0=a)->(d+0=d)";
  1110.          "d+0=d";
  1111.          "a+0=d->d+0=a+0";
  1112.          "(a+0=d->d+0=a+0)->a=d->(a+0=d->d+0=a+0)";
  1113.          "a=d->a+0=d->d+0=a+0";
  1114.          "(a=d->a+0=d)->(a=d->a+0=d->d+0=a+0)->(a=d->d+0=a+0)";
  1115.          "(a=d->a+0=d->d+0=a+0)->(a=d->d+0=a+0)";
  1116.          "a=d->d+0=a+0";
  1117.          "@a.@b.(a=b->b=a)->@b.(d+0=b->b=d+0)";
  1118.          "@b.(d+0=b->b=d+0)";
  1119.          "@b.(d+0=b->b=d+0)->(d+0=a+0->a+0=d+0)";
  1120.          "d+0=a+0->a+0=d+0";
  1121.          "(d+0=a+0->a+0=d+0)->a=d->(d+0=a+0->a+0=d+0)";
  1122.          "a=d->d+0=a+0->a+0=d+0";
  1123.          "(a=d->d+0=a+0)->(a=d->d+0=a+0->a+0=d+0)->(a=d->a+0=d+0)";
  1124.          "(a=d->d+0=a+0->a+0=d+0)->(a=d->a+0=d+0)";
  1125.          "a=d->a+0=d+0";
  1126.          "@a.@b.(a=b->a'=b')->@b.(a+e=b->(a+e)'=b')";
  1127.          "@b.(a+e=b->(a+e)'=b')";
  1128.          "@b.(a+e=b->(a+e)'=b')->(a+e=d+e->(a+e)'=(d+e)')";
  1129.          "a+e=d+e->(a+e)'=(d+e)'";
  1130.          "@a.@b.(a+b'=(a+b)')->@b.(a+b'=(a+b)')";
  1131.          "@b.(a+b'=(a+b)')";
  1132.          "@b.(a+b'=(a+b)')->a+e'=(a+e)'";
  1133.          "a+e'=(a+e)'";
  1134.          "@a.@b.(a+b'=(a+b)')->@b.(d+b'=(d+b)')";
  1135.          "@b.(d+b'=(d+b)')";
  1136.          "@b.(d+b'=(d+b)')->d+e'=(d+e)'";
  1137.          "d+e'=(d+e)'";
  1138.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(a+e)'->(a+e)'=c->b=c)";
  1139.          "@b.@c.(b=(a+e)'->(a+e)'=c->b=c)";
  1140.          "@b.@c.(b=(a+e)'->(a+e)'=c->b=c)->@c.(a+e'=(a+e)'->(a+e)'=c->a+e'=c)";
  1141.          "@c.(a+e'=(a+e)'->(a+e)'=c->a+e'=c)";
  1142.          "@c.(a+e'=(a+e)'->(a+e)'=c->a+e'=c)->(a+e'=(a+e)'->(a+e)'=(d+e)'->a+e'=(d+e)')";
  1143.          "a+e'=(a+e)'->(a+e)'=(d+e)'->a+e'=(d+e)'";
  1144.          "(a+e)'=(d+e)'->a+e'=(d+e)'";
  1145.          "((a+e)'=(d+e)'->a+e'=(d+e)')->a+e=d+e->((a+e)'=(d+e)'->a+e'=(d+e)')";
  1146.          "a+e=d+e->(a+e)'=(d+e)'->a+e'=(d+e)'";
  1147.          "(a+e=d+e->(a+e)'=(d+e)')->(a+e=d+e->(a+e)'=(d+e)'->a+e'=(d+e)')->(a+e=d+e->a+e'=(d+e)')";
  1148.          "(a+e=d+e->(a+e)'=(d+e)'->a+e'=(d+e)')->(a+e=d+e->a+e'=(d+e)')";
  1149.          "a+e=d+e->a+e'=(d+e)'";
  1150.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=(d+e)'->c=(d+e)'->b=c)";
  1151.          "@b.@c.(b=(d+e)'->c=(d+e)'->b=c)";
  1152.          "@b.@c.(b=(d+e)'->c=(d+e)'->b=c)->@c.(d+e'=(d+e)'->c=(d+e)'->d+e'=c)";
  1153.          "@c.(d+e'=(d+e)'->c=(d+e)'->d+e'=c)";
  1154.          "@c.(d+e'=(d+e)'->c=(d+e)'->d+e'=c)->(d+e'=(d+e)'->a+e'=(d+e)'->d+e'=a+e')";
  1155.          "d+e'=(d+e)'->a+e'=(d+e)'->d+e'=a+e'";
  1156.          "a+e'=(d+e)'->d+e'=a+e'";
  1157.          "(a+e'=(d+e)'->d+e'=a+e')->a+e=d+e->(a+e'=(d+e)'->d+e'=a+e')";
  1158.          "a+e=d+e->a+e'=(d+e)'->d+e'=a+e'";
  1159.          "(a+e=d+e->a+e'=(d+e)')->(a+e=d+e->a+e'=(d+e)'->d+e'=a+e')->(a+e=d+e->d+e'=a+e')";
  1160.          "(a+e=d+e->a+e'=(d+e)'->d+e'=a+e')->(a+e=d+e->d+e'=a+e')";
  1161.          "a+e=d+e->d+e'=a+e'";
  1162.          "@a.@b.(a=b->b=a)->@b.(d+e'=b->b=d+e')";
  1163.          "@b.(d+e'=b->b=d+e')";
  1164.          "@b.(d+e'=b->b=d+e')->(d+e'=a+e'->a+e'=d+e')";
  1165.          "d+e'=a+e'->a+e'=d+e'";
  1166.          "(d+e'=a+e'->a+e'=d+e')->a+e=d+e->(d+e'=a+e'->a+e'=d+e')";
  1167.          "a+e=d+e->d+e'=a+e'->a+e'=d+e'";
  1168.          "(a+e=d+e->d+e'=a+e')->(a+e=d+e->d+e'=a+e'->a+e'=d+e')->(a+e=d+e->a+e'=d+e')";
  1169.          "(a+e=d+e->d+e'=a+e'->a+e'=d+e')->(a+e=d+e->a+e'=d+e')";
  1170.          "a+e=d+e->a+e'=d+e'";
  1171.          "(a+e=d+e->a+e'=d+e')->a=d->(a+e=d+e->a+e'=d+e')";
  1172.          "a=d->(a+e=d+e->a+e'=d+e')";
  1173.          "(a=d->(a+e=d+e->a+e'=d+e'))->(a=d->a+e=d+e)->(a=d->(a+e=d+e->a+e'=d+e'))";
  1174.          "(a=d->a+e=d+e)->(a=d->a+e=d+e->a+e'=d+e')";
  1175.          "(a=d->a+e=d+e)->(a=d->a+e=d+e->a+e'=d+e')->(a=d->a+e'=d+e')";
  1176.          "((a=d->a+e=d+e)->(a=d->a+e=d+e->a+e'=d+e'))->((a=d->a+e=d+e)->(a=d->a+e=d+e->a+e'=d+e')->(a=d->a+e'=d+e'))->((a=d->a+e=d+e)->(a=d->a+e'=d+e'))";
  1177.          "((a=d->a+e=d+e)->(a=d->a+e=d+e->a+e'=d+e')->(a=d->a+e'=d+e'))->((a=d->a+e=d+e)->(a=d->a+e'=d+e'))";
  1178.          "(a=d->a+e=d+e)->(a=d->a+e'=d+e')";
  1179.          "((a=d->a+e=d+e)->(a=d->a+e'=d+e'))->0=0->((a=d->a+e=d+e)->(a=d->a+e'=d+e'))";
  1180.          "0=0->((a=d->a+e=d+e)->(a=d->a+e'=d+e'))";
  1181.          "0=0->@e.((a=d->a+e=d+e)->(a=d->a+e'=d+e'))";
  1182.          "@e.((a=d->a+e=d+e)->(a=d->a+e'=d+e'))";
  1183.          "(a=d->a+0=d+0)->@e.((a=d->a+e=d+e)->(a=d->a+e'=d+e'))->(a=d->a+0=d+0)&@e.((a=d->a+e=d+e)->(a=d->a+e'=d+e'))";
  1184.          "@e.((a=d->a+e=d+e)->(a=d->a+e'=d+e'))->(a=d->a+0=d+0)&@e.((a=d->a+e=d+e)->(a=d->a+e'=d+e'))";
  1185.          "(a=d->a+0=d+0)&@e.((a=d->a+e=d+e)->(a=d->a+e'=d+e'))";
  1186.          "(a=d->a+0=d+0)&@e.((a=d->a+e=d+e)->(a=d->a+e'=d+e'))->a=d->a+e=d+e";
  1187.          "a=d->a+e=d+e";
  1188.          "(a=d->a+e=d+e)->0=0->(a=d->a+e=d+e)";
  1189.          "0=0->(a=d->a+e=d+e)";
  1190.          "0=0->@e.(a=d->a+e=d+e)";
  1191.          "0=0->@d.@e.(a=d->a+e=d+e)";
  1192.          "0=0->@a.@d.@e.(a=d->a+e=d+e)";
  1193.          "@a.@d.@e.(a=d->a+e=d+e)";
  1194.          "@a.@d.@e.(a=d->a+e=d+e)->@d.@e.(a=d->a+e=d+e)";
  1195.          "@d.@e.(a=d->a+e=d+e)";
  1196.          "@d.@e.(a=d->a+e=d+e)->@e.(a=b->a+e=b+e)";
  1197.          "@e.(a=b->a+e=b+e)";
  1198.          "@e.(a=b->a+e=b+e)->(a=b->a+c=b+c)";
  1199.          "a=b->a+c=b+c";
  1200.          "(a=b->a+c=b+c)->0=0->(a=b->a+c=b+c)";
  1201.          "0=0->(a=b->a+c=b+c)";
  1202.          "0=0->@c.(a=b->a+c=b+c)";
  1203.          "0=0->@b.@c.(a=b->a+c=b+c)";
  1204.          "0=0->@a.@b.@c.(a=b->a+c=b+c)";
  1205.          "@a.@b.@c.(a=b->a+c=b+c)";
  1206.          "@a.@e.(a+e=e+a)->@e.(d+e=e+d)";
  1207.          "@e.(d+e=e+d)";
  1208.          "@e.(d+e=e+d)->(d+e=e+d)";
  1209.          "d+e=e+d";
  1210.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(a+e=b->a+e=c->b=c)";
  1211.          "@b.@c.(a+e=b->a+e=c->b=c)";
  1212.          "@b.@c.(a+e=b->a+e=c->b=c)->@c.(a+e=e+a->a+e=c->e+a=c)";
  1213.          "@c.(a+e=e+a->a+e=c->e+a=c)";
  1214.          "@c.(a+e=e+a->a+e=c->e+a=c)->(a+e=e+a->a+e=d+e->e+a=d+e)";
  1215.          "a+e=e+a->a+e=d+e->e+a=d+e";
  1216.          "a+e=d+e->e+a=d+e";
  1217.          "(a+e=d+e->e+a=d+e)->a=d->a+e=d+e->e+a=d+e";
  1218.          "a=d->a+e=d+e->e+a=d+e";
  1219.          "(a=d->a+e=d+e)->(a=d->a+e=d+e->e+a=d+e)->(a=d->e+a=d+e)";
  1220.          "(a=d->a+e=d+e->e+a=d+e)->(a=d->e+a=d+e)";
  1221.          "a=d->e+a=d+e";
  1222.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=d+e->d+e=c->b=c)";
  1223.          "@b.@c.(b=d+e->d+e=c->b=c)";
  1224.          "@b.@c.(b=d+e->d+e=c->b=c)->@c.(e+a=d+e->d+e=c->e+a=c)";
  1225.          "@c.(e+a=d+e->d+e=c->e+a=c)";
  1226.          "@c.(e+a=d+e->d+e=c->e+a=c)->(e+a=d+e->d+e=e+d->e+a=e+d)";
  1227.          "e+a=d+e->d+e=e+d->e+a=e+d";
  1228.          "d+e=e+d->e+a=d+e->d+e=e+d";
  1229.          "e+a=d+e->d+e=e+d";
  1230.          "(e+a=d+e->d+e=e+d)->(e+a=d+e->d+e=e+d->e+a=e+d)->(e+a=d+e->e+a=e+d)";
  1231.          "(e+a=d+e->d+e=e+d->e+a=e+d)->(e+a=d+e->e+a=e+d)";
  1232.          "e+a=d+e->e+a=e+d";
  1233.          "(e+a=d+e->e+a=e+d)->a=d->e+a=d+e->e+a=e+d";
  1234.          "a=d->e+a=d+e->e+a=e+d";
  1235.          "(a=d->e+a=d+e)->(a=d->e+a=d+e->e+a=e+d)->(a=d->e+a=e+d)";
  1236.          "(a=d->e+a=d+e->e+a=e+d)->(a=d->e+a=e+d)";
  1237.          "a=d->e+a=e+d";
  1238.          "(a=d->e+a=e+d)->0=0->(a=d->e+a=e+d)";
  1239.          "0=0->(a=d->e+a=e+d)";
  1240.          "0=0->@e.(a=d->e+a=e+d)";
  1241.          "0=0->@d.@e.(a=d->e+a=e+d)";
  1242.          "0=0->@a.@d.@e.(a=d->e+a=e+d)";
  1243.          "@a.@d.@e.(a=d->e+a=e+d)";
  1244.          "@a.@d.@e.(a=d->e+a=e+d)->@d.@e.(a=d->e+a=e+d)";
  1245.          "@d.@e.(a=d->e+a=e+d)";
  1246.          "@d.@e.(a=d->e+a=e+d)->@e.(a=b->e+a=e+b)";
  1247.          "@e.(a=b->e+a=e+b)";
  1248.          "@e.(a=b->e+a=e+b)->(a=b->c+a=c+b)";
  1249.          "a=b->c+a=c+b";
  1250.          "(a=b->c+a=c+b)->0=0->(a=b->c+a=c+b)";
  1251.          "0=0->(a=b->c+a=c+b)";
  1252.          "0=0->@c.(a=b->c+a=c+b)";
  1253.          "0=0->@b.@c.(a=b->c+a=c+b)";
  1254.          "0=0->@a.@b.@c.(a=b->c+a=c+b)";
  1255.          "@a.@b.@c.(a=b->c+a=c+b)"];;
  1256. let associativity = additionDoesntChangeEquality @
  1257.         ["@a.@b.(a+b'=(a+b)')->@b.((a+d)+b'=((a+d)+b)')";
  1258.          "@b.((a+d)+b'=((a+d)+b)')";
  1259.          "@b.((a+d)+b'=((a+d)+b)')->(a+d)+e'=((a+d)+e)'";
  1260.          "(a+d)+e'=((a+d)+e)'";
  1261.          "@a.@b.(a+b'=(a+b)')->@b.(a+b'=(a+b)')";
  1262.          "@b.(a+b'=(a+b)')";
  1263.          "@b.(a+b'=(a+b)')->a+(d+e)'=(a+(d+e))'";
  1264.          "a+(d+e)'=(a+(d+e))'";
  1265.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=((a+d)+e)'->((a+d)+e)'=c->b=c)";
  1266.          "@b.@c.(b=((a+d)+e)'->((a+d)+e)'=c->b=c)";
  1267.          "@b.@c.(b=((a+d)+e)'->((a+d)+e)'=c->b=c)->@c.((a+d)+e'=((a+d)+e)'->((a+d)+e)'=c->(a+d)+e'=c)";
  1268.          "@c.((a+d)+e'=((a+d)+e)'->((a+d)+e)'=c->(a+d)+e'=c)";
  1269.          "@c.((a+d)+e'=((a+d)+e)'->((a+d)+e)'=c->(a+d)+e'=c)->((a+d)+e'=((a+d)+e)'->((a+d)+e)'=(a+(d+e))'->(a+d)+e'=(a+(d+e))')";
  1270.          "(a+d)+e'=((a+d)+e)'->((a+d)+e)'=(a+(d+e))'->(a+d)+e'=(a+(d+e))'";
  1271.          "((a+d)+e)'=(a+(d+e))'->(a+d)+e'=(a+(d+e))'";
  1272.          "@a.@b.(a+b'=(a+b)')->@b.(d+b'=(d+b)')";
  1273.          "@b.(d+b'=(d+b)')";
  1274.          "@b.(d+b'=(d+b)')->(d+e'=(d+e)')";
  1275.          "d+e'=(d+e)'";
  1276.          "@a.@b.@c.(a=b->c+a=c+b)->@b.@c.(d+e'=b->c+(d+e')=c+b)";
  1277.          "@b.@c.(d+e'=b->c+(d+e')=c+b)";
  1278.          "@b.@c.(d+e'=b->c+(d+e')=c+b)->@c.(d+e'=(d+e)'->c+(d+e')=c+(d+e)')";
  1279.          "@c.(d+e'=(d+e)'->c+(d+e')=c+(d+e)')";
  1280.          "@c.(d+e'=(d+e)'->c+(d+e')=c+(d+e)')->(d+e'=(d+e)'->a+(d+e')=a+(d+e)')";
  1281.          "d+e'=(d+e)'->a+(d+e')=a+(d+e)'";
  1282.          "a+(d+e')=a+(d+e)'";
  1283.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=a+(d+e)'->a+(d+e)'=c->b=c)";
  1284.          "@b.@c.(b=a+(d+e)'->a+(d+e)'=c->b=c)";
  1285.          "@b.@c.(b=a+(d+e)'->a+(d+e)'=c->b=c)->@c.(a+(d+e')=a+(d+e)'->a+(d+e)'=c->a+(d+e')=c)";
  1286.          "@c.(a+(d+e')=a+(d+e)'->a+(d+e)'=c->a+(d+e')=c)";
  1287.          "@c.(a+(d+e')=a+(d+e)'->a+(d+e)'=c->a+(d+e')=c)->(a+(d+e')=a+(d+e)'->a+(d+e)'=(a+(d+e))'->a+(d+e')=(a+(d+e))')";
  1288.          "a+(d+e')=a+(d+e)'->a+(d+e)'=(a+(d+e))'->a+(d+e')=(a+(d+e))'";
  1289.          "a+(d+e)'=(a+(d+e))'->a+(d+e')=(a+(d+e))'";
  1290.          "a+(d+e')=(a+(d+e))'";
  1291.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=(a+(d+e))'->c=(a+(d+e))'->b=c)";
  1292.          "@b.@c.(b=(a+(d+e))'->c=(a+(d+e))'->b=c)";
  1293.          "@b.@c.(b=(a+(d+e))'->c=(a+(d+e))'->b=c)->@c.((a+d)+e'=(a+(d+e))'->c=(a+(d+e))'->(a+d)+e'=c)";
  1294.          "@c.((a+d)+e'=(a+(d+e))'->c=(a+(d+e))'->(a+d)+e'=c)";
  1295.          "@c.((a+d)+e'=(a+(d+e))'->c=(a+(d+e))'->(a+d)+e'=c)->((a+d)+e'=(a+(d+e))'->a+(d+e')=(a+(d+e))'->(a+d)+e'=a+(d+e'))";
  1296.          "(a+d)+e'=(a+(d+e))'->a+(d+e')=(a+(d+e))'->(a+d)+e'=a+(d+e')";
  1297.          "a+(d+e')=(a+(d+e))'->(a+d)+e'=(a+(d+e))'->a+(d+e')=(a+(d+e))'";
  1298.          "(a+d)+e'=(a+(d+e))'->a+(d+e')=(a+(d+e))'";
  1299.          "((a+d)+e'=(a+(d+e))'->a+(d+e')=(a+(d+e))')->((a+d)+e'=(a+(d+e))'->a+(d+e')=(a+(d+e))'->(a+d)+e'=a+(d+e'))->((a+d)+e'=(a+(d+e))'->(a+d)+e'=a+(d+e'))";
  1300.          "((a+d)+e'=(a+(d+e))'->a+(d+e')=(a+(d+e))'->(a+d)+e'=a+(d+e'))->((a+d)+e'=(a+(d+e))'->(a+d)+e'=a+(d+e'))";
  1301.          "(a+d)+e'=(a+(d+e))'->(a+d)+e'=a+(d+e')";
  1302.          "((a+d)+e'=(a+(d+e))'->(a+d)+e'=a+(d+e'))->((a+d)+e)'=(a+(d+e))'->((a+d)+e'=(a+(d+e))'->(a+d)+e'=a+(d+e'))";
  1303.          "((a+d)+e)'=(a+(d+e))'->(a+d)+e'=(a+(d+e))'->(a+d)+e'=a+(d+e')";
  1304.          "(((a+d)+e)'=(a+(d+e))'->(a+d)+e'=(a+(d+e))')->(((a+d)+e)'=(a+(d+e))'->(a+d)+e'=(a+(d+e))'->(a+d)+e'=a+(d+e'))->(((a+d)+e)'=(a+(d+e))'->(a+d)+e'=a+(d+e'))";
  1305.          "(((a+d)+e)'=(a+(d+e))'->(a+d)+e'=(a+(d+e))'->(a+d)+e'=a+(d+e'))->(((a+d)+e)'=(a+(d+e))'->(a+d)+e'=a+(d+e'))";
  1306.          "((a+d)+e)'=(a+(d+e))'->(a+d)+e'=a+(d+e')";
  1307.          "(((a+d)+e)'=(a+(d+e))'->(a+d)+e'=a+(d+e'))->((a+d)+e=a+(d+e))->(((a+d)+e)'=(a+(d+e))'->(a+d)+e'=a+(d+e'))";
  1308.          "(a+d)+e=a+(d+e)->((a+d)+e)'=(a+(d+e))'->(a+d)+e'=a+(d+e')";
  1309.          "@a.@b.(a=b->a'=b')->@b.((a+d)+e=b->((a+d)+e)'=b')";
  1310.          "@b.((a+d)+e=b->((a+d)+e)'=b')";
  1311.          "@b.((a+d)+e=b->((a+d)+e)'=b')->((a+d)+e=a+(d+e)->((a+d)+e)'=(a+(d+e))')";
  1312.          "(a+d)+e=a+(d+e)->((a+d)+e)'=(a+(d+e))'";
  1313.          "((a+d)+e=a+(d+e)->((a+d)+e)'=(a+(d+e))')->((a+d)+e=a+(d+e)->((a+d)+e)'=(a+(d+e))'->(a+d)+e'=a+(d+e'))->((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))";
  1314.          "((a+d)+e=a+(d+e)->((a+d)+e)'=(a+(d+e))'->(a+d)+e'=a+(d+e'))->((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))";
  1315.          "(a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e')";
  1316.          "((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))->0=0->((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))";
  1317.          "0=0->((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))";
  1318.          "0=0->@e.((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))";
  1319.          "@e.((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))";
  1320.          "@a.(a+0=a)->((a+d)+0=a+d)";
  1321.          "(a+d)+0=a+d";
  1322.          "@a.(a+0=a)->(d+0=d)";
  1323.          "d+0=d";
  1324.          "@a.@b.@c.(a=b->c+a=c+b)->@b.@c.(d+0=b->c+(d+0)=c+b)";
  1325.          "@b.@c.(d+0=b->c+(d+0)=c+b)";
  1326.          "@b.@c.(d+0=b->c+(d+0)=c+b)->@c.(d+0=d->c+(d+0)=c+d)";
  1327.          "@c.(d+0=d->c+(d+0)=c+d)";
  1328.          "@c.(d+0=d->c+(d+0)=c+d)->(d+0=d->a+(d+0)=a+d)";
  1329.          "d+0=d->a+(d+0)=a+d";
  1330.          "a+(d+0)=a+d";
  1331.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=a+d->c=a+d->b=c)";
  1332.          "@b.@c.(b=a+d->c=a+d->b=c)";
  1333.          "@b.@c.(b=a+d->c=a+d->b=c)->@c.((a+d)+0=a+d->c=a+d->(a+d)+0=c)";
  1334.          "@c.((a+d)+0=a+d->c=a+d->(a+d)+0=c)";
  1335.          "@c.((a+d)+0=a+d->c=a+d->(a+d)+0=c)->((a+d)+0=a+d->a+(d+0)=a+d->(a+d)+0=a+(d+0))";
  1336.          "(a+d)+0=a+d->a+(d+0)=a+d->(a+d)+0=a+(d+0)";
  1337.          "a+(d+0)=a+d->(a+d)+0=a+(d+0)";
  1338.          "(a+d)+0=a+(d+0)";
  1339.          "(a+d)+0=a+(d+0)->@e.((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))->(a+d)+0=a+(d+0)&@e.((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))";
  1340.          "@e.((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))->(a+d)+0=a+(d+0)&@e.((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))";
  1341.          "(a+d)+0=a+(d+0)&@e.((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))";
  1342.          "(a+d)+0=a+(d+0)&@e.((a+d)+e=a+(d+e)->(a+d)+e'=a+(d+e'))->(a+d)+e=a+(d+e)";
  1343.          "(a+d)+e=a+(d+e)";
  1344.          "(a+d)+e=a+(d+e)->0=0->(a+d)+e=a+(d+e)";
  1345.          "0=0->(a+d)+e=a+(d+e)";
  1346.          "0=0->@e.((a+d)+e=a+(d+e))";
  1347.          "0=0->@d.@e.((a+d)+e=a+(d+e))";
  1348.          "0=0->@a.@d.@e.((a+d)+e=a+(d+e))";
  1349.          "@a.@d.@e.((a+d)+e=a+(d+e))";
  1350.          "@a.@d.@e.((a+d)+e=a+(d+e))";
  1351.          "@a.@d.@e.((a+d)+e=a+(d+e))->@d.@e.((a+d)+e=a+(d+e))";
  1352.          "@d.@e.((a+d)+e=a+(d+e))";
  1353.          "@d.@e.((a+d)+e=a+(d+e))->@e.((a+b)+e=a+(b+e))";
  1354.          "@e.((a+b)+e=a+(b+e))";
  1355.          "@e.((a+b)+e=a+(b+e))->((a+b)+c=a+(b+c))";
  1356.          "(a+b)+c=a+(b+c)";
  1357.          "(a+b)+c=a+(b+c)->0=0->(a+b)+c=a+(b+c)";
  1358.          "0=0->(a+b)+c=a+(b+c)";
  1359.          "0=0->@c.((a+b)+c=a+(b+c))";
  1360.          "0=0->@b.@c.((a+b)+c=a+(b+c))";
  1361.          "0=0->@a.@b.@c.((a+b)+c=a+(b+c))";
  1362.          "@a.@b.@c.((a+b)+c=a+(b+c))"];;
  1363. let e'aEqeaPa = associativity @
  1364.         ["a*b'=a*b+a";
  1365.          "a*b'=a*b+a->0=0->a*b'=a*b+a";
  1366.          "0=0->a*b'=a*b+a";
  1367.          "0=0->@b.(a*b'=a*b+a)";
  1368.          "0=0->@a.@b.(a*b'=a*b+a)";
  1369.          "@a.@b.(a*b'=a*b+a)";
  1370.          "@a.@b.(a*b'=a*b+a)->@b.(e*b'=e*b+e)";
  1371.          "@b.(e*b'=e*b+e)";
  1372.          "@b.(e*b'=e*b+e)->(e*a'=e*a+e)";
  1373.          "e*a'=e*a+e";
  1374.          "@a.@b.@c.(a=b->a+c=b+c)->@b.@c.(e*a'=b->e*a'+c=b+c)";
  1375.          "@b.@c.(e*a'=b->e*a'+c=b+c)";
  1376.          "@b.@c.(e*a'=b->e*a'+c=b+c)->@c.(e*a'=e*a+e->e*a'+c=(e*a+e)+c)";
  1377.          "@c.(e*a'=e*a+e->e*a'+c=(e*a+e)+c)";
  1378.          "@c.(e*a'=e*a+e->e*a'+c=(e*a+e)+c)->(e*a'=e*a+e->e*a'+a'=(e*a+e)+a')";
  1379.          "e*a'=e*a+e->e*a'+a'=(e*a+e)+a'";
  1380.          "e*a'+a'=(e*a+e)+a'";
  1381.          "@a.@b.@c.((a+b)+c=a+(b+c))->@b.@c.((e*a+b)+c=e*a+(b+c))";
  1382.          "@b.@c.((e*a+b)+c=e*a+(b+c))";
  1383.          "@b.@c.((e*a+b)+c=e*a+(b+c))->@c.((e*a+e)+c=e*a+(e+c))";
  1384.          "@c.((e*a+e)+c=e*a+(e+c))";
  1385.          "@c.((e*a+e)+c=e*a+(e+c))->(e*a+e)+a'=e*a+(e+a')";
  1386.          "(e*a+e)+a'=e*a+(e+a')";
  1387.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(e*a+e)+a'->(e*a+e)+a'=c->b=c)";
  1388.          "@b.@c.(b=(e*a+e)+a'->(e*a+e)+a'=c->b=c)";
  1389.          "@b.@c.(b=(e*a+e)+a'->(e*a+e)+a'=c->b=c)->@c.(e*a'+a'=(e*a+e)+a'->(e*a+e)+a'=c->e*a'+a'=c)";
  1390.          "@c.(e*a'+a'=(e*a+e)+a'->(e*a+e)+a'=c->e*a'+a'=c)";
  1391.          "@c.(e*a'+a'=(e*a+e)+a'->(e*a+e)+a'=c->e*a'+a'=c)->(e*a'+a'=(e*a+e)+a'->(e*a+e)+a'=e*a+(e+a')->e*a'+a'=e*a+(e+a'))";
  1392.          "e*a'+a'=(e*a+e)+a'->(e*a+e)+a'=e*a+(e+a')->e*a'+a'=e*a+(e+a')";
  1393.          "(e*a+e)+a'=e*a+(e+a')->e*a'+a'=e*a+(e+a')";
  1394.          "e*a'+a'=e*a+(e+a')";
  1395.          "@a.@b.(a+b'=(a+b)')->@b.(e+b'=(e+b)')";
  1396.          "@b.(e+b'=(e+b)')";
  1397.          "@b.(e+b'=(e+b)')->(e+a'=(e+a)')";
  1398.          "e+a'=(e+a)'";
  1399.          "@a.@b.(a'+b=(a+b)')->@b.(e'+b=(e+b)')";
  1400.          "@b.(e'+b=(e+b)')";
  1401.          "@b.(e'+b=(e+b)')->(e'+a=(e+a)')";
  1402.          "e'+a=(e+a)'";
  1403.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=(e+a)'->c=(e+a)'->b=c)";
  1404.          "@b.@c.(b=(e+a)'->c=(e+a)'->b=c)";
  1405.          "@b.@c.(b=(e+a)'->c=(e+a)'->b=c)->@c.(e+a'=(e+a)'->c=(e+a)'->e+a'=c)";
  1406.          "@c.(e+a'=(e+a)'->c=(e+a)'->e+a'=c)";
  1407.          "@c.(e+a'=(e+a)'->c=(e+a)'->e+a'=c)->(e+a'=(e+a)'->e'+a=(e+a)'->e+a'=e'+a)";
  1408.          "e+a'=(e+a)'->e'+a=(e+a)'->e+a'=e'+a";
  1409.          "e'+a=(e+a)'->e+a'=e'+a";
  1410.          "e+a'=e'+a";
  1411.          "@a.@b.@c.(a=b->c+a=c+b)->@b.@c.(e+a'=b->c+(e+a')=c+b)";
  1412.          "@b.@c.(e+a'=b->c+(e+a')=c+b)";
  1413.          "@b.@c.(e+a'=b->c+(e+a')=c+b)->@c.(e+a'=e'+a->c+(e+a')=c+(e'+a))";
  1414.          "@c.(e+a'=e'+a->c+(e+a')=c+(e'+a))";
  1415.          "@c.(e+a'=e'+a->c+(e+a')=c+(e'+a))->(e+a'=e'+a->e*a+(e+a')=e*a+(e'+a))";
  1416.          "e+a'=e'+a->e*a+(e+a')=e*a+(e'+a)";
  1417.          "e*a+(e+a')=e*a+(e'+a)";
  1418.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=e*a+(e+a')->e*a+(e+a')=c->b=c)";
  1419.          "@b.@c.(b=e*a+(e+a')->e*a+(e+a')=c->b=c)";
  1420.          "@b.@c.(b=e*a+(e+a')->e*a+(e+a')=c->b=c)->@c.(e*a'+a'=e*a+(e+a')->e*a+(e+a')=c->e*a'+a'=c)";
  1421.          "@c.(e*a'+a'=e*a+(e+a')->e*a+(e+a')=c->e*a'+a'=c)";
  1422.          "@c.(e*a'+a'=e*a+(e+a')->e*a+(e+a')=c->e*a'+a'=c)->(e*a'+a'=e*a+(e+a')->e*a+(e+a')=e*a+(e'+a)->e*a'+a'=e*a+(e'+a))";
  1423.          "e*a'+a'=e*a+(e+a')->e*a+(e+a')=e*a+(e'+a)->e*a'+a'=e*a+(e'+a)";
  1424.          "e*a+(e+a')=e*a+(e'+a)->e*a'+a'=e*a+(e'+a)";
  1425.          "e*a'+a'=e*a+(e'+a)";
  1426.          "@a.@b.(a+b=b+a)->@b.(e'+b=b+e')";
  1427.          "@b.(e'+b=b+e')";
  1428.          "@b.(e'+b=b+e')->(e'+a=a+e')";
  1429.          "e'+a=a+e'";
  1430.          "@a.@b.@c.(a=b->c+a=c+b)->@b.@c.(e'+a=b->c+(e'+a)=c+b)";
  1431.          "@b.@c.(e'+a=b->c+(e'+a)=c+b)";
  1432.          "@b.@c.(e'+a=b->c+(e'+a)=c+b)->@c.(e'+a=a+e'->c+(e'+a)=c+(a+e'))";
  1433.          "@c.(e'+a=a+e'->c+(e'+a)=c+(a+e'))";
  1434.          "@c.(e'+a=a+e'->c+(e'+a)=c+(a+e'))->(e'+a=a+e'->e*a+(e'+a)=e*a+(a+e'))";
  1435.          "e'+a=a+e'->e*a+(e'+a)=e*a+(a+e')";
  1436.          "e*a+(e'+a)=e*a+(a+e')";
  1437.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=e*a+(e'+a)->e*a+(e'+a)=c->b=c)";
  1438.          "@b.@c.(b=e*a+(e'+a)->e*a+(e'+a)=c->b=c)";
  1439.          "@b.@c.(b=e*a+(e'+a)->e*a+(e'+a)=c->b=c)->@c.(e*a'+a'=e*a+(e'+a)->e*a+(e'+a)=c->e*a'+a'=c)";
  1440.          "@c.(e*a'+a'=e*a+(e'+a)->e*a+(e'+a)=c->e*a'+a'=c)";
  1441.          "@c.(e*a'+a'=e*a+(e'+a)->e*a+(e'+a)=c->e*a'+a'=c)->(e*a'+a'=e*a+(e'+a)->e*a+(e'+a)=e*a+(a+e')->e*a'+a'=e*a+(a+e'))";
  1442.          "e*a'+a'=e*a+(e'+a)->e*a+(e'+a)=e*a+(a+e')->e*a'+a'=e*a+(a+e')";
  1443.          "e*a+(e'+a)=e*a+(a+e')->e*a'+a'=e*a+(a+e')";
  1444.          "e*a'+a'=e*a+(a+e')";
  1445.          "@a.@b.@c.((a+b)+c=a+(b+c))->@b.@c.((e*a+b)+c=e*a+(b+c))";
  1446.          "@b.@c.((e*a+b)+c=e*a+(b+c))";
  1447.          "@b.@c.((e*a+b)+c=e*a+(b+c))->@c.((e*a+a)+c=e*a+(a+c))";
  1448.          "@c.((e*a+a)+c=e*a+(a+c))";
  1449.          "@c.((e*a+a)+c=e*a+(a+c))->((e*a+a)+e'=e*a+(a+e'))";
  1450.          "(e*a+a)+e'=e*a+(a+e')";
  1451.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=e*a+(a+e')->c=e*a+(a+e')->b=c)";
  1452.          "@b.@c.(b=e*a+(a+e')->c=e*a+(a+e')->b=c)";
  1453.          "@b.@c.(b=e*a+(a+e')->c=e*a+(a+e')->b=c)->@c.(e*a'+a'=e*a+(a+e')->c=e*a+(a+e')->e*a'+a'=c)";
  1454.          "@c.(e*a'+a'=e*a+(a+e')->c=e*a+(a+e')->e*a'+a'=c)";
  1455.          "@c.(e*a'+a'=e*a+(a+e')->c=e*a+(a+e')->e*a'+a'=c)->(e*a'+a'=e*a+(a+e')->(e*a+a)+e'=e*a+(a+e')->e*a'+a'=(e*a+a)+e')";
  1456.          "e*a'+a'=e*a+(a+e')->(e*a+a)+e'=e*a+(a+e')->e*a'+a'=(e*a+a)+e'";
  1457.          "(e*a+a)+e'=e*a+(a+e')->e*a'+a'=(e*a+a)+e'";
  1458.          "e*a'+a'=(e*a+a)+e'";
  1459.          "@a.@b.@c.(a=b->a+c=b+c)->@b.@c.(e*a+a=b->(e*a+a)+c=b+c)";
  1460.          "@b.@c.(e*a+a=b->(e*a+a)+c=b+c)";
  1461.          "@b.@c.(e*a+a=b->(e*a+a)+c=b+c)->@c.(e*a+a=e'*a->(e*a+a)+c=e'*a+c)";
  1462.          "@c.(e*a+a=e'*a->(e*a+a)+c=e'*a+c)";
  1463.          "@c.(e*a+a=e'*a->(e*a+a)+c=e'*a+c)->(e*a+a=e'*a->(e*a+a)+e'=e'*a+e')";
  1464.          "e*a+a=e'*a->(e*a+a)+e'=e'*a+e'";
  1465.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(e*a+a)+e'->(e*a+a)+e'=c->b=c)";
  1466.          "@b.@c.(b=(e*a+a)+e'->(e*a+a)+e'=c->b=c)";
  1467.          "@b.@c.(b=(e*a+a)+e'->(e*a+a)+e'=c->b=c)->@c.(e*a'+a'=(e*a+a)+e'->(e*a+a)+e'=c->e*a'+a'=c)";
  1468.          "@c.(e*a'+a'=(e*a+a)+e'->(e*a+a)+e'=c->e*a'+a'=c)";
  1469.          "@c.(e*a'+a'=(e*a+a)+e'->(e*a+a)+e'=c->e*a'+a'=c)->(e*a'+a'=(e*a+a)+e'->(e*a+a)+e'=e'*a+e'->e*a'+a'=e'*a+e')";
  1470.          "e*a'+a'=(e*a+a)+e'->(e*a+a)+e'=e'*a+e'->e*a'+a'=e'*a+e'";
  1471.          "(e*a+a)+e'=e'*a+e'->e*a'+a'=e'*a+e'";
  1472.          "((e*a+a)+e'=e'*a+e'->e*a'+a'=e'*a+e')->e*a+a=e'*a->((e*a+a)+e'=e'*a+e'->e*a'+a'=e'*a+e')";
  1473.          "e*a+a=e'*a->(e*a+a)+e'=e'*a+e'->e*a'+a'=e'*a+e'";
  1474.          "(e*a+a=e'*a->(e*a+a)+e'=e'*a+e')->(e*a+a=e'*a->(e*a+a)+e'=e'*a+e'->e*a'+a'=e'*a+e')->(e*a+a=e'*a->e*a'+a'=e'*a+e')";
  1475.          "(e*a+a=e'*a->(e*a+a)+e'=e'*a+e'->e*a'+a'=e'*a+e')->(e*a+a=e'*a->e*a'+a'=e'*a+e')";
  1476.          "e*a+a=e'*a->e*a'+a'=e'*a+e'";
  1477.          "@a.@b.(a*b'=a*b+a)->@b.(e'*b'=e'*b+e')";
  1478.          "@b.(e'*b'=e'*b+e')";
  1479.          "@b.(e'*b'=e'*b+e')->(e'*a'=e'*a+e')";
  1480.          "e'*a'=e'*a+e'";
  1481.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=e'*a+e'->c=e'*a+e'->b=c)";
  1482.          "@b.@c.(b=e'*a+e'->c=e'*a+e'->b=c)";
  1483.          "@b.@c.(b=e'*a+e'->c=e'*a+e'->b=c)->@c.(e*a'+a'=e'*a+e'->c=e'*a+e'->e*a'+a'=c)";
  1484.          "@c.(e*a'+a'=e'*a+e'->c=e'*a+e'->e*a'+a'=c)";
  1485.          "@c.(e*a'+a'=e'*a+e'->c=e'*a+e'->e*a'+a'=c)->(e*a'+a'=e'*a+e'->e'*a'=e'*a+e'->e*a'+a'=e'*a')";
  1486.          "e*a'+a'=e'*a+e'->e'*a'=e'*a+e'->e*a'+a'=e'*a'";
  1487.          "(e*a'+a'=e'*a+e'->e'*a'=e'*a+e'->e*a'+a'=e'*a')->e*a+a=e'*a->(e*a'+a'=e'*a+e'->e'*a'=e'*a+e'->e*a'+a'=e'*a')";
  1488.          "e*a+a=e'*a->e*a'+a'=e'*a+e'->e'*a'=e'*a+e'->e*a'+a'=e'*a'";
  1489.          "(e*a+a=e'*a->e*a'+a'=e'*a+e')->(e*a+a=e'*a->e*a'+a'=e'*a+e'->e'*a'=e'*a+e'->e*a'+a'=e'*a')->(e*a+a=e'*a->e'*a'=e'*a+e'->e*a'+a'=e'*a')";
  1490.          "(e*a+a=e'*a->e*a'+a'=e'*a+e'->e'*a'=e'*a+e'->e*a'+a'=e'*a')->(e*a+a=e'*a->e'*a'=e'*a+e'->e*a'+a'=e'*a')";
  1491.          "e*a+a=e'*a->e'*a'=e'*a+e'->e*a'+a'=e'*a'";
  1492.          "e'*a'=e'*a+e'->e*a+a=e'*a->e'*a'=e'*a+e'";
  1493.          "e*a+a=e'*a->e'*a'=e'*a+e'";
  1494.          "(e*a+a=e'*a->e'*a'=e'*a+e')->(e*a+a=e'*a->e'*a'=e'*a+e'->e*a'+a'=e'*a')->(e*a+a=e'*a->e*a'+a'=e'*a')";
  1495.          "(e*a+a=e'*a->e'*a'=e'*a+e'->e*a'+a'=e'*a')->(e*a+a=e'*a->e*a'+a'=e'*a')";
  1496.          "e*a+a=e'*a->e*a'+a'=e'*a'";
  1497.          "(e*a+a=e'*a->e*a'+a'=e'*a')->0=0->(e*a+a=e'*a->e*a'+a'=e'*a')";
  1498.          "0=0->(e*a+a=e'*a->e*a'+a'=e'*a')";
  1499.          "0=0->@a.(e*a+a=e'*a->e*a'+a'=e'*a')";
  1500.          "@a.(e*a+a=e'*a->e*a'+a'=e'*a')";
  1501.          "@a.(a+0=a)->(e*0+0=e*0)";
  1502.          "e*0+0=e*0";
  1503.          "a*0=0";
  1504.          "a*0=0->0=0->a*0=0";
  1505.          "0=0->a*0=0";
  1506.          "0=0->@a.(a*0=0)";
  1507.          "@a.(a*0=0)";
  1508.          "@a.(a*0=0)->(e*0=0)";
  1509.          "e*0=0";
  1510.          "@a.(a*0=0)->(e'*0=0)";
  1511.          "e'*0=0";
  1512.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=e*0->e*0=c->b=c)";
  1513.          "@b.@c.(b=e*0->e*0=c->b=c)";
  1514.          "@b.@c.(b=e*0->e*0=c->b=c)->@c.(e*0+0=e*0->e*0=c->e*0+0=c)";
  1515.          "@c.(e*0+0=e*0->e*0=c->e*0+0=c)";
  1516.          "@c.(e*0+0=e*0->e*0=c->e*0+0=c)->(e*0+0=e*0->e*0=0->e*0+0=0)";
  1517.          "e*0+0=e*0->e*0=0->e*0+0=0";
  1518.          "e*0=0->e*0+0=0";
  1519.          "e*0+0=0";
  1520.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=0->c=0->b=c)";
  1521.          "@b.@c.(b=0->c=0->b=c)";
  1522.          "@b.@c.(b=0->c=0->b=c)->@c.(e*0+0=0->c=0->e*0+0=c)";
  1523.          "@c.(e*0+0=0->c=0->e*0+0=c)";
  1524.          "@c.(e*0+0=0->c=0->e*0+0=c)->(e*0+0=0->e'*0=0->e*0+0=e'*0)";
  1525.          "e*0+0=0->e'*0=0->e*0+0=e'*0";
  1526.          "e'*0=0->e*0+0=e'*0";
  1527.          "e*0+0=e'*0";
  1528.          "e*0+0=e'*0->@a.(e*a+a=e'*a->e*a'+a'=e'*a')->e*0+0=e'*0&@a.(e*a+a=e'*a->e*a'+a'=e'*a')";
  1529.          "@a.(e*a+a=e'*a->e*a'+a'=e'*a')->e*0+0=e'*0&@a.(e*a+a=e'*a->e*a'+a'=e'*a')";
  1530.          "e*0+0=e'*0&@a.(e*a+a=e'*a->e*a'+a'=e'*a')";
  1531.          "e*0+0=e'*0&@a.(e*a+a=e'*a->e*a'+a'=e'*a')->e*a+a=e'*a";
  1532.          "e*a+a=e'*a";
  1533.          "e*a+a=e'*a->0=0->e*a+a=e'*a";
  1534.          "0=0->e*a+a=e'*a";
  1535.          "0=0->@e.(e*a+a=e'*a)";
  1536.          "0=0->@a.@e.(e*a+a=e'*a)";
  1537.          "@a.@e.(e*a+a=e'*a)";
  1538.          "@a.@e.(e*a+a=e'*a)->@e.(e*b+b=e'*b)";
  1539.          "@e.(e*b+b=e'*b)";
  1540.          "@e.(e*b+b=e'*b)->(a*b+b=a'*b)";
  1541.          "a*b+b=a'*b";
  1542.          "a*b+b=a'*b->0=0->a*b+b=a'*b";
  1543.          "0=0->a*b+b=a'*b";
  1544.          "0=0->@b.(a*b+b=a'*b)";
  1545.          "0=0->@a.@b.(a*b+b=a'*b)";
  1546.          "@a.@b.(a*b+b=a'*b)"];;
  1547. let zeroMulAEqZero = e'aEqeaPa @
  1548.         ["@a.@b.(a*b'=a*b+a)->@b.(0*b'=0*b+0)";
  1549.          "@b.(0*b'=0*b+0)";
  1550.          "@b.(0*b'=0*b+0)->(0*a'=0*a+0)";
  1551.          "0*a'=0*a+0";
  1552.          "@a.(a+0=a)->(0*a+0=0*a)";
  1553.          "0*a+0=0*a";
  1554.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=0*a+0->0*a+0=c->b=c)";
  1555.          "@b.@c.(b=0*a+0->0*a+0=c->b=c)";
  1556.          "@b.@c.(b=0*a+0->0*a+0=c->b=c)->@c.(0*a'=0*a+0->0*a+0=c->0*a'=c)";
  1557.          "@c.(0*a'=0*a+0->0*a+0=c->0*a'=c)";
  1558.          "@c.(0*a'=0*a+0->0*a+0=c->0*a'=c)->(0*a'=0*a+0->0*a+0=0*a->0*a'=0*a)";
  1559.          "0*a'=0*a+0->0*a+0=0*a->0*a'=0*a";
  1560.          "0*a+0=0*a->0*a'=0*a";
  1561.          "0*a'=0*a";
  1562.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=0*a->0*a=c->b=c)";
  1563.          "@b.@c.(b=0*a->0*a=c->b=c)";
  1564.          "@b.@c.(b=0*a->0*a=c->b=c)->@c.(0*a'=0*a->0*a=c->0*a'=c)";
  1565.          "@c.(0*a'=0*a->0*a=c->0*a'=c)";
  1566.          "@c.(0*a'=0*a->0*a=c->0*a'=c)->(0*a'=0*a->0*a=0->0*a'=0)";
  1567.          "0*a'=0*a->0*a=0->0*a'=0";
  1568.          "0*a=0->0*a'=0";
  1569.          "(0*a=0->0*a'=0)->0=0->(0*a=0->0*a'=0)";
  1570.          "0=0->(0*a=0->0*a'=0)";
  1571.          "0=0->@a.(0*a=0->0*a'=0)";
  1572.          "@a.(0*a=0->0*a'=0)";
  1573.          "@a.(a*0=0)->0*0=0";
  1574.          "0*0=0";
  1575.          "0*0=0->@a.(0*a=0->0*a'=0)->0*0=0&@a.(0*a=0->0*a'=0)";
  1576.          "@a.(0*a=0->0*a'=0)->0*0=0&@a.(0*a=0->0*a'=0)";
  1577.          "0*0=0&@a.(0*a=0->0*a'=0)";
  1578.          "0*0=0&@a.(0*a=0->0*a'=0)->0*a=0";
  1579.          "0*a=0";
  1580.          "(0*a=0)->0=0->(0*a=0)";
  1581.          "0=0->0*a=0";
  1582.          "0=0->@a.(0*a=0)";
  1583.          "@a.(0*a=0)"];;
  1584. let multiplicationDoesntChangeEquality = zeroMulAEqZero @
  1585.         ["@a.@b.(a*b+b=a'*b)->@b.(e*b+b=e'*b)";
  1586.          "@b.(e*b+b=e'*b)";
  1587.          "@b.(e*b+b=e'*b)->(e*d+d=e'*d)";
  1588.          "e*d+d=e'*d";
  1589.          "@a.@b.(a*b+b=a'*b)->@b.(e*b+b=e'*b)";
  1590.          "@b.(e*b+b=e'*b)";
  1591.          "@b.(e*b+b=e'*b)->(e*a+a=e'*a)";
  1592.          "e*a+a=e'*a";
  1593.          "@a.@b.@c.(a=b->a+c=b+c)->@b.@c.(e*a=b->e*a+c=b+c)";
  1594.          "@b.@c.(e*a=b->e*a+c=b+c)";
  1595.          "@b.@c.(e*a=b->e*a+c=b+c)->@c.(e*a=e*d->e*a+c=e*d+c)";
  1596.          "@c.(e*a=e*d->e*a+c=e*d+c)";
  1597.          "@c.(e*a=e*d->e*a+c=e*d+c)->(e*a=e*d->e*a+a=e*d+a)";
  1598.          "e*a=e*d->e*a+a=e*d+a";
  1599.          "(e*a=e*d->e*a+a=e*d+a)->a=d->(e*a=e*d->e*a+a=e*d+a)";
  1600.          "a=d->e*a=e*d->e*a+a=e*d+a";
  1601.          "(a=d->e*a=e*d)->(a=d->e*a=e*d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+a)";
  1602.          "(a=d->e*a=e*d->e*a+a=e*d+a)->(a=d->e*a=e*d)->(a=d->e*a=e*d->e*a+a=e*d+a)";
  1603.          "(a=d->e*a=e*d)->(a=d->e*a=e*d->e*a+a=e*d+a)";
  1604.          "((a=d->e*a=e*d)->(a=d->e*a=e*d->e*a+a=e*d+a))->((a=d->e*a=e*d)->(a=d->e*a=e*d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+a))->((a=d->e*a=e*d)->(a=d->e*a+a=e*d+a))";
  1605.          "((a=d->e*a=e*d)->(a=d->e*a=e*d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+a))->((a=d->e*a=e*d)->(a=d->e*a+a=e*d+a))";
  1606.          "(a=d->e*a=e*d)->(a=d->e*a+a=e*d+a)";
  1607.          "@a.@b.@c.(a=b->c+a=c+b)->@b.@c.(a=b->c+a=c+b)";
  1608.          "@b.@c.(a=b->c+a=c+b)";
  1609.          "@b.@c.(a=b->c+a=c+b)->@c.(a=d->c+a=c+d)";
  1610.          "@c.(a=d->c+a=c+d)";
  1611.          "@c.(a=d->c+a=c+d)->(a=d->e*d+a=e*d+d)";
  1612.          "a=d->e*d+a=e*d+d";
  1613.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=e*d+a->e*d+a=c->b=c)";
  1614.          "@b.@c.(b=e*d+a->e*d+a=c->b=c)";
  1615.          "@b.@c.(b=e*d+a->e*d+a=c->b=c)->@c.(e*a+a=e*d+a->e*d+a=c->e*a+a=c)";
  1616.          "@c.(e*a+a=e*d+a->e*d+a=c->e*a+a=c)";
  1617.          "@c.(e*a+a=e*d+a->e*d+a=c->e*a+a=c)->(e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d)";
  1618.          "e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d";
  1619.          "(e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d)->a=d->(e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d)";
  1620.          "a=d->e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d";
  1621.          "(a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d)";
  1622.          "(a=d->e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d)";
  1623.          "(a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d)";
  1624.          "((a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d))->((a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d))->((a=d->e*a+a=e*d+a)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d))";
  1625.          "((a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+a->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d))->((a=d->e*a+a=e*d+a)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d))";
  1626.          "(a=d->e*a+a=e*d+a)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d)";
  1627.          "(a=d->e*d+a=e*d+d)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d)";
  1628.          "(a=d->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d)";
  1629.          "((a=d->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d))->(a=d->e*a+a=e*d+a)->((a=d->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d))";
  1630.          "(a=d->e*a+a=e*d+a)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d)";
  1631.          "((a=d->e*a+a=e*d+a)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d))->((a=d->e*a+a=e*d+a)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d))->((a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+d))";
  1632.          "((a=d->e*a+a=e*d+a)->(a=d->e*d+a=e*d+d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d))->((a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+d))";
  1633.          "(a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+d)";
  1634.          "((a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+d))->(a=d->e*a=e*d)->((a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+d))";
  1635.          "(a=d->e*a=e*d)->(a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+d)";
  1636.          "((a=d->e*a=e*d)->(a=d->e*a+a=e*d+a))->((a=d->e*a=e*d)->(a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+d))->((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d))";
  1637.          "((a=d->e*a=e*d)->(a=d->e*a+a=e*d+a)->(a=d->e*a+a=e*d+d))->((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d))";
  1638.          "(a=d->e*a=e*d)->(a=d->e*a+a=e*d+d)";
  1639.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(e*a+a=b->e*a+a=c->b=c)";
  1640.          "@b.@c.(e*a+a=b->e*a+a=c->b=c)";
  1641.          "@b.@c.(e*a+a=b->e*a+a=c->b=c)->@c.(e*a+a=e'*a->e*a+a=c->e'*a=c)";
  1642.          "@c.(e*a+a=e'*a->e*a+a=c->e'*a=c)";
  1643.          "@c.(e*a+a=e'*a->e*a+a=c->e'*a=c)->(e*a+a=e'*a->e*a+a=e*d+d->e'*a=e*d+d)";
  1644.          "e*a+a=e'*a->e*a+a=e*d+d->e'*a=e*d+d";
  1645.          "e*a+a=e*d+d->e'*a=e*d+d";
  1646.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=e*d+d->e*d+d=c->b=c)";
  1647.          "@b.@c.(b=e*d+d->e*d+d=c->b=c)";
  1648.          "@b.@c.(b=e*d+d->e*d+d=c->b=c)->@c.(e'*a=e*d+d->e*d+d=c->e'*a=c)";
  1649.          "@c.(e'*a=e*d+d->e*d+d=c->e'*a=c)";
  1650.          "@c.(e'*a=e*d+d->e*d+d=c->e'*a=c)->(e'*a=e*d+d->e*d+d=e'*d->e'*a=e'*d)";
  1651.          "e'*a=e*d+d->e*d+d=e'*d->e'*a=e'*d";
  1652.          "(e'*a=e*d+d->e*d+d=e'*d->e'*a=e'*d)->e*a+a=e*d+d->(e'*a=e*d+d->e*d+d=e'*d->e'*a=e'*d)";
  1653.          "e*a+a=e*d+d->e'*a=e*d+d->e*d+d=e'*d->e'*a=e'*d";
  1654.          "(e*a+a=e*d+d->e'*a=e*d+d)->(e*a+a=e*d+d->e'*a=e*d+d->e*d+d=e'*d->e'*a=e'*d)->(e*a+a=e*d+d->e*d+d=e'*d->e'*a=e'*d)";
  1655.          "(e*a+a=e*d+d->e'*a=e*d+d->e*d+d=e'*d->e'*a=e'*d)->(e*a+a=e*d+d->e*d+d=e'*d->e'*a=e'*d)";
  1656.          "e*a+a=e*d+d->e*d+d=e'*d->e'*a=e'*d";
  1657.          "(e*d+d=e'*d)->(e*a+a=e*d+d)->(e*d+d=e'*d)";
  1658.          "e*a+a=e*d+d->e*d+d=e'*d";
  1659.          "(e*a+a=e*d+d->e*d+d=e'*d)->(e*a+a=e*d+d->e*d+d=e'*d->e'*a=e'*d)->(e*a+a=e*d+d->e'*a=e'*d)";
  1660.          "(e*a+a=e*d+d->e*d+d=e'*d->e'*a=e'*d)->(e*a+a=e*d+d->e'*a=e'*d)";
  1661.          "e*a+a=e*d+d->e'*a=e'*d";
  1662.          "(e*a+a=e*d+d->e'*a=e'*d)->a=d->(e*a+a=e*d+d->e'*a=e'*d)";
  1663.          "a=d->e*a+a=e*d+d->e'*a=e'*d";
  1664.          "(a=d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d)";
  1665.          "((a=d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d))->(a=d->e*a=e*d)->((a=d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d))";
  1666.          "(a=d->e*a=e*d)->(a=d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d)";
  1667.          "((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d))->((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d))->((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d))";
  1668.          "((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d))->((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d))";
  1669.          "(a=d->e*a=e*d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d)";
  1670.          "(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e*a=e*d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)";
  1671.          "(a=d->e*a=e*d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)";
  1672.          "((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d->e'*a=e'*d))->((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d))->((a=d->e*a=e*d)->(a=d->e'*a=e'*d))";
  1673.          "((a=d->e*a=e*d)->(a=d->e*a+a=e*d+d->e'*a=e'*d)->(a=d->e'*a=e'*d))->((a=d->e*a=e*d)->(a=d->e'*a=e'*d))";
  1674.          "(a=d->e*a=e*d)->(a=d->e'*a=e'*d)";
  1675.          "((a=d->e*a=e*d)->(a=d->e'*a=e'*d))->0=0->((a=d->e*a=e*d)->(a=d->e'*a=e'*d))";
  1676.          "0=0->((a=d->e*a=e*d)->(a=d->e'*a=e'*d))";
  1677.          "0=0->@e.((a=d->e*a=e*d)->(a=d->e'*a=e'*d))";
  1678.          "@e.((a=d->e*a=e*d)->(a=d->e'*a=e'*d))";
  1679.          "@a.(0*a=0)->(0*a=0)";
  1680.          "0*a=0";
  1681.          "@a.(0*a=0)->(0*d=0)";
  1682.          "0*d=0";
  1683.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=0->c=0->b=c)";
  1684.          "@b.@c.(b=0->c=0->b=c)";
  1685.          "@b.@c.(b=0->c=0->b=c)->@c.(0*a=0->c=0->0*a=c)";
  1686.          "@c.(0*a=0->c=0->0*a=c)";
  1687.          "@c.(0*a=0->c=0->0*a=c)->(0*a=0->0*d=0->0*a=0*d)";
  1688.          "0*a=0->0*d=0->0*a=0*d";
  1689.          "0*d=0->0*a=0*d";
  1690.          "0*a=0*d";
  1691.          "0*a=0*d->a=d->0*a=0*d";
  1692.          "a=d->0*a=0*d";
  1693.          "(a=d->0*a=0*d)->@e.((a=d->e*a=e*d)->(a=d->e'*a=e'*d))->(a=d->0*a=0*d)&@e.((a=d->e*a=e*d)->(a=d->e'*a=e'*d))";
  1694.          "@e.((a=d->e*a=e*d)->(a=d->e'*a=e'*d))->(a=d->0*a=0*d)&@e.((a=d->e*a=e*d)->(a=d->e'*a=e'*d))";
  1695.          "(a=d->0*a=0*d)&@e.((a=d->e*a=e*d)->(a=d->e'*a=e'*d))";
  1696.          "(a=d->0*a=0*d)&@e.((a=d->e*a=e*d)->(a=d->e'*a=e'*d))->(a=d->e*a=e*d)";
  1697.          "a=d->e*a=e*d";
  1698.          "(a=d->e*a=e*d)->0=0->(a=d->e*a=e*d)";
  1699.          "0=0->(a=d->e*a=e*d)";
  1700.          "0=0->@e.(a=d->e*a=e*d)";
  1701.          "0=0->@d.@e.(a=d->e*a=e*d)";
  1702.          "@d.@e.(a=d->e*a=e*d)";
  1703.          "@d.@e.(a=d->e*a=e*d)->@e.(a=b->e*a=e*b)";
  1704.          "@e.(a=b->e*a=e*b)";
  1705.          "@e.(a=b->e*a=e*b)->(a=b->c*a=c*b)";
  1706.          "a=b->c*a=c*b";
  1707.          "(a=b->c*a=c*b)->0=0->(a=b->c*a=c*b)";
  1708.          "0=0->(a=b->c*a=c*b)";
  1709.          "0=0->@c.(a=b->c*a=c*b)";
  1710.          "0=0->@b.@c.(a=b->c*a=c*b)";
  1711.          "0=0->@a.@b.@c.(a=b->c*a=c*b)";
  1712.          "@a.@b.@c.(a=b->c*a=c*b)"];;
  1713. let distributivity = multiplicationDoesntChangeEquality @
  1714.         ["@a.@b.(a+b'=(a+b)')->@b.(d+b'=(d+b)')";
  1715.          "@b.(d+b'=(d+b)')";
  1716.          "@b.(d+b'=(d+b)')->(d+e'=(d+e)')";
  1717.          "d+e'=(d+e)'";
  1718.          "@a.@b.@c.(a=b->c*a=c*b)->@b.@c.(d+e'=b->c*(d+e')=c*b)";
  1719.          "@b.@c.(d+e'=b->c*(d+e')=c*b)";
  1720.          "@b.@c.(d+e'=b->c*(d+e')=c*b)->@c.(d+e'=(d+e)'->c*(d+e')=c*(d+e)')";
  1721.          "@c.(d+e'=(d+e)'->c*(d+e')=c*(d+e)')";
  1722.          "@c.(d+e'=(d+e)'->c*(d+e')=c*(d+e)')->(d+e'=(d+e)'->a*(d+e')=a*(d+e)')";
  1723.          "d+e'=(d+e)'->a*(d+e')=a*(d+e)'";
  1724.          "a*(d+e')=a*(d+e)'";
  1725.          "@a.@b.(a*b'=a*b+a)->@b.(a*b'=a*b+a)";
  1726.          "@b.(a*b'=a*b+a)";
  1727.          "@b.(a*b'=a*b+a)->(a*(d+e)'=a*(d+e)+a)";
  1728.          "a*(d+e)'=a*(d+e)+a";
  1729.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=a*(d+e)'->a*(d+e)'=c->b=c)";
  1730.          "@b.@c.(b=a*(d+e)'->a*(d+e)'=c->b=c)";
  1731.          "@b.@c.(b=a*(d+e)'->a*(d+e)'=c->b=c)->@c.(a*(d+e')=a*(d+e)'->a*(d+e)'=c->a*(d+e')=c)";
  1732.          "@c.(a*(d+e')=a*(d+e)'->a*(d+e)'=c->a*(d+e')=c)";
  1733.          "@c.(a*(d+e')=a*(d+e)'->a*(d+e)'=c->a*(d+e')=c)->(a*(d+e')=a*(d+e)'->a*(d+e)'=a*(d+e)+a->a*(d+e')=a*(d+e)+a)";
  1734.          "a*(d+e')=a*(d+e)'->a*(d+e)'=a*(d+e)+a->a*(d+e')=a*(d+e)+a";
  1735.          "a*(d+e)'=a*(d+e)+a->a*(d+e')=a*(d+e)+a";
  1736.          "a*(d+e')=a*(d+e)+a";
  1737.          "@a.@b.(a*b'=a*b+a)->@b.(a*b'=a*b+a)";
  1738.          "@b.(a*b'=a*b+a)";
  1739.          "@b.(a*b'=a*b+a)->(a*e'=a*e+a)";
  1740.          "a*e'=a*e+a";
  1741.          "@a.@b.@c.(a=b->c+a=c+b)->@b.@c.(a*e'=b->c+a*e'=c+b)";
  1742.          "@b.@c.(a*e'=b->c+a*e'=c+b)";
  1743.          "@b.@c.(a*e'=b->c+a*e'=c+b)->@c.(a*e'=a*e+a->c+a*e'=c+(a*e+a))";
  1744.          "@c.(a*e'=a*e+a->c+a*e'=c+(a*e+a))";
  1745.          "@c.(a*e'=a*e+a->c+a*e'=c+(a*e+a))->(a*e'=a*e+a->a*d+a*e'=a*d+(a*e+a))";
  1746.          "a*e'=a*e+a->a*d+a*e'=a*d+(a*e+a)";
  1747.          "a*d+a*e'=a*d+(a*e+a)";
  1748.          "@a.@b.@c.((a+b)+c=a+(b+c))->@b.@c.((a*d+b)+c=a*d+(b+c))";
  1749.          "@b.@c.((a*d+b)+c=a*d+(b+c))";
  1750.          "@b.@c.((a*d+b)+c=a*d+(b+c))->@c.((a*d+a*e)+c=a*d+(a*e+c))";
  1751.          "@c.((a*d+a*e)+c=a*d+(a*e+c))";
  1752.          "@c.((a*d+a*e)+c=a*d+(a*e+c))->((a*d+a*e)+a=a*d+(a*e+a))";
  1753.          "(a*d+a*e)+a=a*d+(a*e+a)";
  1754.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=a*d+(a*e+a)->c=a*d+(a*e+a)->b=c)";
  1755.          "@b.@c.(b=a*d+(a*e+a)->c=a*d+(a*e+a)->b=c)";
  1756.          "@b.@c.(b=a*d+(a*e+a)->c=a*d+(a*e+a)->b=c)->@c.(a*d+a*e'=a*d+(a*e+a)->c=a*d+(a*e+a)->a*d+a*e'=c)";
  1757.          "@c.(a*d+a*e'=a*d+(a*e+a)->c=a*d+(a*e+a)->a*d+a*e'=c)";
  1758.          "@c.(a*d+a*e'=a*d+(a*e+a)->c=a*d+(a*e+a)->a*d+a*e'=c)->(a*d+a*e'=a*d+(a*e+a)->(a*d+a*e)+a=a*d+(a*e+a)->a*d+a*e'=(a*d+a*e)+a)";
  1759.          "a*d+a*e'=a*d+(a*e+a)->(a*d+a*e)+a=a*d+(a*e+a)->a*d+a*e'=(a*d+a*e)+a";
  1760.          "(a*d+a*e)+a=a*d+(a*e+a)->a*d+a*e'=(a*d+a*e)+a";
  1761.          "a*d+a*e'=(a*d+a*e)+a";
  1762.          "@a.@b.@c.(a=b->a+c=b+c)->@b.@c.(a*(d+e)=b->a*(d+e)+c=b+c)";
  1763.          "@b.@c.(a*(d+e)=b->a*(d+e)+c=b+c)";
  1764.          "@b.@c.(a*(d+e)=b->a*(d+e)+c=b+c)->@c.(a*(d+e)=a*d+a*e->a*(d+e)+c=(a*d+a*e)+c)";
  1765.          "@c.(a*(d+e)=a*d+a*e->a*(d+e)+c=(a*d+a*e)+c)";
  1766.          "@c.(a*(d+e)=a*d+a*e->a*(d+e)+c=(a*d+a*e)+c)->(a*(d+e)=a*d+a*e->a*(d+e)+a=(a*d+a*e)+a)";
  1767.          "a*(d+e)=a*d+a*e->a*(d+e)+a=(a*d+a*e)+a";
  1768.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=(a*d+a*e)+a->c=(a*d+a*e)+a->b=c)";
  1769.          "@b.@c.(b=(a*d+a*e)+a->c=(a*d+a*e)+a->b=c)";
  1770.          "@b.@c.(b=(a*d+a*e)+a->c=(a*d+a*e)+a->b=c)->@c.(a*(d+e)+a=(a*d+a*e)+a->c=(a*d+a*e)+a->a*(d+e)+a=c)";
  1771.          "@c.(a*(d+e)+a=(a*d+a*e)+a->c=(a*d+a*e)+a->a*(d+e)+a=c)";
  1772.          "@c.(a*(d+e)+a=(a*d+a*e)+a->c=(a*d+a*e)+a->a*(d+e)+a=c)->(a*(d+e)+a=(a*d+a*e)+a->a*d+a*e'=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e')";
  1773.          "a*(d+e)+a=(a*d+a*e)+a->a*d+a*e'=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e'";
  1774.          "a*d+a*e'=(a*d+a*e)+a->a*(d+e)+a=(a*d+a*e)+a->a*d+a*e'=(a*d+a*e)+a";
  1775.          "a*(d+e)+a=(a*d+a*e)+a->a*d+a*e'=(a*d+a*e)+a";
  1776.          "(a*(d+e)+a=(a*d+a*e)+a->a*d+a*e'=(a*d+a*e)+a)->(a*(d+e)+a=(a*d+a*e)+a->a*d+a*e'=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e')->(a*(d+e)+a=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e')";
  1777.          "(a*(d+e)+a=(a*d+a*e)+a->a*d+a*e'=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e')->(a*(d+e)+a=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e')";
  1778.          "a*(d+e)+a=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e'";
  1779.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=a*(d+e)+a->a*(d+e)+a=c->b=c)";
  1780.          "@b.@c.(b=a*(d+e)+a->a*(d+e)+a=c->b=c)";
  1781.          "@b.@c.(b=a*(d+e)+a->a*(d+e)+a=c->b=c)->@c.(a*(d+e')=a*(d+e)+a->a*(d+e)+a=c->a*(d+e')=c)";
  1782.          "@c.(a*(d+e')=a*(d+e)+a->a*(d+e)+a=c->a*(d+e')=c)";
  1783.          "@c.(a*(d+e')=a*(d+e)+a->a*(d+e)+a=c->a*(d+e')=c)->(a*(d+e')=a*(d+e)+a->a*(d+e)+a=a*d+a*e'->a*(d+e')=a*d+a*e')";
  1784.          "a*(d+e')=a*(d+e)+a->a*(d+e)+a=a*d+a*e'->a*(d+e')=a*d+a*e'";
  1785.          "a*(d+e)+a=a*d+a*e'->a*(d+e')=a*d+a*e'";
  1786.          "(a*(d+e)+a=a*d+a*e'->a*(d+e')=a*d+a*e')->a*(d+e)+a=(a*d+a*e)+a->(a*(d+e)+a=a*d+a*e'->a*(d+e')=a*d+a*e')";
  1787.          "a*(d+e)+a=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e'->a*(d+e')=a*d+a*e'";
  1788.          "(a*(d+e)+a=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e')->(a*(d+e)+a=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e'->a*(d+e')=a*d+a*e')->(a*(d+e)+a=(a*d+a*e)+a->a*(d+e')=a*d+a*e')";
  1789.          "(a*(d+e)+a=(a*d+a*e)+a->a*(d+e)+a=a*d+a*e'->a*(d+e')=a*d+a*e')->(a*(d+e)+a=(a*d+a*e)+a->a*(d+e')=a*d+a*e')";
  1790.          "a*(d+e)+a=(a*d+a*e)+a->a*(d+e')=a*d+a*e'";
  1791.          "(a*(d+e)+a=(a*d+a*e)+a->a*(d+e')=a*d+a*e')->a*(d+e)=a*d+a*e->(a*(d+e)+a=(a*d+a*e)+a->a*(d+e')=a*d+a*e')";
  1792.          "a*(d+e)=a*d+a*e->a*(d+e)+a=(a*d+a*e)+a->a*(d+e')=a*d+a*e'";
  1793.          "(a*(d+e)=a*d+a*e->a*(d+e)+a=(a*d+a*e)+a)->(a*(d+e)=a*d+a*e->a*(d+e)+a=(a*d+a*e)+a->a*(d+e')=a*d+a*e')->(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')";
  1794.          "(a*(d+e)=a*d+a*e->a*(d+e)+a=(a*d+a*e)+a->a*(d+e')=a*d+a*e')->(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')";
  1795.          "a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e'";
  1796.          "(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')->0=0->(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')";
  1797.          "0=0->(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')";
  1798.          "0=0->@e.(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')";
  1799.          "@e.(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')";
  1800.          "@a.(a+0=a)->(d+0=d)";
  1801.          "d+0=d";
  1802.          "@a.@b.@c.(a=b->c*a=c*b)->@b.@c.(d+0=b->c*(d+0)=c*b)";
  1803.          "@b.@c.(d+0=b->c*(d+0)=c*b)";
  1804.          "@b.@c.(d+0=b->c*(d+0)=c*b)->@c.(d+0=d->c*(d+0)=c*d)";
  1805.          "@c.(d+0=d->c*(d+0)=c*d)";
  1806.          "@c.(d+0=d->c*(d+0)=c*d)->(d+0=d->a*(d+0)=a*d)";
  1807.          "d+0=d->a*(d+0)=a*d";
  1808.          "a*(d+0)=a*d";
  1809.          "a*0=0";
  1810.          "@a.@b.@c.(a=b->c+a=c+b)->@b.@c.(a*0=b->c+a*0=c+b)";
  1811.          "@b.@c.(a*0=b->c+a*0=c+b)";
  1812.          "@b.@c.(a*0=b->c+a*0=c+b)->@c.(a*0=0->c+a*0=c+0)";
  1813.          "@c.(a*0=0->c+a*0=c+0)";
  1814.          "@c.(a*0=0->c+a*0=c+0)->(a*0=0->a*d+a*0=a*d+0)";
  1815.          "a*0=0->a*d+a*0=a*d+0";
  1816.          "a*d+a*0=a*d+0";
  1817.          "@a.(a+0=a)->(a*d+0=a*d)";
  1818.          "a*d+0=a*d";
  1819.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=a*d+0->a*d+0=c->b=c)";
  1820.          "@b.@c.(b=a*d+0->a*d+0=c->b=c)";
  1821.          "@b.@c.(b=a*d+0->a*d+0=c->b=c)->@c.(a*d+a*0=a*d+0->a*d+0=c->a*d+a*0=c)";
  1822.          "@c.(a*d+a*0=a*d+0->a*d+0=c->a*d+a*0=c)";
  1823.          "@c.(a*d+a*0=a*d+0->a*d+0=c->a*d+a*0=c)->(a*d+a*0=a*d+0->a*d+0=a*d->a*d+a*0=a*d)";
  1824.          "a*d+a*0=a*d+0->a*d+0=a*d->a*d+a*0=a*d";
  1825.          "a*d+0=a*d->a*d+a*0=a*d";
  1826.          "a*d+a*0=a*d";
  1827.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=a*d->c=a*d->b=c)";
  1828.          "@b.@c.(b=a*d->c=a*d->b=c)";
  1829.          "@b.@c.(b=a*d->c=a*d->b=c)->@c.(a*(d+0)=a*d->c=a*d->a*(d+0)=c)";
  1830.          "@c.(a*(d+0)=a*d->c=a*d->a*(d+0)=c)";
  1831.          "@c.(a*(d+0)=a*d->c=a*d->a*(d+0)=c)->(a*(d+0)=a*d->a*d+a*0=a*d->a*(d+0)=a*d+a*0)";
  1832.          "a*(d+0)=a*d->a*d+a*0=a*d->a*(d+0)=a*d+a*0";
  1833.          "a*d+a*0=a*d->a*(d+0)=a*d+a*0";
  1834.          "a*(d+0)=a*d+a*0";
  1835.          "a*(d+0)=a*d+a*0->@e.(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')->a*(d+0)=a*d+a*0&@e.(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')";
  1836.          "@e.(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')->a*(d+0)=a*d+a*0&@e.(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')";
  1837.          "a*(d+0)=a*d+a*0&@e.(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')";
  1838.          "a*(d+0)=a*d+a*0&@e.(a*(d+e)=a*d+a*e->a*(d+e')=a*d+a*e')->a*(d+e)=a*d+a*e";
  1839.          "a*(d+e)=a*d+a*e";
  1840.          "a*(d+e)=a*d+a*e->0=0->a*(d+e)=a*d+a*e";
  1841.          "0=0->a*(d+e)=a*d+a*e";
  1842.          "0=0->@e.(a*(d+e)=a*d+a*e)";
  1843.          "0=0->@d.@e.(a*(d+e)=a*d+a*e)";
  1844.          "@d.@e.(a*(d+e)=a*d+a*e)";
  1845.          "@d.@e.(a*(d+e)=a*d+a*e)->@e.(a*(b+e)=a*b+a*e)";
  1846.          "@e.(a*(b+e)=a*b+a*e)";
  1847.          "@e.(a*(b+e)=a*b+a*e)->(a*(b+c)=a*b+a*c)";
  1848.          "a*(b+c)=a*b+a*c";
  1849.          "a*(b+c)=a*b+a*c->0=0->a*(b+c)=a*b+a*c";
  1850.          "0=0->a*(b+c)=a*b+a*c";
  1851.          "0=0->@c.(a*(b+c)=a*b+a*c)";
  1852.          "0=0->@b.@c.(a*(b+c)=a*b+a*c)";
  1853.          "0=0->@a.@b.@c.(a*(b+c)=a*b+a*c)";
  1854.          "@a.@b.@c.(a*(b+c)=a*b+a*c)"];;
  1855. let substractDoesntMatter = distributivity @
  1856.         ["a'=b'->a=b";
  1857.          "(a'=b'->a=b)->0=0->(a'=b'->a=b)";
  1858.          "0=0->(a'=b'->a=b)";
  1859.          "0=0->@b.(a'=b'->a=b)";
  1860.          "0=0->@a.@b.(a'=b'->a=b)";
  1861.          "@a.@b.(a'=b'->a=b)";
  1862.          "@a.@b.(a'=b'->a=b)->@b.((a+e)'=b'->a+e=b)";
  1863.          "@b.((a+e)'=b'->a+e=b)";
  1864.          "@b.((a+e)'=b'->a+e=b)->((a+e)'=(d+e)'->a+e=d+e)";
  1865.          "(a+e)'=(d+e)'->a+e=d+e";
  1866.          "@a.@b.(a+b'=(a+b)')->@b.(a+b'=(a+b)')";
  1867.          "@b.(a+b'=(a+b)')";
  1868.          "@b.(a+b'=(a+b)')->(a+e'=(a+e)')";
  1869.          "a+e'=(a+e)'";
  1870.          "@a.@b.(a+b'=(a+b)')->@b.(d+b'=(d+b)')";
  1871.          "@b.(d+b'=(d+b)')";
  1872.          "@b.(d+b'=(d+b)')->(d+e'=(d+e)')";
  1873.          "d+e'=(d+e)'";
  1874.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(a+e'=b->a+e'=c->b=c)";
  1875.          "@b.@c.(a+e'=b->a+e'=c->b=c)";
  1876.          "@b.@c.(a+e'=b->a+e'=c->b=c)->@c.(a+e'=(a+e)'->a+e'=c->(a+e)'=c)";
  1877.          "@c.(a+e'=(a+e)'->a+e'=c->(a+e)'=c)";
  1878.          "@c.(a+e'=(a+e)'->a+e'=c->(a+e)'=c)->(a+e'=(a+e)'->a+e'=d+e'->(a+e)'=d+e')";
  1879.          "a+e'=(a+e)'->a+e'=d+e'->(a+e)'=d+e'";
  1880.          "a+e'=d+e'->(a+e)'=d+e'";
  1881.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=d+e'->d+e'=c->b=c)";
  1882.          "@b.@c.(b=d+e'->d+e'=c->b=c)";
  1883.          "@b.@c.(b=d+e'->d+e'=c->b=c)->@c.((a+e)'=d+e'->d+e'=c->(a+e)'=c)";
  1884.          "@c.((a+e)'=d+e'->d+e'=c->(a+e)'=c)";
  1885.          "@c.((a+e)'=d+e'->d+e'=c->(a+e)'=c)->((a+e)'=d+e'->d+e'=(d+e)'->(a+e)'=(d+e)')";
  1886.          "(a+e)'=d+e'->d+e'=(d+e)'->(a+e)'=(d+e)'";
  1887.          "d+e'=(d+e)'->(a+e)'=d+e'->d+e'=(d+e)'";
  1888.          "(a+e)'=d+e'->d+e'=(d+e)'";
  1889.          "((a+e)'=d+e'->d+e'=(d+e)')->((a+e)'=d+e'->d+e'=(d+e)'->(a+e)'=(d+e)')->((a+e)'=d+e'->(a+e)'=(d+e)')";
  1890.          "((a+e)'=d+e'->d+e'=(d+e)'->(a+e)'=(d+e)')->((a+e)'=d+e'->(a+e)'=(d+e)')";
  1891.          "(a+e)'=d+e'->(a+e)'=(d+e)'";
  1892.          "((a+e)'=d+e'->(a+e)'=(d+e)')->a+e'=d+e'->((a+e)'=d+e'->(a+e)'=(d+e)')";
  1893.          "a+e'=d+e'->(a+e)'=d+e'->(a+e)'=(d+e)'";
  1894.          "(a+e'=d+e'->(a+e)'=d+e')->(a+e'=d+e'->(a+e)'=d+e'->(a+e)'=(d+e)')->(a+e'=d+e'->(a+e)'=(d+e)')";
  1895.          "(a+e'=d+e'->(a+e)'=d+e'->(a+e)'=(d+e)')->(a+e'=d+e'->(a+e)'=(d+e)')";
  1896.          "a+e'=d+e'->(a+e)'=(d+e)'";
  1897.          "((a+e)'=(d+e)'->a+e=d+e)->a+e'=d+e'->((a+e)'=(d+e)'->a+e=d+e)";
  1898.          "a+e'=d+e'->(a+e)'=(d+e)'->a+e=d+e";
  1899.          "(a+e'=d+e'->(a+e)'=(d+e)')->(a+e'=d+e'->(a+e)'=(d+e)'->a+e=d+e)->(a+e'=d+e'->a+e=d+e)";
  1900.          "(a+e'=d+e'->(a+e)'=(d+e)'->a+e=d+e)->(a+e'=d+e'->a+e=d+e)";
  1901.          "a+e'=d+e'->a+e=d+e";
  1902.          "((a+e'=d+e'->a+e=d+e)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d))->(a+e=d+e->a=d)->((a+e'=d+e'->a+e=d+e)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1903.          "(a+e'=d+e'->a+e=d+e)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d)";
  1904.          "(a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d)";
  1905.          "(a+e'=d+e'->a+e=d+e)->(a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e)";
  1906.          "(a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e)";
  1907.          "((a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e))->((a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d))->((a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1908.          "((a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d))->((a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1909.          "(a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d)";
  1910.          "(a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e->a=d)";
  1911.          "((a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e->a=d))->((a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d))->((a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1912.          "((a+e=d+e->a=d)->(a+e'=d+e'->a+e=d+e->a=d)->(a+e'=d+e'->a=d))->((a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1913.          "(a+e=d+e->a=d)->(a+e'=d+e'->a=d)";
  1914.          "((a+e=d+e->a=d)->(a+e'=d+e'->a=d))->0=0->((a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1915.          "0=0->((a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1916.          "0=0->@e.((a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1917.          "@e.((a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1918.          "@a.(a+0=a)->(d+0=d)";
  1919.          "d+0=d";
  1920.          "a+0=a";
  1921.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(a+0=b->a+0=c->b=c)";
  1922.          "@b.@c.(a+0=b->a+0=c->b=c)";
  1923.          "@b.@c.(a+0=b->a+0=c->b=c)->@c.(a+0=a->a+0=c->a=c)";
  1924.          "@c.(a+0=a->a+0=c->a=c)";
  1925.          "@c.(a+0=a->a+0=c->a=c)->(a+0=a->a+0=d+0->a=d+0)";
  1926.          "a+0=a->a+0=d+0->a=d+0";
  1927.          "a+0=d+0->a=d+0";
  1928.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=d+0->d+0=c->b=c)";
  1929.          "@b.@c.(b=d+0->d+0=c->b=c)";
  1930.          "@b.@c.(b=d+0->d+0=c->b=c)->@c.(a=d+0->d+0=c->a=c)";
  1931.          "@c.(a=d+0->d+0=c->a=c)";
  1932.          "@c.(a=d+0->d+0=c->a=c)->(a=d+0->d+0=d->a=d)";
  1933.          "a=d+0->d+0=d->a=d";
  1934.          "d+0=d->a=d+0->d+0=d";
  1935.          "a=d+0->d+0=d";
  1936.          "(a=d+0->d+0=d)->(a=d+0->d+0=d->a=d)->(a=d+0->a=d)";
  1937.          "(a=d+0->d+0=d->a=d)->(a=d+0->a=d)";
  1938.          "a=d+0->a=d";
  1939.          "(a=d+0->a=d)->a+0=d+0->(a=d+0->a=d)";
  1940.          "a+0=d+0->a=d+0->a=d";
  1941.          "(a+0=d+0->a=d+0)->(a+0=d+0->a=d+0->a=d)->(a+0=d+0->a=d)";
  1942.          "(a+0=d+0->a=d+0->a=d)->(a+0=d+0->a=d)";
  1943.          "a+0=d+0->a=d";
  1944.          "(a+0=d+0->a=d)->@e.((a+e=d+e->a=d)->(a+e'=d+e'->a=d))->(a+0=d+0->a=d)&@e.((a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1945.          "@e.((a+e=d+e->a=d)->(a+e'=d+e'->a=d))->(a+0=d+0->a=d)&@e.((a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1946.          "(a+0=d+0->a=d)&@e.((a+e=d+e->a=d)->(a+e'=d+e'->a=d))";
  1947.          "(a+0=d+0->a=d)&@e.((a+e=d+e->a=d)->(a+e'=d+e'->a=d))->(a+e=d+e->a=d)";
  1948.          "a+e=d+e->a=d";
  1949.          "(a+e=d+e->a=d)->0=0->(a+e=d+e->a=d)";
  1950.          "0=0->(a+e=d+e->a=d)";
  1951.          "0=0->@e.(a+e=d+e->a=d)";
  1952.          "0=0->@d.@e.(a+e=d+e->a=d)";
  1953.          "@d.@e.(a+e=d+e->a=d)";
  1954.          "@d.@e.(a+e=d+e->a=d)->@e.(a+e=b+e->a=b)";
  1955.          "@e.(a+e=b+e->a=b)";
  1956.          "@e.(a+e=b+e->a=b)->(a+c=b+c->a=b)";
  1957.          "a+c=b+c->a=b";
  1958.          "(a+c=b+c->a=b)->0=0->(a+c=b+c->a=b)";
  1959.          "0=0->(a+c=b+c->a=b)";
  1960.          "0=0->@c.(a+c=b+c->a=b)";
  1961.          "0=0->@b.@c.(a+c=b+c->a=b)";
  1962.          "0=0->@a.@b.@c.(a+c=b+c->a=b)";
  1963.          "@a.@b.@c.(a+c=b+c->a=b)";
  1964.          "@a.@b.(a+b=b+a)->@b.(a+b=b+a)";
  1965.          "@b.(a+b=b+a)";
  1966.          "@b.(a+b=b+a)->(a+e=e+a)";
  1967.          "a+e=e+a";
  1968.          "@a.@b.(a+b=b+a)->@b.(d+b=b+d)";
  1969.          "@b.(d+b=b+d)";
  1970.          "@b.(d+b=b+d)->(d+e=e+d)";
  1971.          "d+e=e+d";
  1972.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=e+a->e+a=c->b=c)";
  1973.          "@b.@c.(b=e+a->e+a=c->b=c)";
  1974.          "@b.@c.(b=e+a->e+a=c->b=c)->@c.(a+e=e+a->e+a=c->a+e=c)";
  1975.          "@c.(a+e=e+a->e+a=c->a+e=c)";
  1976.          "@c.(a+e=e+a->e+a=c->a+e=c)->(a+e=e+a->e+a=e+d->a+e=e+d)";
  1977.          "a+e=e+a->e+a=e+d->a+e=e+d";
  1978.          "e+a=e+d->a+e=e+d";
  1979.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=e+d->c=e+d->b=c)";
  1980.          "@b.@c.(b=e+d->c=e+d->b=c)";
  1981.          "@b.@c.(b=e+d->c=e+d->b=c)->@c.(a+e=e+d->c=e+d->a+e=c)";
  1982.          "@c.(a+e=e+d->c=e+d->a+e=c)";
  1983.          "@c.(a+e=e+d->c=e+d->a+e=c)->(a+e=e+d->d+e=e+d->a+e=d+e)";
  1984.          "a+e=e+d->d+e=e+d->a+e=d+e";
  1985.          "d+e=e+d->a+e=e+d->d+e=e+d";
  1986.          "a+e=e+d->d+e=e+d";
  1987.          "(a+e=e+d->d+e=e+d)->(a+e=e+d->d+e=e+d->a+e=d+e)->(a+e=e+d->a+e=d+e)";
  1988.          "(a+e=e+d->d+e=e+d->a+e=d+e)->(a+e=e+d->a+e=d+e)";
  1989.          "a+e=e+d->a+e=d+e";
  1990.          "(a+e=e+d->a+e=d+e)->e+a=e+d->(a+e=e+d->a+e=d+e)";
  1991.          "e+a=e+d->a+e=e+d->a+e=d+e";
  1992.          "(e+a=e+d->a+e=e+d)->(e+a=e+d->a+e=e+d->a+e=d+e)->(e+a=e+d->a+e=d+e)";
  1993.          "(e+a=e+d->a+e=e+d->a+e=d+e)->(e+a=e+d->a+e=d+e)";
  1994.          "e+a=e+d->a+e=d+e";
  1995.          "(a+e=d+e->a=d)->e+a=e+d->(a+e=d+e->a=d)";
  1996.          "e+a=e+d->a+e=d+e->a=d";
  1997.          "(e+a=e+d->a+e=d+e)->(e+a=e+d->a+e=d+e->a=d)->(e+a=e+d->a=d)";
  1998.          "(e+a=e+d->a+e=d+e->a=d)->(e+a=e+d->a=d)";
  1999.          "e+a=e+d->a=d";
  2000.          "(e+a=e+d->a=d)->0=0->(e+a=e+d->a=d)";
  2001.          "0=0->(e+a=e+d->a=d)";
  2002.          "0=0->@e.(e+a=e+d->a=d)";
  2003.          "0=0->@d.@e.(e+a=e+d->a=d)";
  2004.          "@d.@e.(e+a=e+d->a=d)";
  2005.          "@d.@e.(e+a=e+d->a=d)->@e.(e+a=e+b->a=b)";
  2006.          "@e.(e+a=e+b->a=b)";
  2007.          "@e.(e+a=e+b->a=b)->(c+a=c+b->a=b)";
  2008.          "c+a=c+b->a=b";
  2009.          "(c+a=c+b->a=b)->0=0->(c+a=c+b->a=b)";
  2010.          "0=0->(c+a=c+b->a=b)";
  2011.          "0=0->@c.(c+a=c+b->a=b)";
  2012.          "0=0->@b.@c.(c+a=c+b->a=b)";
  2013.          "0=0->@a.@b.@c.(c+a=c+b->a=b)";
  2014.          "@a.@b.@c.(c+a=c+b->a=b)"];;
  2015. let biggerFirstOrSecond = substractDoesntMatter @
  2016.         ["(0=0->a=e+d)->(0=0->!a=e+d)->!(0=0)";
  2017.          "((0=0->a=e+d)->(0=0->!a=e+d)->!(0=0))->a=e+d->((0=0->a=e+d)->(0=0->!a=e+d)->!(0=0))";
  2018.          "a=e+d->(0=0->a=e+d)->(0=0->!a=e+d)->!(0=0)";
  2019.          "a=e+d->0=0->a=e+d";
  2020.          "(a=e+d->0=0->a=e+d)->(a=e+d->(0=0->a=e+d)->(0=0->!a=e+d)->!(0=0))->(a=e+d->(0=0->!a=e+d)->!(0=0))";
  2021.          "(a=e+d->(0=0->a=e+d)->(0=0->!a=e+d)->!(0=0))->(a=e+d->(0=0->!a=e+d)->!(0=0))";
  2022.          "a=e+d->(0=0->!a=e+d)->!(0=0)";
  2023.          "(a=e+d->(0=0->!a=e+d)->!(0=0))->@e.!a=e+d->(a=e+d->(0=0->!a=e+d)->!(0=0))";
  2024.          "@e.!a=e+d->a=e+d->(0=0->!a=e+d)->!(0=0)";
  2025.          "@e.!a=e+d->!a=e+d";
  2026.          "!a=e+d->0=0->!a=e+d";
  2027.          "(!a=e+d->0=0->!a=e+d)->@e.!a=e+d->(!a=e+d->0=0->!a=e+d)";
  2028.          "@e.!a=e+d->!a=e+d->0=0->!a=e+d";
  2029.          "(@e.!a=e+d->!a=e+d)->(@e.!a=e+d->!a=e+d->0=0->!a=e+d)->(@e.!a=e+d->0=0->!a=e+d)";
  2030.          "(@e.!a=e+d->!a=e+d->0=0->!a=e+d)->(@e.!a=e+d->0=0->!a=e+d)";
  2031.          "@e.!a=e+d->0=0->!a=e+d";
  2032.          "(0=0->!a=e+d)->a=e+d->(0=0->!a=e+d)";
  2033.          "((0=0->!a=e+d)->a=e+d->(0=0->!a=e+d))->@e.!a=e+d->((0=0->!a=e+d)->a=e+d->(0=0->!a=e+d))";
  2034.          "@e.!a=e+d->(0=0->!a=e+d)->a=e+d->(0=0->!a=e+d)";
  2035.          "(@e.!a=e+d->0=0->!a=e+d)->(@e.!a=e+d->(0=0->!a=e+d)->a=e+d->(0=0->!a=e+d))->(@e.!a=e+d->a=e+d->(0=0->!a=e+d))";
  2036.          "(@e.!a=e+d->(0=0->!a=e+d)->a=e+d->(0=0->!a=e+d))->(@e.!a=e+d->a=e+d->(0=0->!a=e+d))";
  2037.          "@e.!a=e+d->a=e+d->0=0->!a=e+d";
  2038.          "(a=e+d->0=0->!a=e+d)->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0))";
  2039.          "((a=e+d->0=0->!a=e+d)->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0)))->@e.!a=e+d->((a=e+d->0=0->!a=e+d)->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0)))";
  2040.          "@e.!a=e+d->(a=e+d->0=0->!a=e+d)->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0))";
  2041.          "(@e.!a=e+d->a=e+d->0=0->!a=e+d)->(@e.!a=e+d->(a=e+d->0=0->!a=e+d)->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0)))->(@e.!a=e+d->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0)))";
  2042.          "(@e.!a=e+d->(a=e+d->0=0->!a=e+d)->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0)))->(@e.!a=e+d->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0)))";
  2043.          "@e.!a=e+d->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0))";
  2044.          "(@e.!a=e+d->a=e+d->(0=0->!a=e+d)->!(0=0))->(@e.!a=e+d->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0)))->(@e.!a=e+d->(a=e+d->!(0=0)))";
  2045.          "(@e.!a=e+d->(a=e+d->(0=0->!a=e+d)->!(0=0))->(a=e+d->!(0=0)))->(@e.!a=e+d->(a=e+d->!(0=0)))";
  2046.          "@e.!a=e+d->a=e+d->!(0=0)";
  2047.          "(@e.!a=e+d->a=e+d->!(0=0))->a=e+d->(@e.!a=e+d->a=e+d->!(0=0))";
  2048.          "a=e+d->@e.!a=e+d->a=e+d->!(0=0)";
  2049.          "a=e+d->@e.!a=e+d->a=e+d";
  2050.          "(@e.!a=e+d->a=e+d)->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0))";
  2051.          "((@e.!a=e+d->a=e+d)->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0)))->a=e+d->((@e.!a=e+d->a=e+d)->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0)))";
  2052.          "a=e+d->(@e.!a=e+d->a=e+d)->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0))";
  2053.          "(a=e+d->@e.!a=e+d->a=e+d)->(a=e+d->(@e.!a=e+d->a=e+d)->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0)))->(a=e+d->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0)))";
  2054.          "(a=e+d->(@e.!a=e+d->a=e+d)->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0)))->(a=e+d->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0)))";
  2055.          "a=e+d->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0))";
  2056.          "(a=e+d->@e.!a=e+d->a=e+d->!(0=0))->(a=e+d->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0)))->(a=e+d->(@e.!a=e+d->!(0=0)))";
  2057.          "(a=e+d->(@e.!a=e+d->a=e+d->!(0=0))->(@e.!a=e+d->!(0=0)))->(a=e+d->(@e.!a=e+d->!(0=0)))";
  2058.          "a=e+d->@e.!a=e+d->!(0=0)";
  2059.          "?e.a=e+d->@e.!a=e+d->!(0=0)";
  2060.          "(?e.a=e+d->@e.!a=e+d->!(0=0))->@e.!a=e+d->(?e.a=e+d->@e.!a=e+d->!(0=0))";
  2061.          "@e.!a=e+d->?e.a=e+d->@e.!a=e+d->!(0=0)";
  2062.          "@e.!a=e+d->?e.a=e+d->@e.!a=e+d";
  2063.          "(?e.a=e+d->@e.!a=e+d)->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0))";
  2064.          "((?e.a=e+d->@e.!a=e+d)->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0)))->@e.!a=e+d->((?e.a=e+d->@e.!a=e+d)->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0)))";
  2065.          "@e.!a=e+d->(?e.a=e+d->@e.!a=e+d)->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0))";
  2066.          "(@e.!a=e+d->?e.a=e+d->@e.!a=e+d)->(@e.!a=e+d->(?e.a=e+d->@e.!a=e+d)->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0)))->(@e.!a=e+d->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0)))";
  2067.          "(@e.!a=e+d->(?e.a=e+d->@e.!a=e+d)->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0)))->(@e.!a=e+d->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0)))";
  2068.          "@e.!a=e+d->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0))";
  2069.          "(@e.!a=e+d->?e.a=e+d->@e.!a=e+d->!(0=0))->(@e.!a=e+d->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0)))->(@e.!a=e+d->(?e.a=e+d->!(0=0)))";
  2070.          "(@e.!a=e+d->(?e.a=e+d->@e.!a=e+d->!(0=0))->(?e.a=e+d->!(0=0)))->(@e.!a=e+d->(?e.a=e+d->!(0=0)))";
  2071.          "@e.!a=e+d->?e.a=e+d->!(0=0)";
  2072.          "0=0->?e.a=e+d->0=0";
  2073.          "?e.a=e+d->0=0";
  2074.          "(?e.a=e+d->0=0)->(?e.a=e+d->!(0=0))->!?e.a=e+d";
  2075.          "(?e.a=e+d->!(0=0))->!?e.a=e+d";
  2076.          "((?e.a=e+d->!(0=0))->!?e.a=e+d)->@e.!a=e+d->((?e.a=e+d->!(0=0))->!?e.a=e+d)";
  2077.          "@e.!a=e+d->(?e.a=e+d->!(0=0))->!?e.a=e+d";
  2078.          "(@e.!a=e+d->?e.a=e+d->!(0=0))->(@e.!a=e+d->(?e.a=e+d->!(0=0))->!?e.a=e+d)->(@e.!a=e+d->!?e.a=e+d)";
  2079.          "(@e.!a=e+d->(?e.a=e+d->!(0=0))->!?e.a=e+d)->(@e.!a=e+d->!?e.a=e+d)";
  2080.          "@e.!a=e+d->!?e.a=e+d";
  2081.          "@a.@b.(a'+b=(a+b)')->@b.(e'+b=(e+b)')";
  2082.          "@b.(e'+b=(e+b)')";
  2083.          "@b.(e'+b=(e+b)')->(e'+d=(e+d)')";
  2084.          "e'+d=(e+d)'";
  2085.          "@a.@b.(a+b'=(a+b)')->@b.(e+b'=(e+b)')";
  2086.          "@b.(e+b'=(e+b)')";
  2087.          "@b.(e+b'=(e+b)')->(e+d'=(e+d)')";
  2088.          "e+d'=(e+d)'";
  2089.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=(e+d)'->c=(e+d)'->b=c)";
  2090.          "@b.@c.(b=(e+d)'->c=(e+d)'->b=c)";
  2091.          "@b.@c.(b=(e+d)'->c=(e+d)'->b=c)->@c.(e'+d=(e+d)'->c=(e+d)'->e'+d=c)";
  2092.          "@c.(e'+d=(e+d)'->c=(e+d)'->e'+d=c)";
  2093.          "@c.(e'+d=(e+d)'->c=(e+d)'->e'+d=c)->(e'+d=(e+d)'->e+d'=(e+d)'->e'+d=e+d')";
  2094.          "e'+d=(e+d)'->e+d'=(e+d)'->e'+d=e+d'";
  2095.          "e+d'=(e+d)'->e'+d=e+d'";
  2096.          "e'+d=e+d'";
  2097.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=e'+d->e'+d=c->b=c)";
  2098.          "@b.@c.(b=e'+d->e'+d=c->b=c)";
  2099.          "@b.@c.(b=e'+d->e'+d=c->b=c)->@c.(a=e'+d->e'+d=c->a=c)";
  2100.          "@c.(a=e'+d->e'+d=c->a=c)";
  2101.          "@c.(a=e'+d->e'+d=c->a=c)->(a=e'+d->e'+d=e+d'->a=e+d')";
  2102.          "a=e'+d->e'+d=e+d'->a=e+d'";
  2103.          "e'+d=e+d'->a=e'+d->e'+d=e+d'";
  2104.          "a=e'+d->e'+d=e+d'";
  2105.          "(a=e'+d->e'+d=e+d')->(a=e'+d->e'+d=e+d'->a=e+d')->(a=e'+d->a=e+d')";
  2106.          "(a=e'+d->e'+d=e+d'->a=e+d')->(a=e'+d->a=e+d')";
  2107.          "a=e'+d->a=e+d'";
  2108.          "a=e+d'->?e.(a=e+d')";
  2109.          "(a=e+d'->?e.(a=e+d'))->a=e'+d->(a=e+d'->?e.(a=e+d'))";
  2110.          "a=e'+d->a=e+d'->?e.(a=e+d')";
  2111.          "(a=e'+d->a=e+d')->(a=e'+d->a=e+d'->?e.(a=e+d'))->(a=e'+d->?e.(a=e+d'))";
  2112.          "(a=e'+d->a=e+d'->?e.(a=e+d'))->(a=e'+d->?e.(a=e+d'))";
  2113.          "a=e'+d->?e.(a=e+d')";
  2114.          "!?e.(a=e+d')->a=e'+d->!?e.(a=e+d')";
  2115.          "(a=e'+d->?e.(a=e+d'))->!?e.(a=e+d')->(a=e'+d->?e.(a=e+d'))";
  2116.          "!?e.(a=e+d')->a=e'+d->?e.(a=e+d')";
  2117.          "(a=e'+d->?e.(a=e+d'))->(a=e'+d->!?e.(a=e+d'))->!a=e'+d";
  2118.          "((a=e'+d->?e.(a=e+d'))->(a=e'+d->!?e.(a=e+d'))->!a=e'+d)->!?e.(a=e+d')->((a=e'+d->?e.(a=e+d'))->(a=e'+d->!?e.(a=e+d'))->!a=e'+d)";
  2119.          "!?e.(a=e+d')->(a=e'+d->?e.(a=e+d'))->(a=e'+d->!?e.(a=e+d'))->!a=e'+d";
  2120.          "(!?e.(a=e+d')->a=e'+d->?e.(a=e+d'))->(!?e.(a=e+d')->(a=e'+d->?e.(a=e+d'))->(a=e'+d->!?e.(a=e+d'))->!a=e'+d)->(!?e.(a=e+d')->(a=e'+d->!?e.(a=e+d'))->!a=e'+d)";
  2121.          "(!?e.(a=e+d')->(a=e'+d->?e.(a=e+d'))->(a=e'+d->!?e.(a=e+d'))->!a=e'+d)->(!?e.(a=e+d')->(a=e'+d->!?e.(a=e+d'))->!a=e'+d)";
  2122.          "!?e.(a=e+d')->(a=e'+d->!?e.(a=e+d'))->!a=e'+d";
  2123.          "(!?e.(a=e+d')->a=e'+d->!?e.(a=e+d'))->(!?e.(a=e+d')->(a=e'+d->!?e.(a=e+d'))->!a=e'+d)->(!?e.(a=e+d')->!a=e'+d)";
  2124.          "(!?e.(a=e+d')->(a=e'+d->!?e.(a=e+d'))->!a=e'+d)->(!?e.(a=e+d')->!a=e'+d)";
  2125.          "!?e.(a=e+d')->!a=e'+d";
  2126.          "(!a=e'+d->!a=e+d->!a=e'+d)->!?e.(a=e+d')->(!a=e'+d->!a=e+d->!a=e'+d)";
  2127.          "!a=e'+d->!a=e+d->!a=e'+d";
  2128.          "!?e.(a=e+d')->!a=e'+d->!a=e+d->!a=e'+d";
  2129.          "(!?e.(a=e+d')->!a=e'+d)->(!?e.(a=e+d')->!a=e'+d->!a=e+d->!a=e'+d)->(!?e.(a=e+d')->!a=e+d->!a=e'+d)";
  2130.          "(!?e.(a=e+d')->!a=e'+d->!a=e+d->!a=e'+d)->(!?e.(a=e+d')->!a=e+d->!a=e'+d)";
  2131.          "!?e.(a=e+d')->!a=e+d->!a=e'+d";
  2132.          "!?e.(a=e+d')->@e.(!a=e+d->!a=e'+d)";
  2133.          "!a=0+d->@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)";
  2134.          "!a=0+d&@e.(!a=e+d->!a=e'+d)->!a=e+d";
  2135.          "!a=0+d&@e.(!a=e+d->!a=e'+d)->@e.!a=e+d";
  2136.          "(@e.!a=e+d->!?e.a=e+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->(@e.!a=e+d->!?e.a=e+d)";
  2137.          "!a=0+d&@e.(!a=e+d->!a=e'+d)->@e.!a=e+d->!?e.a=e+d";
  2138.          "(!a=0+d&@e.(!a=e+d->!a=e'+d)->@e.!a=e+d)->(!a=0+d&@e.(!a=e+d->!a=e'+d)->@e.!a=e+d->!?e.a=e+d)->(!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)";
  2139.          "(!a=0+d&@e.(!a=e+d->!a=e'+d)->@e.!a=e+d->!?e.a=e+d)->(!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)";
  2140.          "!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d";
  2141.          "(!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->@e.(!a=e+d->!a=e'+d)->(!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)";
  2142.          "@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d";
  2143.          "(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->!a=0+d->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)";
  2144.          "!a=0+d->@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d";
  2145.          "(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d))->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)";
  2146.          "((@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d))->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))->!a=0+d->((@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d))->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))";
  2147.          "!a=0+d->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d))->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)";
  2148.          "(!a=0+d->@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d))->(!a=0+d->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d))->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))->(!a=0+d->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))";
  2149.          "(!a=0+d->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d))->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))->(!a=0+d->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))";
  2150.          "!a=0+d->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)";
  2151.          "(!a=0+d->@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))->(!a=0+d->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))";
  2152.          "(!a=0+d->(@e.(!a=e+d->!a=e'+d)->!a=0+d&@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))->(!a=0+d->(@e.(!a=e+d->!a=e'+d)->!?e.a=e+d))";
  2153.          "!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d";
  2154.          "(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->@e.(!a=e+d->!a=e'+d)->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)";
  2155.          "@e.(!a=e+d->!a=e'+d)->!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d";
  2156.          "@e.(!a=e+d->!a=e'+d)->!a=0+d->@e.(!a=e+d->!a=e'+d)";
  2157.          "(!a=0+d->@e.(!a=e+d->!a=e'+d))->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d)";
  2158.          "((!a=0+d->@e.(!a=e+d->!a=e'+d))->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d))->@e.(!a=e+d->!a=e'+d)->((!a=0+d->@e.(!a=e+d->!a=e'+d))->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d))";
  2159.          "@e.(!a=e+d->!a=e'+d)->(!a=0+d->@e.(!a=e+d->!a=e'+d))->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d)";
  2160.          "(@e.(!a=e+d->!a=e'+d)->!a=0+d->@e.(!a=e+d->!a=e'+d))->(@e.(!a=e+d->!a=e'+d)->(!a=0+d->@e.(!a=e+d->!a=e'+d))->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d))->(@e.(!a=e+d->!a=e'+d)->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d))";
  2161.          "(@e.(!a=e+d->!a=e'+d)->(!a=0+d->@e.(!a=e+d->!a=e'+d))->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d))->(@e.(!a=e+d->!a=e'+d)->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d))";
  2162.          "@e.(!a=e+d->!a=e'+d)->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d)";
  2163.          "(@e.(!a=e+d->!a=e'+d)->!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(@e.(!a=e+d->!a=e'+d)->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d))->(@e.(!a=e+d->!a=e'+d)->(!a=0+d->!?e.a=e+d))";
  2164.          "(@e.(!a=e+d->!a=e'+d)->(!a=0+d->@e.(!a=e+d->!a=e'+d)->!?e.a=e+d)->(!a=0+d->!?e.a=e+d))->(@e.(!a=e+d->!a=e'+d)->(!a=0+d->!?e.a=e+d))";
  2165.          "@e.(!a=e+d->!a=e'+d)->!a=0+d->!?e.a=e+d";
  2166.          "(@e.(!a=e+d->!a=e'+d)->!a=0+d->!?e.a=e+d)->!?e.(a=e+d')->(@e.(!a=e+d->!a=e'+d)->!a=0+d->!?e.a=e+d)";
  2167.          "!?e.(a=e+d')->@e.(!a=e+d->!a=e'+d)->!a=0+d->!?e.a=e+d";
  2168.          "(!?e.(a=e+d')->@e.(!a=e+d->!a=e'+d))->(!?e.(a=e+d')->@e.(!a=e+d->!a=e'+d)->!a=0+d->!?e.a=e+d)->(!?e.(a=e+d')->!a=0+d->!?e.a=e+d)";
  2169.          "(!?e.(a=e+d')->@e.(!a=e+d->!a=e'+d)->!a=0+d->!?e.a=e+d)->(!?e.(a=e+d')->!a=0+d->!?e.a=e+d)";
  2170.          "!?e.(a=e+d')->!a=0+d->!?e.a=e+d";
  2171.          "(!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d";
  2172.          "((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->(!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)";
  2173.          "(!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d";
  2174.          "(!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)";
  2175.          "((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d))->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d)";
  2176.          "(((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d))->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))->(!a=0+d->!?e.a=e+d)->(((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d))->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))";
  2177.          "(!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d))->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d)";
  2178.          "((!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d))->((!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d))->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))->((!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))";
  2179.          "((!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d))->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))->((!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))";
  2180.          "(!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d)";
  2181.          "((!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))->((!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))";
  2182.          "((!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->(!a=0+d->!?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))->((!a=0+d->!?e.a=e+d)->((!a=0+d->?e.a=e+d)->!!a=0+d))";
  2183.          "(!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->!!a=0+d";
  2184.          "((!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->!!a=0+d)->!?e.(a=e+d')->((!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->!!a=0+d)";
  2185.          "!?e.(a=e+d')->(!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->!!a=0+d";
  2186.          "(!?e.(a=e+d')->!a=0+d->!?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)";
  2187.          "(!?e.(a=e+d')->(!a=0+d->!?e.a=e+d)->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)";
  2188.          "!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d";
  2189.          "(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)";
  2190.          "(!a=0+d->?e.a=e+d)->!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d";
  2191.          "(!a=0+d->?e.a=e+d)->!?e.(a=e+d')->(!a=0+d->?e.a=e+d)";
  2192.          "(!?e.(a=e+d')->(!a=0+d->?e.a=e+d))->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d)";
  2193.          "((!?e.(a=e+d')->(!a=0+d->?e.a=e+d))->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d))->(!a=0+d->?e.a=e+d)->((!?e.(a=e+d')->(!a=0+d->?e.a=e+d))->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d))";
  2194.          "(!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d))->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d)";
  2195.          "((!a=0+d->?e.a=e+d)->!?e.(a=e+d')->(!a=0+d->?e.a=e+d))->((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d))->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d))->((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d))";
  2196.          "((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d))->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d))->((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d))";
  2197.          "(!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d)";
  2198.          "((!a=0+d->?e.a=e+d)->!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d))->((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->!!a=0+d))";
  2199.          "((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->(!a=0+d->?e.a=e+d)->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d))->((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->!!a=0+d))";
  2200.          "(!a=0+d->?e.a=e+d)->!?e.(a=e+d')->!!a=0+d";
  2201.          "((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->!!a=0+d))->?e.a=e+d->((!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->!!a=0+d))";
  2202.          "?e.a=e+d->(!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->!!a=0+d)";
  2203.          "?e.a=e+d->!a=0+d->?e.a=e+d";
  2204.          "(?e.a=e+d->!a=0+d->?e.a=e+d)->(?e.a=e+d->(!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->!!a=0+d))->(?e.a=e+d->(!?e.(a=e+d')->!!a=0+d))";
  2205.          "(?e.a=e+d->(!a=0+d->?e.a=e+d)->(!?e.(a=e+d')->!!a=0+d))->(?e.a=e+d->(!?e.(a=e+d')->!!a=0+d))";
  2206.          "?e.a=e+d->!?e.(a=e+d')->!!a=0+d";
  2207.          "!!a=0+d->a=0+d";
  2208.          "@a.(0+a=a)->0+d=d";
  2209.          "0+d=d";
  2210.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=0+d->0+d=c->b=c)";
  2211.          "@b.@c.(b=0+d->0+d=c->b=c)";
  2212.          "@b.@c.(b=0+d->0+d=c->b=c)->@c.(a=0+d->0+d=c->a=c)";
  2213.          "@c.(a=0+d->0+d=c->a=c)";
  2214.          "@c.(a=0+d->0+d=c->a=c)->(a=0+d->0+d=d->a=d)";
  2215.          "a=0+d->0+d=d->a=d";
  2216.          "0+d=d->a=0+d->0+d=d";
  2217.          "a=0+d->0+d=d";
  2218.          "(a=0+d->0+d=d)->(a=0+d->0+d=d->a=d)->(a=0+d->a=d)";
  2219.          "(a=0+d->0+d=d->a=d)->(a=0+d->a=d)";
  2220.          "a=0+d->a=d";
  2221.          "(a=0+d->a=d)->!!a=0+d->(a=0+d->a=d)";
  2222.          "!!a=0+d->a=0+d->a=d";
  2223.          "(!!a=0+d->a=0+d)->(!!a=0+d->a=0+d->a=d)->(!!a=0+d->a=d)";
  2224.          "(!!a=0+d->a=0+d->a=d)->(!!a=0+d->a=d)";
  2225.          "!!a=0+d->a=d";
  2226.          "@a.@b.(a=b->a'=b')->@b.(a=b->a'=b')";
  2227.          "@b.(a=b->a'=b')";
  2228.          "@b.(a=b->a'=b')->(a=d->a'=d')";
  2229.          "a=d->a'=d'";
  2230.          "(a=d->a'=d')->!!a=0+d->(a=d->a'=d')";
  2231.          "!!a=0+d->a=d->a'=d'";
  2232.          "(!!a=0+d->a=d)->(!!a=0+d->a=d->a'=d')->(!!a=0+d->a'=d')";
  2233.          "(!!a=0+d->a=d->a'=d')->(!!a=0+d->a'=d')";
  2234.          "!!a=0+d->a'=d'";
  2235.          "a+0=a";
  2236.          "@a.@b.(a=b->a'=b')->@b.(a+0=b->(a+0)'=b')";
  2237.          "@b.(a+0=b->(a+0)'=b')";
  2238.          "@b.(a+0=b->(a+0)'=b')->(a+0=a->(a+0)'=a')";
  2239.          "a+0=a->(a+0)'=a'";
  2240.          "(a+0)'=a'";
  2241.          "@a.@b.(a+b'=(a+b)')->@b.(a+b'=(a+b)')";
  2242.          "@b.(a+b'=(a+b)')";
  2243.          "@b.(a+b'=(a+b)')->(a+0'=(a+0)')";
  2244.          "a+0'=(a+0)'";
  2245.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(a+0)'->(a+0)'=c->b=c)";
  2246.          "@b.@c.(b=(a+0)'->(a+0)'=c->b=c)";
  2247.          "@b.@c.(b=(a+0)'->(a+0)'=c->b=c)->@c.(a+0'=(a+0)'->(a+0)'=c->a+0'=c)";
  2248.          "@c.(a+0'=(a+0)'->(a+0)'=c->a+0'=c)";
  2249.          "@c.(a+0'=(a+0)'->(a+0)'=c->a+0'=c)->(a+0'=(a+0)'->(a+0)'=a'->a+0'=a')";
  2250.          "a+0'=(a+0)'->(a+0)'=a'->a+0'=a'";
  2251.          "(a+0)'=a'->a+0'=a'";
  2252.          "a+0'=a'";
  2253.          "a+0'=a'->0=0->a+0'=a'";
  2254.          "0=0->(a+0'=a')";
  2255.          "0=0->@a.(a+0'=a')";
  2256.          "@a.(a+0'=a')";
  2257.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=a'->a'=c->b=c)";
  2258.          "@b.@c.(b=a'->a'=c->b=c)";
  2259.          "@b.@c.(b=a'->a'=c->b=c)->@c.(a+0'=a'->a'=c->a+0'=c)";
  2260.          "@c.(a+0'=a'->a'=c->a+0'=c)";
  2261.          "@c.(a+0'=a'->a'=c->a+0'=c)->(a+0'=a'->a'=d'->a+0'=d')";
  2262.          "a+0'=a'->a'=d'->a+0'=d'";
  2263.          "a'=d'->a+0'=d'";
  2264.          "(a'=d'->a+0'=d')->!!a=0+d->(a'=d'->a+0'=d')";
  2265.          "!!a=0+d->a'=d'->a+0'=d'";
  2266.          "(!!a=0+d->a'=d')->(!!a=0+d->a'=d'->a+0'=d')->(!!a=0+d->a+0'=d')";
  2267.          "(!!a=0+d->a'=d'->a+0'=d')->(!!a=0+d->a+0'=d')";
  2268.          "!!a=0+d->a+0'=d'";
  2269.          "a+0'=d'->?e.a+e=d'";
  2270.          "(a+0'=d'->?e.a+e=d')->!!a=0+d->(a+0'=d'->?e.a+e=d')";
  2271.          "!!a=0+d->a+0'=d'->?e.a+e=d'";
  2272.          "(!!a=0+d->a+0'=d')->(!!a=0+d->a+0'=d'->?e.a+e=d')->(!!a=0+d->?e.a+e=d')";
  2273.          "(!!a=0+d->a+0'=d'->?e.a+e=d')->(!!a=0+d->?e.a+e=d')";
  2274.          "!!a=0+d->?e.a+e=d'";
  2275.          "?e.a+e=d'->?e.a=e+d'|?e.a+e=d'";
  2276.          "(?e.a+e=d'->?e.a=e+d'|?e.a+e=d')->!!a=0+d->(?e.a+e=d'->?e.a=e+d'|?e.a+e=d')";
  2277.          "!!a=0+d->?e.a+e=d'->?e.a=e+d'|?e.a+e=d'";
  2278.          "(!!a=0+d->?e.a+e=d')->(!!a=0+d->?e.a+e=d'->?e.a=e+d'|?e.a+e=d')->(!!a=0+d->?e.a=e+d'|?e.a+e=d')";
  2279.          "(!!a=0+d->?e.a+e=d'->?e.a=e+d'|?e.a+e=d')->(!!a=0+d->?e.a=e+d'|?e.a+e=d')";
  2280.          "!!a=0+d->?e.a=e+d'|?e.a+e=d'";
  2281.          "(!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->!?e.(a=e+d')->(!!a=0+d->(?e.a=e+d'|?e.a+e=d'))";
  2282.          "!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d')";
  2283.          "(!?e.(a=e+d')->(!!a=0+d->(?e.a=e+d'|?e.a+e=d')))->?e.a=e+d->(!?e.(a=e+d')->(!!a=0+d->(?e.a=e+d'|?e.a+e=d')))";
  2284.          "?e.a=e+d->!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d')";
  2285.          "(!?e.(a=e+d')->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d'))";
  2286.          "((!?e.(a=e+d')->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))->?e.a=e+d->((!?e.(a=e+d')->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))";
  2287.          "?e.a=e+d->(!?e.(a=e+d')->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d'))";
  2288.          "(?e.a=e+d->!?e.(a=e+d')->!!a=0+d)->(?e.a=e+d->(!?e.(a=e+d')->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))->(?e.a=e+d->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))";
  2289.          "(?e.a=e+d->(!?e.(a=e+d')->!!a=0+d)->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))->(?e.a=e+d->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))";
  2290.          "?e.a=e+d->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d'))";
  2291.          "(?e.a=e+d->!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(?e.a=e+d->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))->(?e.a=e+d->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))";
  2292.          "(?e.a=e+d->(!?e.(a=e+d')->!!a=0+d->(?e.a=e+d'|?e.a+e=d'))->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))->(?e.a=e+d->(!?e.(a=e+d')->(?e.a=e+d'|?e.a+e=d')))";
  2293.          "?e.a=e+d->!?e.a=e+d'->?e.a=e+d'|?e.a+e=d'";
  2294.          "@a.@b.(a=b->a'=b')->@b.(a+e=b->(a+e)'=b')";
  2295.          "@b.(a+e=b->(a+e)'=b')";
  2296.          "@b.(a+e=b->(a+e)'=b')->(a+e=d->(a+e)'=d')";
  2297.          "a+e=d->(a+e)'=d'";
  2298.          "@a.@b.(a+b'=(a+b)')->@b.(a+b'=(a+b)')";
  2299.          "@b.(a+b'=(a+b)')";
  2300.          "@b.(a+b'=(a+b)')->(a+e'=(a+e)')";
  2301.          "a+e'=(a+e)'";
  2302.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(a+e)'->(a+e)'=c->b=c)";
  2303.          "@b.@c.(b=(a+e)'->(a+e)'=c->b=c)";
  2304.          "@b.@c.(b=(a+e)'->(a+e)'=c->b=c)->@c.(a+e'=(a+e)'->(a+e)'=c->a+e'=c)";
  2305.          "@c.(a+e'=(a+e)'->(a+e)'=c->a+e'=c)";
  2306.          "@c.(a+e'=(a+e)'->(a+e)'=c->a+e'=c)->(a+e'=(a+e)'->(a+e)'=d'->a+e'=d')";
  2307.          "a+e'=(a+e)'->(a+e)'=d'->a+e'=d'";
  2308.          "(a+e)'=d'->a+e'=d'";
  2309.          "((a+e)'=d'->a+e'=d')->a+e=d->((a+e)'=d'->a+e'=d')";
  2310.          "a+e=d->(a+e)'=d'->a+e'=d'";
  2311.          "(a+e=d->(a+e)'=d')->(a+e=d->(a+e)'=d'->a+e'=d')->(a+e=d->a+e'=d')";
  2312.          "(a+e=d->(a+e)'=d'->a+e'=d')->(a+e=d->a+e'=d')";
  2313.          "a+e=d->a+e'=d'";
  2314.          "a+e'=d'->?e.(a+e=d')";
  2315.          "(a+e'=d'->?e.(a+e=d'))->a+e=d->(a+e'=d'->?e.(a+e=d'))";
  2316.          "a+e=d->a+e'=d'->?e.(a+e=d')";
  2317.          "(a+e=d->a+e'=d')->(a+e=d->a+e'=d'->?e.(a+e=d'))->(a+e=d->?e.(a+e=d'))";
  2318.          "(a+e=d->a+e'=d'->?e.(a+e=d'))->(a+e=d->?e.(a+e=d'))";
  2319.          "a+e=d->?e.(a+e=d')";
  2320.          "?e.a+e=d->?e.a+e=d'";
  2321.          "?e.a=e+d'->?e.a=e+d'|?e.a+e=d'";
  2322.          "?e.a=e+d'->?e.a=e+d'|!?e.a=e+d'";
  2323.          "(?e.a=e+d'->?e.a=e+d'|!?e.a=e+d')->(?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!?e.a=e+d'";
  2324.          "(?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!?e.a=e+d'";
  2325.          "((?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!?e.a=e+d')->!(?e.a=e+d'|!?e.a=e+d')->((?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!?e.a=e+d')";
  2326.          "!(?e.a=e+d'|!?e.a=e+d')->(?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!?e.a=e+d'";
  2327.          "!(?e.a=e+d'|!?e.a=e+d')->?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d')";
  2328.          "(!(?e.a=e+d'|!?e.a=e+d')->?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->(!(?e.a=e+d'|!?e.a=e+d')->(?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!?e.a=e+d')->(!(?e.a=e+d'|!?e.a=e+d')->!?e.a=e+d')";
  2329.          "(!(?e.a=e+d'|!?e.a=e+d')->(?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!?e.a=e+d')->(!(?e.a=e+d'|!?e.a=e+d')->!?e.a=e+d')";
  2330.          "!(?e.a=e+d'|!?e.a=e+d')->!?e.a=e+d'";
  2331.          "!?e.a=e+d'->?e.a=e+d'|!?e.a=e+d'";
  2332.          "(!?e.a=e+d'->?e.a=e+d'|!?e.a=e+d')->(!?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!!?e.a=e+d'";
  2333.          "(!?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!!?e.a=e+d'";
  2334.          "((!?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!!?e.a=e+d')->!(?e.a=e+d'|!?e.a=e+d')->((!?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!!?e.a=e+d')";
  2335.          "!(?e.a=e+d'|!?e.a=e+d')->(!?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!!?e.a=e+d'";
  2336.          "!(?e.a=e+d'|!?e.a=e+d')->!?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d')";
  2337.          "(!(?e.a=e+d'|!?e.a=e+d')->!?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->(!(?e.a=e+d'|!?e.a=e+d')->(!?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!!?e.a=e+d')->(!(?e.a=e+d'|!?e.a=e+d')->!!?e.a=e+d')";
  2338.          "(!(?e.a=e+d'|!?e.a=e+d')->(!?e.a=e+d'->!(?e.a=e+d'|!?e.a=e+d'))->!!?e.a=e+d')->(!(?e.a=e+d'|!?e.a=e+d')->!!?e.a=e+d')";
  2339.          "!(?e.a=e+d'|!?e.a=e+d')->!!?e.a=e+d'";
  2340.          "(!(?e.a=e+d'|!?e.a=e+d')->!?e.a=e+d')->(!(?e.a=e+d'|!?e.a=e+d')->!!?e.a=e+d')->!!(?e.a=e+d'|!?e.a=e+d')";
  2341.          "(!(?e.a=e+d'|!?e.a=e+d')->!!?e.a=e+d')->!!(?e.a=e+d'|!?e.a=e+d')";
  2342.          "!!(?e.a=e+d'|!?e.a=e+d')";
  2343.          "!!(?e.a=e+d'|!?e.a=e+d')->?e.a=e+d'|!?e.a=e+d'";
  2344.          "?e.a=e+d'|!?e.a=e+d'";
  2345.          "(?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')";
  2346.          "(!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')";
  2347.          "((!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d'))->?e.a=e+d->((!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d'))";
  2348.          "?e.a=e+d->(!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')";
  2349.          "(?e.a=e+d->!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d->(!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d'))->(?e.a=e+d->(?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d'))";
  2350.          "(?e.a=e+d->(!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d'))->(?e.a=e+d->(?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d'))";
  2351.          "?e.a=e+d->?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d'";
  2352.          "?e.a=e+d'|!?e.a=e+d'->?e.a=e+d->?e.a=e+d'|!?e.a=e+d'";
  2353.          "?e.a=e+d->?e.a=e+d'|!?e.a=e+d'";
  2354.          "(?e.a=e+d->?e.a=e+d'|!?e.a=e+d')->(?e.a=e+d->?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d->?e.a=e+d'|?e.a+e=d')";
  2355.          "(?e.a=e+d->?e.a=e+d'|!?e.a=e+d'->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d->?e.a=e+d'|?e.a+e=d')";
  2356.          "?e.a=e+d->?e.a=e+d'|?e.a+e=d'";
  2357.          "?e.a+e=d'->?e.a=e+d'|?e.a+e=d'";
  2358.          "(?e.a+e=d'->?e.a=e+d'|?e.a+e=d')->?e.a+e=d->(?e.a+e=d'->?e.a=e+d'|?e.a+e=d')";
  2359.          "?e.a+e=d->?e.a+e=d'->?e.a=e+d'|?e.a+e=d'";
  2360.          "(?e.a+e=d->?e.a+e=d')->(?e.a+e=d->?e.a+e=d'->?e.a=e+d'|?e.a+e=d')->(?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2361.          "(?e.a+e=d->?e.a+e=d'->?e.a=e+d'|?e.a+e=d')->(?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2362.          "?e.a+e=d->?e.a=e+d'|?e.a+e=d'";
  2363.          "(?e.a=e+d->?e.a=e+d'|?e.a+e=d')->(?e.a+e=d->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2364.          "(?e.a+e=d->?e.a=e+d'|?e.a+e=d')->(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2365.          "?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d'";
  2366.          "(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')->0=0->(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2367.          "0=0->(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2368.          "0=0->@d.(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2369.          "@d.(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2370.          "@a.@b.(a=b->b=a)->@b.(a+0=b->b=a+0)";
  2371.          "@b.(a+0=b->b=a+0)";
  2372.          "@b.(a+0=b->b=a+0)->(a+0=a->a=a+0)";
  2373.          "a+0=a->a=a+0";
  2374.          "a=a+0";
  2375.          "a=a+0->?e.a=e+0";
  2376.          "?e.a=e+0";
  2377.          "?e.a=e+0->?e.a=e+0|?e.a+e=0";
  2378.          "?e.a=e+0|?e.a+e=0";
  2379.          "?e.a=e+0|?e.a+e=0->@d.(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')->(?e.a=e+0|?e.a+e=0)&@d.(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2380.          "@d.(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')->(?e.a=e+0|?e.a+e=0)&@d.(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2381.          "(?e.a=e+0|?e.a+e=0)&@d.(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')";
  2382.          "(?e.a=e+0|?e.a+e=0)&@d.(?e.a=e+d|?e.a+e=d->?e.a=e+d'|?e.a+e=d')->?e.a=e+d|?e.a+e=d";
  2383.          "?e.a=e+d|?e.a+e=d";
  2384.          "(?e.a=e+d|?e.a+e=d)->0=0->(?e.a=e+d|?e.a+e=d)";
  2385.          "0=0->(?e.a=e+d|?e.a+e=d)";
  2386.          "0=0->@d.(?e.a=e+d|?e.a+e=d)";
  2387.          "@d.(?e.a=e+d|?e.a+e=d)";
  2388.          "@d.(?e.a=e+d|?e.a+e=d)->(?e.a=e+b|?e.a+e=b)";
  2389.          "?e.a=e+b|?e.a+e=b";
  2390.          "(?e.a=e+b|?e.a+e=b)->0=0->(?e.a=e+b|?e.a+e=b)";
  2391.          "0=0->(?e.a=e+b|?e.a+e=b)";
  2392.          "0=0->@b.(?e.a=e+b|?e.a+e=b)";
  2393.          "0=0->@a.@b.(?e.a=e+b|?e.a+e=b)";
  2394.          "@a.@b.(?e.a=e+b|?e.a+e=b)"];;
  2395. let twoMulANeqOne = biggerFirstOrSecond @
  2396.         ["@a.@b.(a*b'=a*b+a)->@b.(0''*b'=0''*b+0'')";
  2397.          "@b.(0''*b'=0''*b+0'')";
  2398.          "@b.(0''*b'=0''*b+0'')->(0''*a'=0''*a+0'')";
  2399.          "0''*a'=0''*a+0''";
  2400.          "@a.@b.(a+b'=(a+b)')->@b.(0''*a+b'=(0''*a+b)')";
  2401.          "@b.(0''*a+b'=(0''*a+b)')";
  2402.          "@b.(0''*a+b'=(0''*a+b)')->(0''*a+0''=(0''*a+0')')";
  2403.          "0''*a+0''=(0''*a+0')'";
  2404.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=0''*a+0''->0''*a+0''=c->b=c)";
  2405.          "@b.@c.(b=0''*a+0''->0''*a+0''=c->b=c)";
  2406.          "@b.@c.(b=0''*a+0''->0''*a+0''=c->b=c)->@c.(0''*a'=0''*a+0''->0''*a+0''=c->0''*a'=c)";
  2407.          "@c.(0''*a'=0''*a+0''->0''*a+0''=c->0''*a'=c)";
  2408.          "@c.(0''*a'=0''*a+0''->0''*a+0''=c->0''*a'=c)->(0''*a'=0''*a+0''->0''*a+0''=(0''*a+0')'->0''*a'=(0''*a+0')')";
  2409.          "0''*a'=0''*a+0''->0''*a+0''=(0''*a+0')'->0''*a'=(0''*a+0')'";
  2410.          "0''*a+0''=(0''*a+0')'->0''*a'=(0''*a+0')'";
  2411.          "0''*a'=(0''*a+0')'";
  2412.          "@a.@b.(a+b'=(a+b)')->@b.(0''*a+b'=(0''*a+b)')";
  2413.          "@b.(0''*a+b'=(0''*a+b)')";
  2414.          "@b.(0''*a+b'=(0''*a+b)')->(0''*a+0'=(0''*a+0)')";
  2415.          "0''*a+0'=(0''*a+0)'";
  2416.          "@a.@b.(a=b->a'=b')->@b.(0''*a+0'=b->(0''*a+0')'=b')";
  2417.          "@b.(0''*a+0'=b->(0''*a+0')'=b')";
  2418.          "@b.(0''*a+0'=b->(0''*a+0')'=b')->(0''*a+0'=(0''*a+0)'->(0''*a+0')'=(0''*a+0)'')";
  2419.          "0''*a+0'=(0''*a+0)'->(0''*a+0')'=(0''*a+0)''";
  2420.          "(0''*a+0')'=(0''*a+0)''";
  2421.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(0''*a+0')'->(0''*a+0')'=c->b=c)";
  2422.          "@b.@c.(b=(0''*a+0')'->(0''*a+0')'=c->b=c)";
  2423.          "@b.@c.(b=(0''*a+0')'->(0''*a+0')'=c->b=c)->@c.(0''*a'=(0''*a+0')'->(0''*a+0')'=c->0''*a'=c)";
  2424.          "@c.(0''*a'=(0''*a+0')'->(0''*a+0')'=c->0''*a'=c)";
  2425.          "@c.(0''*a'=(0''*a+0')'->(0''*a+0')'=c->0''*a'=c)->(0''*a'=(0''*a+0')'->(0''*a+0')'=(0''*a+0)''->0''*a'=(0''*a+0)'')";
  2426.          "0''*a'=(0''*a+0')'->(0''*a+0')'=(0''*a+0)''->0''*a'=(0''*a+0)''";
  2427.          "(0''*a+0')'=(0''*a+0)''->0''*a'=(0''*a+0)''";
  2428.          "0''*a'=(0''*a+0)''";
  2429.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(0''*a'=b->0''*a'=c->b=c)";
  2430.          "@b.@c.(0''*a'=b->0''*a'=c->b=c)";
  2431.          "@b.@c.(0''*a'=b->0''*a'=c->b=c)->@c.(0''*a'=(0''*a+0)''->0''*a'=c->(0''*a+0)''=c)";
  2432.          "@c.(0''*a'=(0''*a+0)''->0''*a'=c->(0''*a+0)''=c)";
  2433.          "@c.(0''*a'=(0''*a+0)''->0''*a'=c->(0''*a+0)''=c)->(0''*a'=(0''*a+0)''->0''*a'=0'->(0''*a+0)''=0')";
  2434.          "0''*a'=(0''*a+0)''->0''*a'=0'->(0''*a+0)''=0'";
  2435.          "0''*a'=0'->(0''*a+0)''=0'";
  2436.          "@a.@b.(a'=b'->a=b)->@b.((0''*a+0)''=b'->(0''*a+0)'=b)";
  2437.          "@b.((0''*a+0)''=b'->(0''*a+0)'=b)";
  2438.          "@b.((0''*a+0)''=b'->(0''*a+0)'=b)->((0''*a+0)''=0'->(0''*a+0)'=0)";
  2439.          "(0''*a+0)''=0'->(0''*a+0)'=0";
  2440.          "((0''*a+0)''=0'->(0''*a+0)'=0)->0''*a'=0'->((0''*a+0)''=0'->(0''*a+0)'=0)";
  2441.          "0''*a'=0'->(0''*a+0)''=0'->(0''*a+0)'=0";
  2442.          "(0''*a'=0'->(0''*a+0)''=0')->(0''*a'=0'->(0''*a+0)''=0'->(0''*a+0)'=0)->(0''*a'=0'->(0''*a+0)'=0)";
  2443.          "(0''*a'=0'->(0''*a+0)''=0'->(0''*a+0)'=0)->(0''*a'=0'->(0''*a+0)'=0)";
  2444.          "0''*a'=0'->(0''*a+0)'=0";
  2445.          "!(a'=0)";
  2446.          "!(a'=0)->0=0->!(a'=0)";
  2447.          "0=0->!(a'=0)";
  2448.          "0=0->@a.!(a'=0)";
  2449.          "@a.!(a'=0)";
  2450.          "@a.!(a'=0)->!((0''*a+0)'=0)";
  2451.          "!((0''*a+0)'=0)";
  2452.          "!((0''*a+0)'=0)->0''*a'=0'->!((0''*a+0)'=0)";
  2453.          "0''*a'=0'->!((0''*a+0)'=0)";
  2454.          "(0''*a'=0'->(0''*a+0)'=0)->(0''*a'=0'->!(0''*a+0)'=0)->!0''*a'=0'";
  2455.          "(0''*a'=0'->!(0''*a+0)'=0)->!0''*a'=0'";
  2456.          "!0''*a'=0'";
  2457.          "!0''*a'=0'->!0''*a=0'->!0''*a'=0'";
  2458.          "!0''*a=0'->!0''*a'=0'";
  2459.          "(!0''*a=0'->!0''*a'=0')->0=0->(!0''*a=0'->!0''*a'=0')";
  2460.          "0=0->(!0''*a=0'->!0''*a'=0')";
  2461.          "0=0->@a.(!0''*a=0'->!0''*a'=0')";
  2462.          "@a.(!0''*a=0'->!0''*a'=0')";
  2463.          "@a.(a*0=0)->0''*0=0";
  2464.          "0''*0=0";
  2465.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(0''*0=b->0''*0=c->b=c)";
  2466.          "@b.@c.(0''*0=b->0''*0=c->b=c)";
  2467.          "@b.@c.(0''*0=b->0''*0=c->b=c)->@c.(0''*0=0'->0''*0=c->0'=c)";
  2468.          "@c.(0''*0=0'->0''*0=c->0'=c)";
  2469.          "@c.(0''*0=0'->0''*0=c->0'=c)->(0''*0=0'->0''*0=0->0'=0)";
  2470.          "0''*0=0'->0''*0=0->0'=0";
  2471.          "0''*0=0->0''*0=0'->0''*0=0";
  2472.          "0''*0=0'->0''*0=0";
  2473.          "(0''*0=0'->0''*0=0)->(0''*0=0'->0''*0=0->0'=0)->(0''*0=0'->0'=0)";
  2474.          "(0''*0=0'->0''*0=0->0'=0)->(0''*0=0'->0'=0)";
  2475.          "0''*0=0'->0'=0";
  2476.          "@a.!a'=0->!0'=0";
  2477.          "!0'=0";
  2478.          "!0'=0->0''*0=0'->!0'=0";
  2479.          "0''*0=0'->!0'=0";
  2480.          "(0''*0=0'->0'=0)->(0''*0=0'->!0'=0)->!0''*0=0'";
  2481.          "(0''*0=0'->!0'=0)->!0''*0=0'";
  2482.          "!0''*0=0'";
  2483.          "!0''*0=0'->@a.(!0''*a=0'->!0''*a'=0')->!0''*0=0'&@a.(!0''*a=0'->!0''*a'=0')";
  2484.          "@a.(!0''*a=0'->!0''*a'=0')->!0''*0=0'&@a.(!0''*a=0'->!0''*a'=0')";
  2485.          "!0''*0=0'&@a.(!0''*a=0'->!0''*a'=0')";
  2486.          "!0''*0=0'&@a.(!0''*a=0'->!0''*a'=0')->!0''*a=0'";
  2487.          "!0''*a=0'";
  2488.          "!0''*a=0'->0=0->!0''*a=0'";
  2489.          "0=0->!0''*a=0'";
  2490.          "0=0->@a.!0''*a=0'";
  2491.          "@a.!0''*a=0'"];;
  2492. let evenNeqOdd = twoMulANeqOne @
  2493.         ["@a.@b.@c.(a=b->c*a=c*b)->@b.@c.(a=b->c*a=c*b)";
  2494.          "@b.@c.(a=b->c*a=c*b)";
  2495.          "@b.@c.(a=b->c*a=c*b)->@c.(a=e+d->c*a=c*(e+d))";
  2496.          "@c.(a=e+d->c*a=c*(e+d))";
  2497.          "@c.(a=e+d->c*a=c*(e+d))->(a=e+d->0''*a=0''*(e+d))";
  2498.          "a=e+d->0''*a=0''*(e+d)";
  2499.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(0''*a=b->0''*a=c->b=c)";
  2500.          "@b.@c.(0''*a=b->0''*a=c->b=c)";
  2501.          "@b.@c.(0''*a=b->0''*a=c->b=c)->@c.(0''*a=0''*(e+d)->0''*a=c->0''*(e+d)=c)";
  2502.          "@c.(0''*a=0''*(e+d)->0''*a=c->0''*(e+d)=c)";
  2503.          "@c.(0''*a=0''*(e+d)->0''*a=c->0''*(e+d)=c)->(0''*a=0''*(e+d)->0''*a=(0''*d)'->0''*(e+d)=(0''*d)')";
  2504.          "0''*a=0''*(e+d)->0''*a=(0''*d)'->0''*(e+d)=(0''*d)'";
  2505.          "(0''*a=0''*(e+d)->0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->a=e+d->(0''*a=0''*(e+d)->0''*a=(0''*d)'->0''*(e+d)=(0''*d)')";
  2506.          "a=e+d->0''*a=0''*(e+d)->0''*a=(0''*d)'->0''*(e+d)=(0''*d)'";
  2507.          "(a=e+d->0''*a=0''*(e+d))->(a=e+d->0''*a=0''*(e+d)->0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->(a=e+d->0''*a=(0''*d)'->0''*(e+d)=(0''*d)')";
  2508.          "(a=e+d->0''*a=0''*(e+d)->0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->(a=e+d->0''*a=(0''*d)'->0''*(e+d)=(0''*d)')";
  2509.          "a=e+d->0''*a=(0''*d)'->0''*(e+d)=(0''*d)'";
  2510.          "@a.@b.@c.(a*(b+c)=a*b+a*c)->@b.@c.(0''*(b+c)=0''*b+0''*c)";
  2511.          "@b.@c.(0''*(b+c)=0''*b+0''*c)";
  2512.          "@b.@c.(0''*(b+c)=0''*b+0''*c)->@c.(0''*(e+c)=0''*e+0''*c)";
  2513.          "@c.(0''*(e+c)=0''*e+0''*c)";
  2514.          "@c.(0''*(e+c)=0''*e+0''*c)->(0''*(e+d)=0''*e+0''*d)";
  2515.          "0''*(e+d)=0''*e+0''*d";
  2516.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(0''*(e+d)=b->0''*(e+d)=c->b=c)";
  2517.          "@b.@c.(0''*(e+d)=b->0''*(e+d)=c->b=c)";
  2518.          "@b.@c.(0''*(e+d)=b->0''*(e+d)=c->b=c)->@c.(0''*(e+d)=0''*e+0''*d->0''*(e+d)=c->0''*e+0''*d=c)";
  2519.          "@c.(0''*(e+d)=0''*e+0''*d->0''*(e+d)=c->0''*e+0''*d=c)";
  2520.          "@c.(0''*(e+d)=0''*e+0''*d->0''*(e+d)=c->0''*e+0''*d=c)->(0''*(e+d)=0''*e+0''*d->0''*(e+d)=(0''*d)'->0''*e+0''*d=(0''*d)')";
  2521.          "0''*(e+d)=0''*e+0''*d->0''*(e+d)=(0''*d)'->0''*e+0''*d=(0''*d)'";
  2522.          "0''*(e+d)=(0''*d)'->0''*e+0''*d=(0''*d)'";
  2523.          "@a.(0+a=a)->0+0''*d=0''*d";
  2524.          "0+0''*d=0''*d";
  2525.          "@a.@b.(a=b->a'=b')->@b.(0+0''*d=b->(0+0''*d)'=b')";
  2526.          "@b.(0+0''*d=b->(0+0''*d)'=b')";
  2527.          "@b.(0+0''*d=b->(0+0''*d)'=b')->(0+0''*d=0''*d->(0+0''*d)'=(0''*d)')";
  2528.          "0+0''*d=0''*d->(0+0''*d)'=(0''*d)'";
  2529.          "(0+0''*d)'=(0''*d)'";
  2530.          "@a.@b.(a'+b=(a+b)')->@b.(0'+b=(0+b)')";
  2531.          "@b.(0'+b=(0+b)')";
  2532.          "@b.(0'+b=(0+b)')->(0'+0''*d=(0+0''*d)')";
  2533.          "0'+0''*d=(0+0''*d)'";
  2534.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(0+0''*d)'->(0+0''*d)'=c->b=c)";
  2535.          "@b.@c.(b=(0+0''*d)'->(0+0''*d)'=c->b=c)";
  2536.          "@b.@c.(b=(0+0''*d)'->(0+0''*d)'=c->b=c)->@c.(0'+0''*d=(0+0''*d)'->(0+0''*d)'=c->0'+0''*d=c)";
  2537.          "@c.(0'+0''*d=(0+0''*d)'->(0+0''*d)'=c->0'+0''*d=c)";
  2538.          "@c.(0'+0''*d=(0+0''*d)'->(0+0''*d)'=c->0'+0''*d=c)->(0'+0''*d=(0+0''*d)'->(0+0''*d)'=(0''*d)'->0'+0''*d=(0''*d)')";
  2539.          "0'+0''*d=(0+0''*d)'->(0+0''*d)'=(0''*d)'->0'+0''*d=(0''*d)'";
  2540.          "(0+0''*d)'=(0''*d)'->0'+0''*d=(0''*d)'";
  2541.          "0'+0''*d=(0''*d)'";
  2542.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=(0''*d)'->c=(0''*d)'->b=c)";
  2543.          "@b.@c.(b=(0''*d)'->c=(0''*d)'->b=c)";
  2544.          "@b.@c.(b=(0''*d)'->c=(0''*d)'->b=c)->@c.(0''*e+0''*d=(0''*d)'->c=(0''*d)'->0''*e+0''*d=c)";
  2545.          "@c.(0''*e+0''*d=(0''*d)'->c=(0''*d)'->0''*e+0''*d=c)";
  2546.          "@c.(0''*e+0''*d=(0''*d)'->c=(0''*d)'->0''*e+0''*d=c)->(0''*e+0''*d=(0''*d)'->0'+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d)";
  2547.          "0''*e+0''*d=(0''*d)'->0'+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d";
  2548.          "0'+0''*d=(0''*d)'->0''*e+0''*d=(0''*d)'->0'+0''*d=(0''*d)'";
  2549.          "0''*e+0''*d=(0''*d)'->0'+0''*d=(0''*d)'";
  2550.          "(0''*e+0''*d=(0''*d)'->0'+0''*d=(0''*d)')->(0''*e+0''*d=(0''*d)'->0'+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d)->(0''*e+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d)";
  2551.          "(0''*e+0''*d=(0''*d)'->0'+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d)->(0''*e+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d)";
  2552.          "0''*e+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d";
  2553.          "(0''*e+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d)->0''*(e+d)=(0''*d)'->(0''*e+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d)";
  2554.          "0''*(e+d)=(0''*d)'->0''*e+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d";
  2555.          "(0''*(e+d)=(0''*d)'->0''*e+0''*d=(0''*d)')->(0''*(e+d)=(0''*d)'->0''*e+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d)->(0''*(e+d)=(0''*d)'->0''*e+0''*d=0'+0''*d)";
  2556.          "(0''*(e+d)=(0''*d)'->0''*e+0''*d=(0''*d)'->0''*e+0''*d=0'+0''*d)->(0''*(e+d)=(0''*d)'->0''*e+0''*d=0'+0''*d)";
  2557.          "0''*(e+d)=(0''*d)'->0''*e+0''*d=0'+0''*d";
  2558.          "@a.@b.@c.(a+c=b+c->a=b)->@b.@c.(0''*e+c=b+c->0''*e=b)";
  2559.          "@b.@c.(0''*e+c=b+c->0''*e=b)";
  2560.          "@b.@c.(0''*e+c=b+c->0''*e=b)->@c.(0''*e+c=0'+c->0''*e=0')";
  2561.          "@c.(0''*e+c=0'+c->0''*e=0')";
  2562.          "@c.(0''*e+c=0'+c->0''*e=0')->(0''*e+0''*d=0'+0''*d->0''*e=0')";
  2563.          "0''*e+0''*d=0'+0''*d->0''*e=0'";
  2564.          "(0''*e+0''*d=0'+0''*d->0''*e=0')->0''*(e+d)=(0''*d)'->(0''*e+0''*d=0'+0''*d->0''*e=0')";
  2565.          "0''*(e+d)=(0''*d)'->0''*e+0''*d=0'+0''*d->0''*e=0'";
  2566.          "(0''*(e+d)=(0''*d)'->0''*e+0''*d=0'+0''*d)->(0''*(e+d)=(0''*d)'->0''*e+0''*d=0'+0''*d->0''*e=0')->(0''*(e+d)=(0''*d)'->0''*e=0')";
  2567.          "(0''*(e+d)=(0''*d)'->0''*e+0''*d=0'+0''*d->0''*e=0')->(0''*(e+d)=(0''*d)'->0''*e=0')";
  2568.          "0''*(e+d)=(0''*d)'->0''*e=0'";
  2569.          "@a.!0''*a=0'->!0''*e=0'";
  2570.          "!0''*e=0'";
  2571.          "!0''*e=0'->0''*(e+d)=(0''*d)'->!0''*e=0'";
  2572.          "0''*(e+d)=(0''*d)'->!0''*e=0'";
  2573.          "(0''*(e+d)=(0''*d)'->0''*e=0')->(0''*(e+d)=(0''*d)'->!0''*e=0')->!0''*(e+d)=(0''*d)'";
  2574.          "(0''*(e+d)=(0''*d)'->!0''*e=0')->!0''*(e+d)=(0''*d)'";
  2575.          "!0''*(e+d)=(0''*d)'";
  2576.          "!0''*(e+d)=(0''*d)'->0''*a=(0''*d)'->!0''*(e+d)=(0''*d)'";
  2577.          "0''*a=(0''*d)'->!0''*(e+d)=(0''*d)'";
  2578.          "(0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)'";
  2579.          "((0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)')->a=e+d->((0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)')";
  2580.          "a=e+d->(0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)'";
  2581.          "(a=e+d->0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->(a=e+d->(0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)')->(a=e+d->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)')";
  2582.          "(a=e+d->(0''*a=(0''*d)'->0''*(e+d)=(0''*d)')->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)')->(a=e+d->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)')";
  2583.          "a=e+d->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)'";
  2584.          "(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->a=e+d->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')";
  2585.          "a=e+d->0''*a=(0''*d)'->!0''*(e+d)=(0''*d)'";
  2586.          "(a=e+d->0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->(a=e+d->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)')->(a=e+d->!0''*a=(0''*d)')";
  2587.          "(a=e+d->(0''*a=(0''*d)'->!0''*(e+d)=(0''*d)')->!0''*a=(0''*d)')->(a=e+d->!0''*a=(0''*d)')";
  2588.          "a=e+d->!0''*a=(0''*d)'";
  2589.          "?e.a=e+d->!0''*a=(0''*d)'";
  2590.          "@a.@b.@c.(a=b->c*a=c*b)->@b.@c.(a+e=b->c*(a+e)=c*b)";
  2591.          "@b.@c.(a+e=b->c*(a+e)=c*b)";
  2592.          "@b.@c.(a+e=b->c*(a+e)=c*b)->@c.(a+e=d->c*(a+e)=c*d)";
  2593.          "@c.(a+e=d->c*(a+e)=c*d)";
  2594.          "@c.(a+e=d->c*(a+e)=c*d)->(a+e=d->0''*(a+e)=0''*d)";
  2595.          "a+e=d->0''*(a+e)=0''*d";
  2596.          "@a.@b.@c.(a*(b+c)=a*b+a*c)->@b.@c.(0''*(b+c)=0''*b+0''*c)";
  2597.          "@b.@c.(0''*(b+c)=0''*b+0''*c)";
  2598.          "@b.@c.(0''*(b+c)=0''*b+0''*c)->@c.(0''*(a+c)=0''*a+0''*c)";
  2599.          "@c.(0''*(a+c)=0''*a+0''*c)";
  2600.          "@c.(0''*(a+c)=0''*a+0''*c)->(0''*(a+e)=0''*a+0''*e)";
  2601.          "0''*(a+e)=0''*a+0''*e";
  2602.          "@a.@b.@c.(a=b->a=c->b=c)->@b.@c.(0''*(a+e)=b->0''*(a+e)=c->b=c)";
  2603.          "@b.@c.(0''*(a+e)=b->0''*(a+e)=c->b=c)";
  2604.          "@b.@c.(0''*(a+e)=b->0''*(a+e)=c->b=c)->@c.(0''*(a+e)=0''*a+0''*e->0''*(a+e)=c->0''*a+0''*e=c)";
  2605.          "@c.(0''*(a+e)=0''*a+0''*e->0''*(a+e)=c->0''*a+0''*e=c)";
  2606.          "@c.(0''*(a+e)=0''*a+0''*e->0''*(a+e)=c->0''*a+0''*e=c)->(0''*(a+e)=0''*a+0''*e->0''*(a+e)=0''*d->0''*a+0''*e=0''*d)";
  2607.          "0''*(a+e)=0''*a+0''*e->0''*(a+e)=0''*d->0''*a+0''*e=0''*d";
  2608.          "0''*(a+e)=0''*d->0''*a+0''*e=0''*d";
  2609.          "0''*(a+e)=0''*d->0''*a+0''*e=0''*d";
  2610.          "(0''*(a+e)=0''*d->0''*a+0''*e=0''*d)->a+e=d->(0''*(a+e)=0''*d->0''*a+0''*e=0''*d)";
  2611.          "a+e=d->0''*(a+e)=0''*d->0''*a+0''*e=0''*d";
  2612.          "(a+e=d->0''*(a+e)=0''*d)->(a+e=d->0''*(a+e)=0''*d->0''*a+0''*e=0''*d)->(a+e=d->0''*a+0''*e=0''*d)";
  2613.          "(a+e=d->0''*(a+e)=0''*d->0''*a+0''*e=0''*d)->(a+e=d->0''*a+0''*e=0''*d)";
  2614.          "a+e=d->0''*a+0''*e=0''*d";
  2615.          "@a.@b.(a=b->a'=b')->@b.(0''*a+0''*e=b->(0''*a+0''*e)'=b')";
  2616.          "@b.(0''*a+0''*e=b->(0''*a+0''*e)'=b')";
  2617.          "@b.(0''*a+0''*e=b->(0''*a+0''*e)'=b')->(0''*a+0''*e=0''*d->(0''*a+0''*e)'=(0''*d)')";
  2618.          "0''*a+0''*e=0''*d->(0''*a+0''*e)'=(0''*d)'";
  2619.          "(0''*a+0''*e=0''*d->(0''*a+0''*e)'=(0''*d)')->a+e=d->(0''*a+0''*e=0''*d->(0''*a+0''*e)'=(0''*d)')";
  2620.          "a+e=d->0''*a+0''*e=0''*d->(0''*a+0''*e)'=(0''*d)'";
  2621.          "(a+e=d->0''*a+0''*e=0''*d)->(a+e=d->0''*a+0''*e=0''*d->(0''*a+0''*e)'=(0''*d)')->(a+e=d->(0''*a+0''*e)'=(0''*d)')";
  2622.          "(a+e=d->0''*a+0''*e=0''*d->(0''*a+0''*e)'=(0''*d)')->(a+e=d->(0''*a+0''*e)'=(0''*d)')";
  2623.          "a+e=d->(0''*a+0''*e)'=(0''*d)'";
  2624.          "@a.@b.(a+b'=(a+b)')->@b.(0''*a+b'=(0''*a+b)')";
  2625.          "@b.(0''*a+b'=(0''*a+b)')";
  2626.          "@b.(0''*a+b'=(0''*a+b)')->(0''*a+(0''*e)'=(0''*a+0''*e)')";
  2627.          "0''*a+(0''*e)'=(0''*a+0''*e)'";
  2628.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(0''*a+0''*e)'->(0''*a+0''*e)'=c->b=c)";
  2629.          "@b.@c.(b=(0''*a+0''*e)'->(0''*a+0''*e)'=c->b=c)";
  2630.          "@b.@c.(b=(0''*a+0''*e)'->(0''*a+0''*e)'=c->b=c)->@c.(0''*a+(0''*e)'=(0''*a+0''*e)'->(0''*a+0''*e)'=c->0''*a+(0''*e)'=c)";
  2631.          "@c.(0''*a+(0''*e)'=(0''*a+0''*e)'->(0''*a+0''*e)'=c->0''*a+(0''*e)'=c)";
  2632.          "@c.(0''*a+(0''*e)'=(0''*a+0''*e)'->(0''*a+0''*e)'=c->0''*a+(0''*e)'=c)->(0''*a+(0''*e)'=(0''*a+0''*e)'->(0''*a+0''*e)'=(0''*d)'->0''*a+(0''*e)'=(0''*d)')";
  2633.          "0''*a+(0''*e)'=(0''*a+0''*e)'->(0''*a+0''*e)'=(0''*d)'->0''*a+(0''*e)'=(0''*d)'";
  2634.          "(0''*a+0''*e)'=(0''*d)'->0''*a+(0''*e)'=(0''*d)'";
  2635.          "((0''*a+0''*e)'=(0''*d)'->0''*a+(0''*e)'=(0''*d)')->a+e=d->((0''*a+0''*e)'=(0''*d)'->0''*a+(0''*e)'=(0''*d)')";
  2636.          "a+e=d->(0''*a+0''*e)'=(0''*d)'->0''*a+(0''*e)'=(0''*d)'";
  2637.          "(a+e=d->(0''*a+0''*e)'=(0''*d)')->(a+e=d->(0''*a+0''*e)'=(0''*d)'->0''*a+(0''*e)'=(0''*d)')->(a+e=d->0''*a+(0''*e)'=(0''*d)')";
  2638.          "(a+e=d->(0''*a+0''*e)'=(0''*d)'->0''*a+(0''*e)'=(0''*d)')->(a+e=d->0''*a+(0''*e)'=(0''*d)')";
  2639.          "a+e=d->0''*a+(0''*e)'=(0''*d)'";
  2640.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=(0''*d)'->c=(0''*d)'->b=c)";
  2641.          "@b.@c.(b=(0''*d)'->c=(0''*d)'->b=c)";
  2642.          "@b.@c.(b=(0''*d)'->c=(0''*d)'->b=c)->@c.(0''*a+(0''*e)'=(0''*d)'->c=(0''*d)'->0''*a+(0''*e)'=c)";
  2643.          "@c.(0''*a+(0''*e)'=(0''*d)'->c=(0''*d)'->0''*a+(0''*e)'=c)";
  2644.          "@c.(0''*a+(0''*e)'=(0''*d)'->c=(0''*d)'->0''*a+(0''*e)'=c)->(0''*a+(0''*e)'=(0''*d)'->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)";
  2645.          "0''*a+(0''*e)'=(0''*d)'->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a";
  2646.          "(0''*a+(0''*e)'=(0''*d)'->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->a+e=d->(0''*a+(0''*e)'=(0''*d)'->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)";
  2647.          "a+e=d->0''*a+(0''*e)'=(0''*d)'->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a";
  2648.          "(a+e=d->0''*a+(0''*e)'=(0''*d)')->(a+e=d->0''*a+(0''*e)'=(0''*d)'->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->(a+e=d->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)";
  2649.          "(a+e=d->0''*a+(0''*e)'=(0''*d)'->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->(a+e=d->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)";
  2650.          "a+e=d->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a";
  2651.          "@a.(a+0=a)->0''*a+0=0''*a";
  2652.          "0''*a+0=0''*a";
  2653.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=0''*a->c=0''*a->b=c)";
  2654.          "@b.@c.(b=0''*a->c=0''*a->b=c)";
  2655.          "@b.@c.(b=0''*a->c=0''*a->b=c)->@c.(0''*a+(0''*e)'=0''*a->c=0''*a->0''*a+(0''*e)'=c)";
  2656.          "@c.(0''*a+(0''*e)'=0''*a->c=0''*a->0''*a+(0''*e)'=c)";
  2657.          "@c.(0''*a+(0''*e)'=0''*a->c=0''*a->0''*a+(0''*e)'=c)->(0''*a+(0''*e)'=0''*a->0''*a+0=0''*a->0''*a+(0''*e)'=0''*a+0)";
  2658.          "0''*a+(0''*e)'=0''*a->0''*a+0=0''*a->0''*a+(0''*e)'=0''*a+0";
  2659.          "0''*a+0=0''*a->0''*a+(0''*e)'=0''*a->0''*a+0=0''*a";
  2660.          "0''*a+(0''*e)'=0''*a->0''*a+0=0''*a";
  2661.          "(0''*a+(0''*e)'=0''*a->0''*a+0=0''*a)->(0''*a+(0''*e)'=0''*a->0''*a+0=0''*a->0''*a+(0''*e)'=0''*a+0)->(0''*a+(0''*e)'=0''*a->0''*a+(0''*e)'=0''*a+0)";
  2662.          "(0''*a+(0''*e)'=0''*a->0''*a+0=0''*a->0''*a+(0''*e)'=0''*a+0)->(0''*a+(0''*e)'=0''*a->0''*a+(0''*e)'=0''*a+0)";
  2663.          "0''*a+(0''*e)'=0''*a->0''*a+(0''*e)'=0''*a+0";
  2664.          "@a.@b.@c.(c+a=c+b->a=b)->@b.@c.(c+(0''*e)'=c+b->(0''*e)'=b)";
  2665.          "@b.@c.(c+(0''*e)'=c+b->(0''*e)'=b)";
  2666.          "@b.@c.(c+(0''*e)'=c+b->(0''*e)'=b)->@c.(c+(0''*e)'=c+0->(0''*e)'=0)";
  2667.          "@c.(c+(0''*e)'=c+0->(0''*e)'=0)";
  2668.          "@c.(c+(0''*e)'=c+0->(0''*e)'=0)->(0''*a+(0''*e)'=0''*a+0->(0''*e)'=0)";
  2669.          "0''*a+(0''*e)'=0''*a+0->(0''*e)'=0";
  2670.          "(0''*a+(0''*e)'=0''*a+0->(0''*e)'=0)->0''*a+(0''*e)'=0''*a->(0''*a+(0''*e)'=0''*a+0->(0''*e)'=0)";
  2671.          "0''*a+(0''*e)'=0''*a->0''*a+(0''*e)'=0''*a+0->(0''*e)'=0";
  2672.          "(0''*a+(0''*e)'=0''*a->0''*a+(0''*e)'=0''*a+0)->(0''*a+(0''*e)'=0''*a->0''*a+(0''*e)'=0''*a+0->(0''*e)'=0)->(0''*a+(0''*e)'=0''*a->(0''*e)'=0)";
  2673.          "(0''*a+(0''*e)'=0''*a->0''*a+(0''*e)'=0''*a+0->(0''*e)'=0)->(0''*a+(0''*e)'=0''*a->(0''*e)'=0)";
  2674.          "0''*a+(0''*e)'=0''*a->(0''*e)'=0";
  2675.          "@a.!a'=0->!(0''*e)'=0";
  2676.          "!(0''*e)'=0";
  2677.          "!(0''*e)'=0->0''*a+(0''*e)'=0''*a->!(0''*e)'=0";
  2678.          "0''*a+(0''*e)'=0''*a->!(0''*e)'=0";
  2679.          "(0''*a+(0''*e)'=0''*a->(0''*e)'=0)->(0''*a+(0''*e)'=0''*a->!(0''*e)'=0)->!0''*a+(0''*e)'=0''*a";
  2680.          "(0''*a+(0''*e)'=0''*a->!(0''*e)'=0)->!0''*a+(0''*e)'=0''*a";
  2681.          "!0''*a+(0''*e)'=0''*a";
  2682.          "!0''*a+(0''*e)'=0''*a->0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a";
  2683.          "0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a";
  2684.          "(0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)'";
  2685.          "((0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)')->a+e=d->((0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)')";
  2686.          "a+e=d->(0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)'";
  2687.          "(a+e=d->0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->(a+e=d->(0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)')->(a+e=d->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)')";
  2688.          "(a+e=d->(0''*a=(0''*d)'->0''*a+(0''*e)'=0''*a)->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)')->(a+e=d->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)')";
  2689.          "a+e=d->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)'";
  2690.          "(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->a+e=d->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)";
  2691.          "a+e=d->0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a";
  2692.          "(a+e=d->0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->(a+e=d->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)')->(a+e=d->!0''*a=(0''*d)')";
  2693.          "(a+e=d->(0''*a=(0''*d)'->!0''*a+(0''*e)'=0''*a)->!0''*a=(0''*d)')->(a+e=d->!0''*a=(0''*d)')";
  2694.          "a+e=d->!0''*a=(0''*d)'";
  2695.          "?e.a+e=d->!0''*a=(0''*d)'";
  2696.          "(?e.a=e+d->!0''*a=(0''*d)')->(?e.a+e=d->!0''*a=(0''*d)')->(?e.a=e+d|?e.a+e=d->!0''*a=(0''*d)')";
  2697.          "(?e.a+e=d->!0''*a=(0''*d)')->(?e.a=e+d|?e.a+e=d->!0''*a=(0''*d)')";
  2698.          "?e.a=e+d|?e.a+e=d->!0''*a=(0''*d)'";
  2699.          "!0''*a=(0''*d)'";
  2700.          "!0''*a=(0''*d)'->0=0->!0''*a=(0''*d)'";
  2701.          "0=0->!0''*a=(0''*d)'";
  2702.          "0=0->@d.!0''*a=(0''*d)'";
  2703.          "@d.!0''*a=(0''*d)'";
  2704.          "@d.!0''*a=(0''*d)'->!0''*a=(0''*b)'";
  2705.          "!0''*a=(0''*b)'";
  2706.          "!0''*a=(0''*b)'->0=0->!0''*a=(0''*b)'";
  2707.          "0=0->!0''*a=(0''*b)'";
  2708.          "0=0->@b.!0''*a=(0''*b)'";
  2709.          "0=0->@a.@b.!0''*a=(0''*b)'";
  2710.          "@a.@b.!0''*a=(0''*b)'";
  2711.          "@a.(a+0=a)->0''*d+0=0''*d";
  2712.          "0''*d+0=0''*d";
  2713.          "@a.@b.(a=b->a'=b')->@b.(0''*d+0=b->(0''*d+0)'=b')";
  2714.          "@b.(0''*d+0=b->(0''*d+0)'=b')";
  2715.          "@b.(0''*d+0=b->(0''*d+0)'=b')->(0''*d+0=0''*d->(0''*d+0)'=(0''*d)')";
  2716.          "0''*d+0=0''*d->(0''*d+0)'=(0''*d)'";
  2717.          "(0''*d+0)'=(0''*d)'";
  2718.          "@a.@b.(a+b'=(a+b)')->@b.(0''*d+b'=(0''*d+b)')";
  2719.          "@b.(0''*d+b'=(0''*d+b)')";
  2720.          "@b.(0''*d+b'=(0''*d+b)')->(0''*d+0'=(0''*d+0)')";
  2721.          "0''*d+0'=(0''*d+0)'";
  2722.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(0''*d+0)'->(0''*d+0)'=c->b=c)";
  2723.          "@b.@c.(b=(0''*d+0)'->(0''*d+0)'=c->b=c)";
  2724.          "@b.@c.(b=(0''*d+0)'->(0''*d+0)'=c->b=c)->@c.(0''*d+0'=(0''*d+0)'->(0''*d+0)'=c->0''*d+0'=c)";
  2725.          "@c.(0''*d+0'=(0''*d+0)'->(0''*d+0)'=c->0''*d+0'=c)";
  2726.          "@c.(0''*d+0'=(0''*d+0)'->(0''*d+0)'=c->0''*d+0'=c)->(0''*d+0'=(0''*d+0)'->(0''*d+0)'=(0''*d)'->0''*d+0'=(0''*d)')";
  2727.          "0''*d+0'=(0''*d+0)'->(0''*d+0)'=(0''*d)'->0''*d+0'=(0''*d)'";
  2728.          "(0''*d+0)'=(0''*d)'->0''*d+0'=(0''*d)'";
  2729.          "0''*d+0'=(0''*d)'";
  2730.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=0''*d+0'->0''*d+0'=c->b=c)";
  2731.          "@b.@c.(b=0''*d+0'->0''*d+0'=c->b=c)";
  2732.          "@b.@c.(b=0''*d+0'->0''*d+0'=c->b=c)->@c.(0''*a=0''*d+0'->0''*d+0'=c->0''*a=c)";
  2733.          "@c.(0''*a=0''*d+0'->0''*d+0'=c->0''*a=c)";
  2734.          "@c.(0''*a=0''*d+0'->0''*d+0'=c->0''*a=c)->(0''*a=0''*d+0'->0''*d+0'=(0''*d)'->0''*a=(0''*d)')";
  2735.          "0''*a=0''*d+0'->0''*d+0'=(0''*d)'->0''*a=(0''*d)'";
  2736.          "0''*d+0'=(0''*d)'->0''*a=0''*d+0'->0''*d+0'=(0''*d)'";
  2737.          "0''*a=0''*d+0'->0''*d+0'=(0''*d)'";
  2738.          "(0''*a=0''*d+0'->0''*d+0'=(0''*d)')->(0''*a=0''*d+0'->0''*d+0'=(0''*d)'->0''*a=(0''*d)')->(0''*a=0''*d+0'->0''*a=(0''*d)')";
  2739.          "(0''*a=0''*d+0'->0''*d+0'=(0''*d)'->0''*a=(0''*d)')->(0''*a=0''*d+0'->0''*a=(0''*d)')";
  2740.          "0''*a=0''*d+0'->0''*a=(0''*d)'";
  2741.          "!0''*a=(0''*d)'->0''*a=0''*d+0'->!0''*a=(0''*d)'";
  2742.          "0''*a=0''*d+0'->!0''*a=(0''*d)'";
  2743.          "(0''*a=0''*d+0'->0''*a=(0''*d)')->(0''*a=0''*d+0'->!0''*a=(0''*d)')->!0''*a=0''*d+0'";
  2744.          "(0''*a=0''*d+0'->!0''*a=(0''*d)')->!0''*a=0''*d+0'";
  2745.          "!0''*a=0''*d+0'";
  2746.          "!0''*a=0''*d+0'->0=0->!0''*a=0''*d+0'";
  2747.          "0=0->!0''*a=0''*d+0'";
  2748.          "0=0->@d.!0''*a=0''*d+0'";
  2749.          "@d.!0''*a=0''*d+0'";
  2750.          "@d.!0''*a=0''*d+0'->!0''*a=0''*b+0'";
  2751.          "!0''*a=0''*b+0'";
  2752.          "!0''*a=0''*b+0'->0=0->!0''*a=0''*b+0'";
  2753.          "0=0->!0''*a=0''*b+0'";
  2754.          "0=0->@b.!0''*a=0''*b+0'";
  2755.          "0=0->@a.@b.!0''*a=0''*b+0'";
  2756.          "@a.@b.!0''*a=0''*b+0'"];;
  2757. let constructTheorem = evenNeqOdd @
  2758.         ["@a.(a*0=0)->0''*0=0";
  2759.          "0''*0=0";
  2760.          "@a.@b.(a=b->a'=b')->@b.(0''*a=b->(0''*a)'=b')";
  2761.          "@b.(0''*a=b->(0''*a)'=b')";
  2762.          "@b.(0''*a=b->(0''*a)'=b')->(0''*a=d->(0''*a)'=d')";
  2763.          "0''*a=d->(0''*a)'=d'";
  2764.          "@a.@b.(a=b->a'=b')->@b.((0''*a)'=b->(0''*a)''=b')";
  2765.          "@b.((0''*a)'=b->(0''*a)''=b')";
  2766.          "@b.((0''*a)'=b->(0''*a)''=b')->((0''*a)'=d'->(0''*a)''=d'')";
  2767.          "(0''*a)'=d'->(0''*a)''=d''";
  2768.          "((0''*a)'=d'->(0''*a)''=d'')->0''*a=d->((0''*a)'=d'->(0''*a)''=d'')";
  2769.          "0''*a=d->(0''*a)'=d'->(0''*a)''=d''";
  2770.          "(0''*a=d->(0''*a)'=d')->(0''*a=d->(0''*a)'=d'->(0''*a)''=d'')->(0''*a=d->(0''*a)''=d'')";
  2771.          "(0''*a=d->(0''*a)'=d'->(0''*a)''=d'')->(0''*a=d->(0''*a)''=d'')";
  2772.          "0''*a=d->(0''*a)''=d''";
  2773.          "@a.(a+0=a)->(0''*a+0=0''*a)";
  2774.          "0''*a+0=0''*a";
  2775.          "@a.@b.(a=b->a'=b')->@b.(0''*a+0=b->(0''*a+0)'=b')";
  2776.          "@b.(0''*a+0=b->(0''*a+0)'=b')";
  2777.          "@b.(0''*a+0=b->(0''*a+0)'=b')->(0''*a+0=0''*a->(0''*a+0)'=(0''*a)')";
  2778.          "0''*a+0=0''*a->(0''*a+0)'=(0''*a)'";
  2779.          "(0''*a+0)'=(0''*a)'";
  2780.          "@a.@b.(a=b->a'=b')->@b.((0''*a+0)'=b->(0''*a+0)''=b')";
  2781.          "@b.((0''*a+0)'=b->(0''*a+0)''=b')";
  2782.          "@b.((0''*a+0)'=b->(0''*a+0)''=b')->((0''*a+0)'=(0''*a)'->(0''*a+0)''=(0''*a)'')";
  2783.          "(0''*a+0)'=(0''*a)'->(0''*a+0)''=(0''*a)''";
  2784.          "(0''*a+0)''=(0''*a)''";
  2785.          "@a.@b.(a+b'=(a+b)')->@b.(0''*a+b'=(0''*a+b)')";
  2786.          "@b.(0''*a+b'=(0''*a+b)')";
  2787.          "@b.(0''*a+b'=(0''*a+b)')->(0''*a+0'=(0''*a+0)')";
  2788.          "0''*a+0'=(0''*a+0)'";
  2789.          "@a.@b.(a=b->a'=b')->@b.(0''*a+0'=b->(0''*a+0')'=b')";
  2790.          "@b.(0''*a+0'=b->(0''*a+0')'=b')";
  2791.          "@b.(0''*a+0'=b->(0''*a+0')'=b')->(0''*a+0'=(0''*a+0)'->(0''*a+0')'=(0''*a+0)'')";
  2792.          "0''*a+0'=(0''*a+0)'->(0''*a+0')'=(0''*a+0)''";
  2793.          "(0''*a+0')'=(0''*a+0)''";
  2794.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(0''*a+0)''->(0''*a+0)''=c->b=c)";
  2795.          "@b.@c.(b=(0''*a+0)''->(0''*a+0)''=c->b=c)";
  2796.          "@b.@c.(b=(0''*a+0)''->(0''*a+0)''=c->b=c)->@c.((0''*a+0')'=(0''*a+0)''->(0''*a+0)''=c->(0''*a+0')'=c)";
  2797.          "@c.((0''*a+0')'=(0''*a+0)''->(0''*a+0)''=c->(0''*a+0')'=c)";
  2798.          "@c.((0''*a+0')'=(0''*a+0)''->(0''*a+0)''=c->(0''*a+0')'=c)->((0''*a+0')'=(0''*a+0)''->(0''*a+0)''=(0''*a)''->(0''*a+0')'=(0''*a)'')";
  2799.          "(0''*a+0')'=(0''*a+0)''->(0''*a+0)''=(0''*a)''->(0''*a+0')'=(0''*a)''";
  2800.          "(0''*a+0)''=(0''*a)''->(0''*a+0')'=(0''*a)''";
  2801.          "(0''*a+0')'=(0''*a)''";
  2802.          "@a.@b.(a+b'=(a+b)')->@b.(0''*a+b'=(0''*a+b)')";
  2803.          "@b.(0''*a+b'=(0''*a+b)')";
  2804.          "@b.(0''*a+b'=(0''*a+b)')->(0''*a+0''=(0''*a+0')')";
  2805.          "0''*a+0''=(0''*a+0')'";
  2806.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(0''*a+0')'->(0''*a+0')'=c->b=c)";
  2807.          "@b.@c.(b=(0''*a+0')'->(0''*a+0')'=c->b=c)";
  2808.          "@b.@c.(b=(0''*a+0')'->(0''*a+0')'=c->b=c)->@c.(0''*a+0''=(0''*a+0')'->(0''*a+0')'=c->0''*a+0''=c)";
  2809.          "@c.(0''*a+0''=(0''*a+0')'->(0''*a+0')'=c->0''*a+0''=c)";
  2810.          "@c.(0''*a+0''=(0''*a+0')'->(0''*a+0')'=c->0''*a+0''=c)->(0''*a+0''=(0''*a+0')'->(0''*a+0')'=(0''*a)''->0''*a+0''=(0''*a)'')";
  2811.          "0''*a+0''=(0''*a+0')'->(0''*a+0')'=(0''*a)''->0''*a+0''=(0''*a)''";
  2812.          "(0''*a+0')'=(0''*a)''->0''*a+0''=(0''*a)''";
  2813.          "0''*a+0''=(0''*a)''";
  2814.          "@a.@b.(a*b'=a*b+a)->@b.(0''*b'=0''*b+0'')";
  2815.          "@b.(0''*b'=0''*b+0'')";
  2816.          "@b.(0''*b'=0''*b+0'')->(0''*a'=0''*a+0'')";
  2817.          "0''*a'=0''*a+0''";
  2818.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=0''*a+0''->0''*a+0''=c->b=c)";
  2819.          "@b.@c.(b=0''*a+0''->0''*a+0''=c->b=c)";
  2820.          "@b.@c.(b=0''*a+0''->0''*a+0''=c->b=c)->@c.(0''*a'=0''*a+0''->0''*a+0''=c->0''*a'=c)";
  2821.          "@c.(0''*a'=0''*a+0''->0''*a+0''=c->0''*a'=c)";
  2822.          "@c.(0''*a'=0''*a+0''->0''*a+0''=c->0''*a'=c)->(0''*a'=0''*a+0''->0''*a+0''=(0''*a)''->0''*a'=(0''*a)'')";
  2823.          "0''*a'=0''*a+0''->0''*a+0''=(0''*a)''->0''*a'=(0''*a)''";
  2824.          "0''*a+0''=(0''*a)''->0''*a'=(0''*a)''";
  2825.          "0''*a'=(0''*a)''";
  2826.          "@a.@b.@c.(b=a->a=c->b=c)->@b.@c.(b=(0''*a)''->(0''*a)''=c->b=c)";
  2827.          "@b.@c.(b=(0''*a)''->(0''*a)''=c->b=c)";
  2828.          "@b.@c.(b=(0''*a)''->(0''*a)''=c->b=c)->@c.(0''*a'=(0''*a)''->(0''*a)''=c->0''*a'=c)";
  2829.          "@c.(0''*a'=(0''*a)''->(0''*a)''=c->0''*a'=c)";
  2830.          "@c.(0''*a'=(0''*a)''->(0''*a)''=c->0''*a'=c)->(0''*a'=(0''*a)''->(0''*a)''=d''->0''*a'=d'')";
  2831.          "0''*a'=(0''*a)''->(0''*a)''=d''->0''*a'=d''";
  2832.          "(0''*a)''=d''->0''*a'=d''";
  2833.          "((0''*a)''=d''->0''*a'=d'')->0''*a=d->((0''*a)''=d''->0''*a'=d'')";
  2834.          "0''*a=d->(0''*a)''=d''->0''*a'=d''";
  2835.          "(0''*a=d->(0''*a)''=d'')->(0''*a=d->(0''*a)''=d''->0''*a'=d'')->(0''*a=d->0''*a'=d'')";
  2836.          "(0''*a=d->(0''*a)''=d''->0''*a'=d'')->(0''*a=d->0''*a'=d'')";
  2837.          "0''*a=d->0''*a'=d''";
  2838.          "(0''*a=d->0''*a'=d'')->0=0->(0''*a=d->0''*a'=d'')";
  2839.          "0=0->(0''*a=d->0''*a'=d'')";
  2840.          "0=0->@d.(0''*a=d->0''*a'=d'')";
  2841.          "@d.(0''*a=d->0''*a'=d'')";
  2842.          "@d.(0''*a=d->0''*a'=d'')->(0''*a=b->0''*a'=b'')";
  2843.          "0''*a=b->0''*a'=b''";
  2844.          "(0''*a=b->0''*a'=b'')->0=0->(0''*a=b->0''*a'=b'')";
  2845.          "0=0->(0''*a=b->0''*a'=b'')";
  2846.          "0=0->@b.(0''*a=b->0''*a'=b'')";
  2847.          "0=0->@a.@b.(0''*a=b->0''*a'=b'')";
  2848.          "@a.@b.(0''*a=b->0''*a'=b'')";
  2849.         ];;
  2850. let lastOneForNeg =
  2851.         ["(0''*f)'=x";
  2852.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=x->c=x->b=c)";
  2853.          "@b.@c.(b=x->c=x->b=c)";
  2854.          "@b.@c.(b=x->c=x->b=c)->@c.(0''*p=x->c=x->0''*p=c)";
  2855.          "@c.(0''*p=x->c=x->0''*p=c)";
  2856.          "@c.(0''*p=x->c=x->0''*p=c)->(0''*p=x->(0''*f)'=x->0''*p=(0''*f)')";
  2857.          "0''*p=x->(0''*f)'=x->0''*p=(0''*f)'";
  2858.          "(0''*f)'=x->0''*p=x->(0''*f)'=x";
  2859.          "0''*p=x->(0''*f)'=x";
  2860.          "(0''*p=x->(0''*f)'=x)->(0''*p=x->(0''*f)'=x->0''*p=(0''*f)')->(0''*p=x->0''*p=(0''*f)')";
  2861.          "(0''*p=x->(0''*f)'=x->0''*p=(0''*f)')->(0''*p=x->0''*p=(0''*f)')";
  2862.          "0''*p=x->0''*p=(0''*f)'";
  2863.          "@a.@b.!0''*a=(0''*b)'->@b.!0''*p=(0''*b)'";
  2864.          "@b.!0''*p=(0''*b)'";
  2865.          "@b.!0''*p=(0''*b)'->!0''*p=(0''*f)'";
  2866.          "!0''*p=(0''*f)'";
  2867.          "!0''*p=(0''*f)'->0''*p=x->!0''*p=(0''*f)'";
  2868.          "0''*p=x->!0''*p=(0''*f)'";
  2869.          "(0''*p=x->0''*p=(0''*f)')->(0''*p=x->!0''*p=(0''*f)')->!0''*p=x";
  2870.          "(0''*p=x->!0''*p=(0''*f)')->!0''*p=x";
  2871.          "!0''*p=x";
  2872.          "!0''*p=x->0''*p=x&0''*q=y->!0''*p=x";
  2873.          "0''*p=x&0''*q=y->!0''*p=x";
  2874.          "0''*p=x&0''*q=y->0''*p=x";
  2875.          "(0''*p=x&0''*q=y->0''*p=x)->(0''*p=x&0''*q=y->!0''*p=x)->!(0''*p=x&0''*q=y)";
  2876.          "(0''*p=x&0''*q=y->!0''*p=x)->!(0''*p=x&0''*q=y)";
  2877.          "!(0''*p=x&0''*q=y)";
  2878.          "!0''*p=x->0''*q=y&0''*p=x->!0''*p=x";
  2879.          "0''*q=y&0''*p=x->!0''*p=x";
  2880.          "0''*q=y&0''*p=x->0''*p=x";
  2881.          "(0''*q=y&0''*p=x->0''*p=x)->(0''*q=y&0''*p=x->!0''*p=x)->!(0''*q=y&0''*p=x)";
  2882.          "(0''*q=y&0''*p=x->!0''*p=x)->!(0''*q=y&0''*p=x)";
  2883.          "!(0''*q=y&0''*p=x)";
  2884.          "0''*g=y";
  2885.          "@a.@b.@c.(a=b->a+c=b+c)->@b.@c.(0''*g=b->0''*g+c=b+c)";
  2886.          "@b.@c.(0''*g=b->0''*g+c=b+c)";
  2887.          "@b.@c.(0''*g=b->0''*g+c=b+c)->@c.(0''*g=y->0''*g+c=y+c)";
  2888.          "@c.(0''*g=y->0''*g+c=y+c)";
  2889.          "@c.(0''*g=y->0''*g+c=y+c)->(0''*g=y->0''*g+0'=y+0')";
  2890.          "0''*g=y->0''*g+0'=y+0'";
  2891.          "0''*g+0'=y+0'";
  2892.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=y+0'->c=y+0'->b=c)";
  2893.          "@b.@c.(b=y+0'->c=y+0'->b=c)";
  2894.          "@b.@c.(b=y+0'->c=y+0'->b=c)->@c.(0''*q=y+0'->c=y+0'->0''*q=c)";
  2895.          "@c.(0''*q=y+0'->c=y+0'->0''*q=c)";
  2896.          "@c.(0''*q=y+0'->c=y+0'->0''*q=c)->(0''*q=y+0'->0''*g+0'=y+0'->0''*q=0''*g+0')";
  2897.          "0''*q=y+0'->0''*g+0'=y+0'->0''*q=0''*g+0'";
  2898.          "0''*g+0'=y+0'->0''*q=y+0'->0''*g+0'=y+0'";
  2899.          "0''*q=y+0'->0''*g+0'=y+0'";
  2900.          "(0''*q=y+0'->0''*g+0'=y+0')->(0''*q=y+0'->0''*g+0'=y+0'->0''*q=0''*g+0')->(0''*q=y+0'->0''*q=0''*g+0')";
  2901.          "(0''*q=y+0'->0''*g+0'=y+0'->0''*q=0''*g+0')->(0''*q=y+0'->0''*q=0''*g+0')";
  2902.          "0''*q=y+0'->0''*q=0''*g+0'";
  2903.          "@a.@b.!0''*a=0''*b+0'->@b.!0''*q=0''*b+0'";
  2904.          "@b.!0''*q=0''*b+0'";
  2905.          "@b.!0''*q=0''*b+0'->!0''*q=0''*g+0'";
  2906.          "!0''*q=0''*g+0'";
  2907.          "!0''*q=0''*g+0'->0''*q=y+0'->!0''*q=0''*g+0'";
  2908.          "0''*q=y+0'->!0''*q=0''*g+0'";
  2909.          "(0''*q=y+0'->0''*q=0''*g+0')->(0''*q=y+0'->!0''*q=0''*g+0')->!0''*q=y+0'";
  2910.          "(0''*q=y+0'->!0''*q=0''*g+0')->!0''*q=y+0'";
  2911.          "!0''*q=y+0'";
  2912.          "!0''*q=y+0'->0''*q=y+0'&0''*p=x+0'->!0''*q=y+0'";
  2913.          "0''*q=y+0'&0''*p=x+0'->!0''*q=y+0'";
  2914.          "0''*q=y+0'&0''*p=x+0'->0''*q=y+0'";
  2915.          "(0''*q=y+0'&0''*p=x+0'->0''*q=y+0')->(0''*q=y+0'&0''*p=x+0'->!0''*q=y+0')->!(0''*q=y+0'&0''*p=x+0')";
  2916.          "(0''*q=y+0'&0''*p=x+0'->!0''*q=y+0')->!(0''*q=y+0'&0''*p=x+0')";
  2917.          "!(0''*q=y+0'&0''*p=x+0')";
  2918.          "!0''*q=y+0'->0''*p=x+0'&0''*q=y+0'->!0''*q=y+0'";
  2919.          "0''*p=x+0'&0''*q=y+0'->!0''*q=y+0'";
  2920.          "0''*p=x+0'&0''*q=y+0'->0''*q=y+0'";
  2921.          "(0''*p=x+0'&0''*q=y+0'->0''*q=y+0')->(0''*p=x+0'&0''*q=y+0'->!0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0')";
  2922.          "(0''*p=x+0'&0''*q=y+0'->!0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0')";
  2923.          "!(0''*p=x+0'&0''*q=y+0')";
  2924.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2925.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(0''*p=x&0''*q=y)->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2926.          "(0''*p=x&0''*q=y)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2927.          "(0''*p=x&0''*q=y)->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y)";
  2928.          "((0''*p=x&0''*q=y)->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y))->((0''*p=x&0''*q=y)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x&0''*q=y)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2929.          "((0''*p=x&0''*q=y)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x&0''*q=y)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2930.          "(0''*p=x&0''*q=y)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2931.          "!(0''*p=x&0''*q=y)->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y)";
  2932.          "(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y)";
  2933.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->(0''*p=x&0''*q=y)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))";
  2934.          "(0''*p=x&0''*q=y)->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y)";
  2935.          "((0''*p=x&0''*q=y)->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->((0''*p=x&0''*q=y)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x&0''*q=y)->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2936.          "((0''*p=x&0''*q=y)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x&0''*q=y))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x&0''*q=y)->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2937.          "(0''*p=x&0''*q=y)->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2938.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2939.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(0''*p=x+0'&0''*q=y+0')->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2940.          "(0''*p=x+0'&0''*q=y+0')->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2941.          "(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x+0'&0''*q=y+0')";
  2942.          "((0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x+0'&0''*q=y+0'))->((0''*p=x+0'&0''*q=y+0')->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x+0'&0''*q=y+0')->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2943.          "((0''*p=x+0'&0''*q=y+0')->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x+0'&0''*q=y+0')->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2944.          "(0''*p=x+0'&0''*q=y+0')->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2945.          "!(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0')";
  2946.          "(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0')";
  2947.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->(0''*p=x+0'&0''*q=y+0')->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))";
  2948.          "(0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0')";
  2949.          "((0''*p=x+0'&0''*q=y+0')->(0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->((0''*p=x+0'&0''*q=y+0')->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x+0'&0''*q=y+0')->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2950.          "((0''*p=x+0'&0''*q=y+0')->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')->!(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x+0'&0''*q=y+0')->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2951.          "(0''*p=x+0'&0''*q=y+0')->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2952.          "((0''*p=x&0''*q=y)->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x+0'&0''*q=y+0')->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2953.          "((0''*p=x+0'&0''*q=y+0')->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2954.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2955.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2956.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2957.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2958.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  2959.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2960.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2961.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2962.          "!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  2963.          "((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2964.          "(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->(0''*q=y&0''*p=x)->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2965.          "(0''*q=y&0''*p=x)->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2966.          "(0''*q=y&0''*p=x)->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x)";
  2967.          "((0''*q=y&0''*p=x)->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x))->((0''*q=y&0''*p=x)->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y&0''*p=x)->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2968.          "((0''*q=y&0''*p=x)->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y&0''*p=x)->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2969.          "(0''*q=y&0''*p=x)->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2970.          "!(0''*q=y&0''*p=x)->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x)";
  2971.          "(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x)";
  2972.          "((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->(0''*q=y&0''*p=x)->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))";
  2973.          "(0''*q=y&0''*p=x)->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x)";
  2974.          "((0''*q=y&0''*p=x)->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->((0''*q=y&0''*p=x)->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y&0''*p=x)->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2975.          "((0''*q=y&0''*p=x)->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y&0''*p=x))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y&0''*p=x)->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2976.          "(0''*q=y&0''*p=x)->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2977.          "((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2978.          "(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->(0''*q=y+0'&0''*p=x+0')->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2979.          "(0''*q=y+0'&0''*p=x+0')->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2980.          "(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y+0'&0''*p=x+0')";
  2981.          "((0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y+0'&0''*p=x+0'))->((0''*q=y+0'&0''*p=x+0')->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y+0'&0''*p=x+0')->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2982.          "((0''*q=y+0'&0''*p=x+0')->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y+0'&0''*p=x+0')->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2983.          "(0''*q=y+0'&0''*p=x+0')->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2984.          "!(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0')";
  2985.          "(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0')";
  2986.          "((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->(0''*q=y+0'&0''*p=x+0')->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))";
  2987.          "(0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0')";
  2988.          "((0''*q=y+0'&0''*p=x+0')->(0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->((0''*q=y+0'&0''*p=x+0')->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y+0'&0''*p=x+0')->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2989.          "((0''*q=y+0'&0''*p=x+0')->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')->!(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y+0'&0''*p=x+0')->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2990.          "(0''*q=y+0'&0''*p=x+0')->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2991.          "((0''*q=y&0''*p=x)->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y+0'&0''*p=x+0')->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2992.          "((0''*q=y+0'&0''*p=x+0')->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2993.          "((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2994.          "((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2995.          "((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2996.          "(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2997.          "(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))";
  2998.          "((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  2999.          "(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  3000.          "(((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0')))->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  3001.          "!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  3002.          "!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->0=0->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  3003.          "0=0->!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  3004.          "0=0->@q.!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  3005.          "@q.!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))";
  3006.          "@q.!((0''*q=y&0''*p=x)|(0''*q=y+0'&0''*p=x+0'))->!((0''*w=y&0''*p=x)|(0''*w=y+0'&0''*p=x+0'))";
  3007.          "!((0''*w=y&0''*p=x)|(0''*w=y+0'&0''*p=x+0'))";
  3008.          "!((0''*w=y&0''*p=x)|(0''*w=y+0'&0''*p=x+0'))->0=0->!((0''*w=y&0''*p=x)|(0''*w=y+0'&0''*p=x+0'))";
  3009.          "0=0->!((0''*w=y&0''*p=x)|(0''*w=y+0'&0''*p=x+0'))";
  3010.          "0=0->@w.!((0''*w=y&0''*p=x)|(0''*w=y+0'&0''*p=x+0'))";
  3011.          "0=0->@p.@w.!((0''*w=y&0''*p=x)|(0''*w=y+0'&0''*p=x+0'))";
  3012.          "@p.@w.!((0''*w=y&0''*p=x)|(0''*w=y+0'&0''*p=x+0'))";
  3013.          "@p.@w.!((0''*w=y&0''*p=x)|(0''*w=y+0'&0''*p=x+0'))->@w.!((0''*w=y&0''*q=x)|(0''*w=y+0'&0''*q=x+0'))";
  3014.          "@w.!((0''*w=y&0''*q=x)|(0''*w=y+0'&0''*q=x+0'))";
  3015.          "@w.!((0''*w=y&0''*q=x)|(0''*w=y+0'&0''*q=x+0'))->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))";
  3016.          "!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))";
  3017.          "!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3018.          "(0=0->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0";
  3019.          "((0=0->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0)->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->((0=0->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0)";
  3020.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(0=0->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0";
  3021.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3022.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(0=0->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0)->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0)";
  3023.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(0=0->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0)->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0)";
  3024.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0";
  3025.          "!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3026.          "0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3027.          "(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))";
  3028.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3029.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0)->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!0=0)";
  3030.          "(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->(0=0->!((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0')))->!0=0)->(((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!0=0)";
  3031.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!0=0";
  3032.          "0=0->((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0";
  3033.          "((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0";
  3034.          "?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!0=0";
  3035.          "?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!0=0";
  3036.          "?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0";
  3037.          "?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0";
  3038.          "(?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->0=0)->(?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!0=0)->!?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3039.          "(?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))->!0=0)->!?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3040.          "!?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3041.          "(0=0->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0";
  3042.          "((0=0->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0)->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->((0=0->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0)";
  3043.          "((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->(0=0->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0";
  3044.          "((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))";
  3045.          "(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->(0=0->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0)->(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0)";
  3046.          "(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->(0=0->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0)->(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0)";
  3047.          "((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0";
  3048.          "!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))";
  3049.          "0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))";
  3050.          "(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))";
  3051.          "((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))";
  3052.          "(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0)->(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->!0=0)";
  3053.          "(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->(0=0->!((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0')))->!0=0)->(((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->!0=0)";
  3054.          "((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->!0=0";
  3055.          "0=0->((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0";
  3056.          "((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0";
  3057.          "?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->!0=0";
  3058.          "?p.?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->!0=0";
  3059.          "?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0";
  3060.          "?p.?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0";
  3061.          "(?p.?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->0=0)->(?p.?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->!0=0)->!?p.?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))";
  3062.          "(?p.?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))->!0=0)->!?p.?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))";
  3063.          "!?p.?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))";
  3064.          "!?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3065.         ];;
  3066. let evenProve =
  3067.         ["0''*f=x";
  3068.          "0''*g=y";
  3069.          "0''*f=x->0''*g=y->0''*f=x&0''*g=y";
  3070.          "0''*g=y->0''*f=x&0''*g=y";
  3071.          "0''*f=x&0''*g=y";
  3072.          "0''*f=x&0''*g=y->(0''*f=x&0''*g=y)|(0''*f=x+0'&0''*g=y+0')";
  3073.          "(0''*f=x&0''*g=y)|(0''*f=x+0'&0''*g=y+0')";
  3074.          "(0''*f=x&0''*g=y)|(0''*f=x+0'&0''*g=y+0')->?q.((0''*f=x&0''*q=y)|(0''*f=x+0'&0''*q=y+0'))";
  3075.          "?q.((0''*f=x&0''*q=y)|(0''*f=x+0'&0''*q=y+0'))";
  3076.          "?q.((0''*f=x&0''*q=y)|(0''*f=x+0'&0''*q=y+0'))->?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3077.          "?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3078.         ];;
  3079. let oddProve =
  3080.         ["0''*f=x'";
  3081.          "0''*g=y'";
  3082.          "@a.(a+0'=a')->(x+0'=x')";
  3083.          "x+0'=x'";
  3084.          "@a.(a+0'=a')->(y+0'=y')";
  3085.          "y+0'=y'";
  3086.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=x'->c=x'->b=c)";
  3087.          "@b.@c.(b=x'->c=x'->b=c)";
  3088.          "@b.@c.(b=x'->c=x'->b=c)->@c.(0''*f=x'->c=x'->0''*f=c)";
  3089.          "@c.(0''*f=x'->c=x'->0''*f=c)";
  3090.          "@c.(0''*f=x'->c=x'->0''*f=c)->(0''*f=x'->x+0'=x'->0''*f=x+0')";
  3091.          "0''*f=x'->x+0'=x'->0''*f=x+0'";
  3092.          "x+0'=x'->0''*f=x+0'";
  3093.          "0''*f=x+0'";
  3094.          "@a.@b.@c.(b=a->c=a->b=c)->@b.@c.(b=y'->c=y'->b=c)";
  3095.          "@b.@c.(b=y'->c=y'->b=c)";
  3096.          "@b.@c.(b=y'->c=y'->b=c)->@c.(0''*g=y'->c=y'->0''*g=c)";
  3097.          "@c.(0''*g=y'->c=y'->0''*g=c)";
  3098.          "@c.(0''*g=y'->c=y'->0''*g=c)->(0''*g=y'->y+0'=y'->0''*g=y+0')";
  3099.          "0''*g=y'->y+0'=y'->0''*g=y+0'";
  3100.          "y+0'=y'->0''*g=y+0'";
  3101.          "0''*g=y+0'";
  3102.          "0''*f=x+0'->0''*g=y+0'->0''*f=x+0'&0''*g=y+0'";
  3103.          "0''*g=y+0'->0''*f=x+0'&0''*g=y+0'";
  3104.          "0''*f=x+0'&0''*g=y+0'";
  3105.          "0''*f=x+0'&0''*g=y+0'->(0''*f=x&0''*g=y)|(0''*f=x+0'&0''*g=y+0')";
  3106.          "(0''*f=x&0''*g=y)|(0''*f=x+0'&0''*g=y+0')";
  3107.          "(0''*f=x&0''*g=y)|(0''*f=x+0'&0''*g=y+0')->?q.((0''*f=x&0''*q=y)|(0''*f=x+0'&0''*q=y+0'))";
  3108.          "?q.((0''*f=x&0''*q=y)|(0''*f=x+0'&0''*q=y+0'))";
  3109.          "?q.((0''*f=x&0''*q=y)|(0''*f=x+0'&0''*q=y+0'))->?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3110.          "?p.?q.((0''*p=x&0''*q=y)|(0''*p=x+0'&0''*q=y+0'))";
  3111.          ];;
  3112.  
  3113. let buildProve a b =
  3114.         let rec number a =
  3115.                 if a = 0 then "0" else (number (a - 1)) ^ "'" in
  3116.         let rec numberTerm a =
  3117.                 if a = 0 then Zero else Increment (numberTerm (a - 1))  in
  3118.         let rec build c a b =
  3119.                 if c = 0 then [] else
  3120.                         ("@a.@b.(0''*a=b->0''*a'=b'')->@b.(0''*" ^ a ^ "=b->0''*" ^ a ^ "'=b'')") ::
  3121.                         ("@b.(0''*" ^ a ^ "=b->0''*" ^ a ^ "'=b'')") ::
  3122.                         ("@b.(0''*" ^ a ^ "=b->0''*" ^ a ^ "'=b'')->(0''*" ^ a ^ "=" ^ b ^ "->0''*" ^ a ^ "'=" ^ b ^ "'')") ::
  3123.                         ("0''*" ^ a ^ "=" ^ b ^ "->0''*" ^ a ^ "'=" ^ b ^ "''") ::
  3124.                         ("0''*" ^ a ^ "'=" ^ b ^ "''") :: (build (c - 1) (a ^ "'") (b ^ "''")) in
  3125.         let substitute e f x g y =
  3126.                 let e = (transformTerm e (Var "x") (numberTerm x)) in
  3127.                 let e = (transformTerm e (Var "y") (numberTerm y)) in
  3128.                 let e = (transformTerm e (Var "f") (numberTerm f)) in
  3129.                 let e = (transformTerm e (Var "g") (numberTerm g)) in
  3130.                 e in
  3131.         let neg a b =
  3132.                 let ra = number (a - 1) in
  3133.                 let da = number (a / 2) in
  3134.                 constructTheorem @ (build (b / 2) "0" "0") @ (build (a / 2) "0" "0") @
  3135.                         (("@a.@b.(a=b->a'=b')->@b.(0''*" ^ da ^ "=b->(0''*" ^ da ^ ")'=b')") ::
  3136.                         ("@b.(0''*" ^ da ^ "=b->(0''*" ^ da ^ ")'=b')") ::
  3137.                         ("@b.(0''*" ^ da ^ "=b->(0''*" ^ da ^ ")'=b')->(0''*" ^ da ^ "=" ^ ra ^ "->(0''*" ^ da ^ ")'=" ^ ra ^ "')") ::
  3138.                         ("0''*" ^ da ^ "=" ^ ra ^ "->(0''*" ^ da ^ ")'=" ^ ra ^ "'") ::
  3139.                         ("(0''*" ^ da ^ ")'=" ^ ra ^ "'") :: (List.map (fun x -> printExpr (substitute (parse_bad x) (a / 2) a (b / 2) b)) lastOneForNeg)) in
  3140.         let result =
  3141.                 if a - 2 * (a / 2) = 1 && b - 2 * (b / 2) = 0 then
  3142.                         neg a b
  3143.                 else if a - 2 * (a / 2) = 0 && b - 2 * (b / 2) = 1 then
  3144.                         (neg b a) @ [printExpr (substitute (parse_bad "!?p.?q.((0''*p=y&0''*q=x)|(0''*p=y+0'&0''*q=x+0'))") (b / 2) b (a / 2) a)]
  3145.                 else if a - 2 * (a / 2) = 0 && b - 2 * (b / 2) = 0 then
  3146.                         constructTheorem @ (build (b / 2) "0" "0") @ (build (a / 2) "0" "0") @
  3147.                                 (List.map (fun x -> printExpr (substitute (parse_bad x) (a / 2) a (b / 2) b)) evenProve)
  3148.                 else
  3149.                         let a = a + 1 in
  3150.                         let b = b + 1 in
  3151.                         constructTheorem @ (build (b / 2) "0" "0") @ (build (a / 2) "0" "0") @
  3152.                                 (List.map (fun x -> printExpr (substitute (parse_bad x) (a / 2) (a - 1) (b / 2) (b - 1))) oddProve) in
  3153.         result;;
  3154.  
  3155. println_string (let doc = parseList (buildProve (read_int ()) (read_int ())) in (printDocument doc)(* ^ "\n" ^ (checkProof doc)*));;
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top