diff options
| author | Jason Gross | 2018-12-03 16:45:49 -0500 |
|---|---|---|
| committer | Jason Gross | 2019-01-24 14:29:03 -0500 |
| commit | 0c99020482e96ceb05799c47ffbcaef0e89b4b1f (patch) | |
| tree | cd5c1017a6c3d98f6d3d7da76ab90ffad0467156 | |
| parent | 7bc08910ad7451d5e45102653d33e89aed5ae12b (diff) | |
Don't bundle Z.div_mod_quot_rem into zify
Alas, I have not had time to work on imrpoving the performance of nia,
and there has been a request to include this tactic (which is useful on
its own) without bundling it into `zify`. So that is what we do here.
I leave the definition of it in `PreOmega` in case we want to eventually
include it in `zify`/`nia`.
| -rw-r--r-- | doc/sphinx/addendum/micromega.rst | 4 | ||||
| -rw-r--r-- | plugins/omega/PreOmega.v | 2 | ||||
| -rw-r--r-- | test-suite/success/Nia.v | 3 |
3 files changed, 6 insertions, 3 deletions
diff --git a/doc/sphinx/addendum/micromega.rst b/doc/sphinx/addendum/micromega.rst index 1aa4a23b5c..2ace8a59e1 100644 --- a/doc/sphinx/addendum/micromega.rst +++ b/doc/sphinx/addendum/micromega.rst @@ -250,8 +250,8 @@ obtain :math:`-1`. By Theorem :ref:`Psatz <psatz_thm>`, the goal is valid. .. [#] Support for :g:`nat` and :g:`N` is obtained by pre-processing the goal with the ``zify`` tactic. -.. [#] Support for :g:`Z.div` and :g:`Z.modulo` is obtained by pre-processing the goal with - the `Z.div_mod_to_quot_rem` tactic, which is called by `zify`. +.. [#] Support for :g:`Z.div` and :g:`Z.modulo` may be obtained by pre-processing the goal with + the ``Z.div_mod_to_quot_rem`` tactic after manually running ``zify``. .. [#] Sources and binaries can be found at https://projects.coin-or.org/Csdp .. [#] Variants deal with equalities and strict inequalities. .. [#] In practice, the oracle might fail to produce such a refutation. diff --git a/plugins/omega/PreOmega.v b/plugins/omega/PreOmega.v index 1e0922e1ca..08bfec84bc 100644 --- a/plugins/omega/PreOmega.v +++ b/plugins/omega/PreOmega.v @@ -455,4 +455,4 @@ Ltac zify_N := repeat zify_N_rel; repeat zify_N_op; unfold Z_of_N' in *. (** The complete Z-ification tactic *) -Ltac zify := repeat (zify_nat; zify_positive; zify_N); zify_op; Z.div_mod_to_quot_rem. +Ltac zify := repeat (zify_nat; zify_positive; zify_N); zify_op. diff --git a/test-suite/success/Nia.v b/test-suite/success/Nia.v index da0b2a7a83..9a13e41e07 100644 --- a/test-suite/success/Nia.v +++ b/test-suite/success/Nia.v @@ -2,6 +2,9 @@ Require Import Coq.ZArith.ZArith. Require Import Coq.micromega.Lia. Open Scope Z_scope. +(** Add [Z.div_mod_to_quot_rem] to the end of [zify], just for this file *) +Ltac zify ::= repeat (zify_nat; zify_positive; zify_N); zify_op; Z.div_mod_to_quot_rem. + Lemma Z_zerop_or x : x = 0 \/ x <> 0. Proof. nia. Qed. Lemma Z_eq_dec_or (x y : Z) : x = y \/ x <> y. Proof. nia. Qed. |
