Documentation

Mathlib.Tactic.GrindAttrs

Custom grind-sets #

In this file we declare custom grind attributes and tactics that call grind using only these grind attributes. These grind sets are helpful because they can contain a lot of specialized ways to prove a particular problem.

Currently, this implements the compactness and closedness grind attribute and tactic.

Usage Notes #

These tactics can be useful for various purposes:

Implementation Notes #

We define these grind sets so that we can aggressively tag lemmas in one particular topic as grind lemmas for a particular grind set. For the default grind set we should be a lot more careful with tagging lemmas, to avoid slowing down grind, but since these specialized grind attributes don't have any tagged lemmas outside its specialized domain, it should still be performant.

These tactics will not use the full power of grind, and could disable some of the grind engines if these would slow down these tactics. We could have alternatively used a tactic similar to apply_rules here, but we think that the efficient implementation of grind is helpful even for these simpler tactics. For example, we can safely tag both the following lemmas, and grind will add both pairs of hypotheses to the whiteboard without having to backtrack.

IsCompact.inter_left : IsClosed s → IsCompact t → IsCompact (s ∩ t)
IsCompact.inter_right : IsCompact s → IsClosed t → IsCompact (s ∩ t)

We will tag transition theorems, e.g. Set.Finite.isCompact : Finite s → IsCompact s should be tagged @[compactness .], even if compactness won't contain lemmas about finite sets. The advantages of this are that we can use local finiteness hypotheses, and this will ensure that the different grind sets will interact well with each other. For the same reason we tag lemmas that involve other properties, e.g. IsCompact.inter_left

To do #

The compactness attribute is a custom grind-set specialized to prove that sets are compact. It is called by the compactness tactic.

Equations
  • One or more equations did not get rendered due to their size.
Instances For

    The compactness attribute is a custom grind-set specialized to prove that sets are compact. It is called by the compactness tactic.

    Equations
    • One or more equations did not get rendered due to their size.
    Instances For

      The compactness attribute is a custom grind-set specialized to prove that sets are compact. It is called by the compactness tactic.

      Equations
      • One or more equations did not get rendered due to their size.
      Instances For

        The compactness attribute is a custom grind-set specialized to prove that sets are compact. It is called by the compactness tactic.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For

          compactness is a simple tactic that tries various lemmas to prove that a set is compact. It is implemented using grind, and has the same configuration options as grind.

          Use grind only [compactness, closedness] instead if you want to prove that the closure of sets are compact.

          It also exists as a grind attribute, and can be combined with other grind attributes using grind only [compactness, ...].

          Equations
          Instances For

            compactness is a simple tactic that tries various lemmas to prove that a set is compact. It is implemented using grind, and has the same configuration options as grind.

            Use grind only [compactness, closedness] instead if you want to prove that the closure of sets are compact.

            It also exists as a grind attribute, and can be combined with other grind attributes using grind only [compactness, ...].

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For

              The closedness attribute is a custom grind-set specialized to prove that sets are closed. It is called by the closedness tactic.

              Equations
              • One or more equations did not get rendered due to their size.
              Instances For

                The closedness attribute is a custom grind-set specialized to prove that sets are closed. It is called by the closedness tactic.

                Equations
                • One or more equations did not get rendered due to their size.
                Instances For

                  The closedness attribute is a custom grind-set specialized to prove that sets are closed. It is called by the closedness tactic.

                  Equations
                  • One or more equations did not get rendered due to their size.
                  Instances For

                    The closedness attribute is a custom grind-set specialized to prove that sets are closed. It is called by the closedness tactic.

                    Equations
                    • One or more equations did not get rendered due to their size.
                    Instances For

                      closedness is a simple tactic that tries various lemmas to prove that a set is closed, and reasoning about the closure of sets. It is implemented using grind, and has the same configuration options as grind.

                      It also exists as a grind attribute, and can be combined with other grind attributes using grind only [closedness, ...].

                      Equations
                      Instances For

                        closedness is a simple tactic that tries various lemmas to prove that a set is closed, and reasoning about the closure of sets. It is implemented using grind, and has the same configuration options as grind.

                        It also exists as a grind attribute, and can be combined with other grind attributes using grind only [closedness, ...].

                        Equations
                        • One or more equations did not get rendered due to their size.
                        Instances For