File size: 2,433 Bytes
4a56cd6
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
import Mathlib.Data.Fintype.Powerset
import Mathlib.Data.Finset.Union
import Mathlib.Basic.Real.Basic
import Mathlib.Algebra.Order.BigOperators.Group.Finset

namespace OAI

/-!
# Finite families, containment covers, and exceptional sets

All families are ordinary finite sets: repeated generators carry no extra cost.
In contrast, the members of a union tuple may repeat. The exceptional family
uses containment in a union, without any monotonicity assumption on the input.
-/

namespace TalagrandDiscreteConvexity

open scoped BigOperators

abbrev Family (Ξ± : Type*) := Finset (Finset Ξ±)

variable {Ξ± : Type*} [Fintype Ξ±] [DecidableEq Ξ±]

noncomputable section

/-- The mass of a subset under independent Bernoulli coordinates. -/
def bernoulliMass (p : ℝ) (s : Finset Ξ±) : ℝ :=
  p ^ s.card * (1 - p) ^ (Finset.univ \ s).card

/-- The Bernoulli measure of an arbitrary finite family. -/
def familyMeasure (p : ℝ) (D : Family Ξ±) : ℝ :=
  βˆ‘ s ∈ D, bernoulliMass p s

/-- Cost at the specified density, counting each generator once. -/
def cost (p : ℝ) (G : Family Ξ±) : ℝ := βˆ‘ I ∈ G, p ^ I.card

/-- A cover supplies a contained generator for every target set. -/
def Covers (G A : Family Ξ±) : Prop := βˆ€ S ∈ A, βˆƒ I ∈ G, I βŠ† S

/-- Smallness is witnessed by an actual containment cover of cost at most one half. -/
def Small (p : ℝ) (A : Family Ξ±) : Prop :=
  βˆƒ G : Family Ξ±, Covers G A ∧ cost p G ≀ 1 / 2

/-- A union of exactly `k` entries; repetitions are allowed. -/
def unionTuple {k : β„•} (f : Fin k β†’ Finset Ξ±) : Finset Ξ± :=
  Finset.univ.biUnion f

/-- All unions of `k` members of a family. -/
def unionFamily (k : β„•) (D : Family Ξ±) : Family Ξ± := by
  classical
  exact Finset.univ.filter (fun S =>
    βˆƒ f : Fin k β†’ Finset Ξ±, (βˆ€ j, f j ∈ D) ∧ unionTuple f = S)

/-- Sets contained in no union of `k` members of `D`. -/
def exceptional (k : β„•) (D : Family Ξ±) : Family Ξ± := by
  classical
  exact Finset.univ.filter (fun S =>
    βˆ€ f : Fin k β†’ Finset Ξ±, (βˆ€ j, f j ∈ D) β†’ Β¬ S βŠ† unionTuple f)

/-- The subset represented by a Boolean coordinate vector. -/
def cubeSet (x : Ξ± β†’ Bool) : Finset Ξ± :=
  Finset.univ.filter (fun i => x i = true)

/-- The indicator of a family on the Boolean cube. -/
def familyIndicator (D : Family Ξ±) (x : Ξ± β†’ Bool) : ℝ :=
  if cubeSet x ∈ D then 1 else 0

end
end TalagrandDiscreteConvexity

end OAI