Module docstring
{"# Pointwise operations of finsets
This file defines pointwise algebraic operations on finsets.
Main declarations
For finsets s and t:
* 0 (Finset.zero): The singleton {0}.
* 1 (Finset.one): The singleton {1}.
* -s (Finset.neg): Negation, finset of all -x where x ∈ s.
* s⁻¹ (Finset.inv): Inversion, finset of all x⁻¹ where x ∈ s.
* s + t (Finset.add): Addition, finset of all x + y where x ∈ s and y ∈ t.
* s * t (Finset.mul): Multiplication, finset of all x * y where x ∈ s and y ∈ t.
* s - t (Finset.sub): Subtraction, finset of all x - y where x ∈ s and y ∈ t.
* s / t (Finset.div): Division, finset of all x / y where x ∈ s and y ∈ t.
For α a semigroup/monoid, Finset α is a semigroup/monoid.
As an unfortunate side effect, this means that n • s, where n : ℕ, is ambiguous between
pointwise scaling and repeated pointwise addition; the former has (2 : ℕ) • {1, 2} = {2, 4}, while
the latter has (2 : ℕ) • {1, 2} = {2, 3, 4}. See note [pointwise nat action].
Implementation notes
We put all instances in the locale Pointwise, so that these instances are not available by
default. Note that we do not mark them as reducible (as argued by note [reducible non-instances])
since we expect the locale to be open whenever the instances are actually used (and making the
instances reducible changes the behavior of simp.
Tags
finset multiplication, finset addition, pointwise addition, pointwise multiplication,
pointwise subtraction
","### 0/1 as finsets ","### Finset negation/inversion ","### Finset addition/multiplication ","### Finset subtraction/division ","### Instances ","Note that Finset is not a Group because s / s ≠ 1 in general. "}