Functions that agree with a fixed function on a set #
The functions b : ι → β that agree with a fixed y on a finite set P of coordinates number
#β ^ #Pᶜ, since the coordinates outside P are free. Mathlib fixes a single coordinate
(Fintype.card_filter_piFinset_eq); this file fixes a set of them.
Main results #
Fintype.card_filter_forall_mem_eq:#{b | ∀ i ∈ P, b i = y i} = #β ^ #Pᶜ.
theorem Fintype.card_filter_forall_mem_eq {ι : Type u_1} {β : Type u_2} [Fintype ι] [DecidableEq ι] [Fintype β] (P : Finset ι) (y : ι → β) [DecidablePred fun (b : ι → β) => ∀ i ∈ P, b i = y i] :
The functions that agree with y on P number #β ^ #Pᶜ. The filter's decidability is an
instance argument, so the lemma rewrites whichever instance elaborated the filter (on Fin n,
Nat.decidableForallFin).