Examples of sample laws: the constant graphon is the binomial random graph (issue #21) #
The sample law of the constant graphon with value p is exactly Mathlib's binomial
random-graph distribution G(V, p) (SimpleGraph.binomialRandom):
Graphon.sampleMass_constGraphon— the graphon-side mass computationsampleMass (constGraphon p) G = p^{e(G)} (1-p)^{\binom{k}{2} - e(G)};Graphon.sampleLaw_const_eq_binomial— equality of measures withG(Fin k, p), viaMeasure.ext_of_singletonand Mathlib'sbinomialRandom_singleton(reused, not reproved);- endpoint
simpcorollaries: atp = 0the law isdirac ⊥, atp = 1it isdirac ⊤.
This file exists so that the binomial-random-graph import stays out of
Graphon/SamplingLaw.lean. The stochastic-block-model law is deliberately deferred
(see issue #21).
The sample mass of a constant graphon: every edge is present independently with
probability p, so the mass of G is p^{e(G)} (1-p)^{\binom{k}{2} - e(G)}.
The constant graphon samples the binomial random graph: the sample law of
constGraphon p on k vertices is Mathlib's G(Fin k, p). The singleton mass formula
SimpleGraph.binomialRandom_singleton is reused from Mathlib; the graphon-side
computation is sampleMass_constGraphon.
At p = 0 the sample law is the point mass at the empty graph.
At p = 1 the sample law is the point mass at the complete graph.