Documentation

CslibFrontier.Computability.Circuit.OutputDistribution

Output distributions of circuits #

A circuit with n inputs and m outputs is a sampler: evaluated on uniformly random inputs, it produces a distribution on BitString m, its output distribution (Circuit.outputDist). This is how circuits encode distributions in the Statistical Difference problem [SahaiVadhan2003, §2.2 and §3.1]. Running the circuit on the outputs of another samples the image of the first output distribution (Circuit.outputDist_comp), and k independent copies on disjoint input blocks sample k independent outputs, laid out in consecutive blocks (Circuit.outputDist_replicate).

Main definitions #

Main results #

References #

noncomputable def Cslib.Circuits.Circuit.outputDist {σ : Signature} {n m : ℕ} (I : Interpretation σ Bool) (C : Circuit σ n m) :

The output distribution of a circuit: its outputs on a uniformly random input.

theorem Cslib.Circuits.Circuit.outputDist_comp {σ : Signature} {n m p : ℕ} (I : Interpretation σ Bool) (C : Circuit σ m p) (D : Circuit σ n m) :
outputDist I (C.comp D) = PMF.map (C.eval I) (outputDist I D)

Running C on the outputs of D samples the image of the output distribution of D under C.

Independent copies of a circuit sample independent copies of its output, with the k outputs in consecutive blocks (Cslib.BitString.blocksEquiv).