BernoulliGraphDistribution
BernoulliGraphDistribution[n,p]
represents a Bernoulli graph distribution for n-vertex graphs with edge probability p.
Details and Options
- The Bernoulli graph is constructed starting with the complete graph with n vertices and selecting each edge independently through a Bernoulli trial with probability p.
- The following options can be given:
-
DirectedEdges False whether to generate directed edges - BernoulliGraphDistribution can be used with such functions as RandomGraph and GraphPropertyDistribution.
Examples
open allclose allBasic Examples (2)
Scope (4)
Options (2)
DirectedEdges (2)
By default, a Bernoulli graph is undirected:
With the setting DirectedEdges->True, directed Bernoulli graphs are generated:
Applications (3)
After 20 children have spent their first week in kindergarten, the probability that two children have made friends is 0.2:
Find the probability that the social network is connected:
In a snowball fight with 15 participants, and everybody throwing snowballs at everyone else, the probability of being hit by any given participant is 0.4:
Find the size of the largest group where everybody has been hit by everyone else:
Find the largest component fraction when the mean vertex degree is :
Average the result over 100 runs and plot it for different numbers of vertices:
Properties & Relations (6)
Distribution of the number of vertices:
Distribution of the number of edges:
The mean of the number of edges:
Distribution of the degree of a vertex:
The mean of the degree of a vertex:
Connectivity for large n with respect to p:
A Bernoulli graph is almost surely disconnected for :
A Bernoulli graph is almost surely connected for :
Use BernoulliDistribution to simulate a BernoulliGraphDistribution:
Edge probability 1 results in the CompleteGraph:
Text
Wolfram Research (2010), BernoulliGraphDistribution, Wolfram Language function, https://reference.wolfram.com/language/ref/BernoulliGraphDistribution.html.
CMS
Wolfram Language. 2010. "BernoulliGraphDistribution." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/BernoulliGraphDistribution.html.
APA
Wolfram Language. (2010). BernoulliGraphDistribution. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/BernoulliGraphDistribution.html