Documentation

Complexity.Computability.QueryComplexity.Threshold

Query complexity measures of threshold functions and parity #

The threshold function Th^n_j says that at least j of n bits are true. A coordinate i is sensitive for it at x exactly when x has weight j and x i is true, or (for j ≥ 1) weight j - 1 and x i is false (BitString.isSensitiveCoord_threshold_iff). So the sensitivity is j at an input of weight j and n + 1 - j at an input of weight j - 1. Conversely j true bits certify the value 1 and n + 1 - j false bits certify the value 0 (QueryComplexity.certificateComplexityAt_threshold_le). With s(f) ≤ bs(f) ≤ C(f) all three measures agree: for 1 ≤ j ≤ n, s(Th^n_j) = bs(Th^n_j) = C(Th^n_j) = max(j, n + 1 - j). In particular majority has sensitivity ⌊n/2⌋ + 1 for n ≥ 1. The disjunction OR_n = Th^n_1 is sensitive to every bit at the all-false input, so bs(OR_n) = n. A single true bit certifies its value 1, while certifying the value 0 takes all n bits. Flipping any bit flips the parity, so parity is sensitive to every bit at every input (BitString.sensitivityAt_parity), and its sensitivity, block sensitivity and certificate complexity all equal n. The measures are those of [BdW02].

Main results #

References #

A coordinate is sensitive for Th^n_j exactly when it is a true bit of an input of weight j, or (for j ≥ 1) a false bit of an input of weight j - 1.

At an input of weight j, the sensitive coordinates of Th^n_j are its true bits.

At an input of weight j - 1, for j ≥ 1, the sensitive coordinates of Th^n_j are its false bits.

Certificate complexity of Th^n_j at any input is at most max(j, n + 1 - j): j true bits certify the value 1, and n + 1 - j false bits certify the value 0.

bs(Th^n_j) ≤ max(j, n + 1 - j).

theorem Cslib.BitString.sensitivity_threshold {n j : ℕ} (hj : 1 ≤ j) (hjn : j ≤ n) :
sensitivity (threshold n j) = max j (n + 1 - j)

Sensitivity of threshold functions: s(Th^n_j) = max(j, n + 1 - j) for 1 ≤ j ≤ n.

theorem Cslib.BitString.sensitivity_majority {n : ℕ} (hn : 1 ≤ n) :

Sensitivity of majority: s(MAJ_n) = ⌊n/2⌋ + 1 for n ≥ 1.

theorem Cslib.QueryComplexity.blockSensitivity_threshold {n j : ℕ} (hj : 1 ≤ j) (hjn : j ≤ n) :
blockSensitivity (threshold n j) = max j (n + 1 - j)

Block sensitivity of threshold functions: bs(Th^n_j) = max(j, n + 1 - j) for 1 ≤ j ≤ n.

Certificate complexity of threshold functions: C(Th^n_j) = max(j, n + 1 - j) for 1 ≤ j ≤ n.

Disjunction #

The disjunction of n bits is sensitive to every bit at the all-false input.

The disjunction of n bits has block sensitivity n.

Certifying the value 0 of the disjunction at the all-false input takes every bit.

Certificate complexity of disjunction: C(OR_n) = n.

One true bit certifies the value 1 of the disjunction: C₁(OR_n) = 1 for n ≥ 1.

Certifying the value 0 of the disjunction takes every bit: C₀(OR_n) = n.

Parity #

Parity is sensitive to every bit at every input.

The sensitivity of parity is its number of coordinates.

The block sensitivity of parity is its number of coordinates.

The certificate complexity of parity is its number of coordinates.