Hitting Set

Lax496464.WH_C2_HittingSet · concepts/Lax496464/WH_C2_HittingSet.lean · lax-496464

definition

Loading review…

Sign in with ORCID

Community review

Flags

Each flag is tied to a public ORCID identity and explains why this concept may be incorrect.

No flags have been submitted.

    Community review

    Flag this concept

    State precisely what appears incorrect. This explanation will be public under your ORCID name.

    No source line selected.

    Natural Language Statement

    Definition

    pp-Hitting-Set. Instance: a hypergraph — a universe and a family of subsets of it — and k∈Nk \in \mathbb N. Parameter: kk. Question: is there a set of kk elements of the universe that meets every set of the family? [FG06, Example 4.42]

    Concept map
    7 concepts; 3 descendants hidden
    100%
    Proven claimDefinitionThis conceptRelated conceptA → B: B builds on A

    Lean source view on GitHub

    1import Lax888481.ParameterizedComplexity
    2import Lax496464.HittingSet
    3
    4/-!
    5---
    6title: Hitting Set
    7type: definition
    8---
    9**pp-Hitting-Set.** *Instance:* a hypergraph — a universe and a family of subsets of it — and
    10k∈Nk \in \mathbb N. *Parameter:* kk. *Question:* is there a set of kk elements of the universe that
    11meets every set of the family? [FG06, Example 4.42]
    12
    13# Formalization Notes
    14
    15The instances and the question are those of the Hitting Set of the just-in-time flow shop part of
    16this submission (`Lax496464.HittingSet`): a universe {0,…,n−1}\{0,\dots,n-1\}, sets
    17F0,…,Fm−1F_0,\dots,F_{m-1} and an exact size kk. The word is its binary encoding of the instance with kk,
    18each bit written as the number 00 or 11. Hardness results for this problem are therefore results
    19about the problem the flow shop reductions start from.
    20
    21The binary code is prefix-free, so a word encodes at most one instance and one kk; the parameter
    22of a word is the kk it encodes. Since nn and kk are written in binary, a reduction from this
    23problem that ranges over the universe first restricts it to the elements occurring in the sets.
    24-/
    25
    26namespace Lax496464.WH_C2_HittingSet
    27
    28open Lax496464.HittingSet
    29open Lax888481.ParameterizedComplexity (Problem)
    30
    31/-- The word of an instance with solution size `k`: its binary word, one number `0` or `1` per
    32bit. -/
    33def word (P : Instance) (k : ℕ) : List ℕ := (encodeInstance P k).map fun b => if b then 1 else 0
    34
    35open Classical in
    36/-- The solution size a word encodes (`0` on other words). -/
    37noncomputable def sizeParam (x : List ℕ) : ℕ :=
    38 if h : ∃ p : Instance × ℕ, x = word p.1 p.2 then (Classical.choose h).2 else 0
    39
    40/-- **`p-Hitting-Set`**. -/
    41noncomputable def HittingSet : Problem where
    42 Domain := {x | ∃ P k, x = word P k}
    43 Yes x := ∃ P k, x = word P k ∧ P.HasHittingSet k
    44 param := sizeParam
    45
    46end Lax496464.WH_C2_HittingSet
    47
    Formalization Notes

    The instances and the question are those of the Hitting Set of the just-in-time flow shop part of this submission (Lax496464.HittingSetLax496464.HittingSet): a universe {0,…,n−1}\{0,\dots,n-1\}, sets F0,…,Fm−1F_0,\dots,F_{m-1} and an exact size kk. The word is its binary encoding of the instance with kk, each bit written as the number 00 or 11. Hardness results for this problem are therefore results about the problem the flow shop reductions start from.

    The binary code is prefix-free, so a word encodes at most one instance and one kk; the parameter of a word is the kk it encodes. Since nn and kk are written in binary, a reduction from this problem that ranges over the universe first restricts it to the elements occurring in the sets.

    Discussion

    Ask a question or add context. Endorsements and structured flags are kept in the review panel above.

    Loading discussion…