Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

randomized.h File Reference

Declaration of randomized graph generators. More...

#include <ogdf/basic/Array.h>
#include <ogdf/basic/Graph_d.h>
#include <ogdf/basic/graph_generators/randomGeographicalThresholdGraph.h>
#include <ogdf/basic/internal/config.h>
#include <functional>
#include <vector>

Go to the source code of this file.

Namespaces

 ogdf
 The namespace for all OGDF objects.
 

Functions

Randomized graph generators
void ogdf::preferentialAttachmentGraph (Graph &G, int nodes, int minDegree)
 Creates a graph where new nodes are more likely to connect to nodes with high degree. More...
 
void ogdf::pruneEdges (Graph &G, int max_edges, int min_deg)
 Removed random edges from /p G until it has less than /p max_edges edges, not removing edges from nodes with degree less than /p min_deg. More...
 
void ogdf::randomBiconnectedGraph (Graph &G, int n, int m)
 Creates a random biconnected graph. More...
 
void ogdf::randomChungLuGraph (Graph &G, Array< int > expectedDegreeDistribution)
 Creates a graph where edges are inserted based on given weights. More...
 
void ogdf::randomDigraph (Graph &G, int n, double p)
 Creates a random (simple) directed graph. More...
 
void ogdf::randomEdgesGraph (Graph &G, std::function< double(node, node)> probability)
 Inserts edges into the given graph based on probabilities given by a callback function. More...
 
void ogdf::randomGeometricCubeGraph (Graph &G, int nodes, double threshold, int dimension=2)
 Creates a random geometric graph by laying out nodes in a unit n-cube. Nodes with a distance < threshold are connected, 0 <= threshold <= sqrt(dimension). The graph is simple. More...
 
void ogdf::randomGraph (Graph &G, int n, int m)
 Creates a random graph. More...
 
void ogdf::randomHierarchy (Graph &G, int n, int m, bool planar, bool singleSource, bool longEdges)
 Creates a random hierarchical graph. More...
 
void ogdf::randomPlanarBiconnectedDigraph (Graph &G, int n, int m, double p=0, bool multiEdges=false)
 Creates a random planar biconnected acyclic (embedded) digraph. More...
 
void ogdf::randomPlanarBiconnectedGraph (Graph &G, int n, int m, bool multiEdges=false)
 Creates a random planar biconnected (embedded) graph. More...
 
void ogdf::randomPlanarCNBGraph (Graph &G, int n, int m, int b)
 Creates a random planar graph, that is connected, but not biconnected. More...
 
void ogdf::randomPlanarConnectedGraph (Graph &G, int n, int m)
 Creates a random connected (simple) planar (embedded) graph. More...
 
void ogdf::randomPlanarTriconnectedGraph (Graph &G, int n, double p1, double p2)
 Creates a random planar triconnected (and simple) graph. More...
 
void ogdf::randomPlanarTriconnectedGraph (Graph &G, int n, int m)
 Creates a random planar triconnected (and simple) graph. More...
 
void ogdf::randomProperMaximalLevelPlaneGraph (Graph &G, std::vector< std::vector< node >> &emb, int N, int K, bool radial)
 Generates a random proper, maximal (radial) level-plane graph. More...
 
void ogdf::randomRegularGraph (Graph &G, int n, int d)
 Creates a random d-regular graph. More...
 
void ogdf::randomSeriesParallelDAG (Graph &G, int edges, double p=0.5, double flt=0.0)
 Creates a random (simple, biconnected) series parallel DAG. More...
 
bool ogdf::randomSimpleConnectedGraph (Graph &G, int n, int m)
 Creates a random simple and connected graph. More...
 
bool ogdf::randomSimpleGraph (Graph &G, int n, int m)
 Creates a random simple graph. More...
 
bool ogdf::randomSimpleGraphByProbability (Graph &G, int n, double pEdge)
 Creates a random simple graph. More...
 
void ogdf::randomTree (Graph &G, int n)
 Creates a random tree (simpler version. More...
 
void ogdf::randomTree (Graph &G, int n, int maxDeg, int maxWidth)
 Creates a random tree. More...
 
void ogdf::randomTriconnectedGraph (Graph &G, int n, double p1, double p2)
 Creates a random triconnected (and simple) graph. More...
 
void ogdf::randomUpwardPlanarBiconnectedDigraph (Graph &G, int n, int m)
 Creates a random upward planar biconnected (embedded) digraph. More...
 
void ogdf::randomWattsStrogatzGraph (Graph &G, int n, int k, double probability)
 Creates a "small world" graph as described by Watts & Strogatz. More...
 
void ogdf::randomWaxmanGraph (Graph &G, int nodes, double alpha, double beta, double width=1.0, double height=1.0)
 Generates a Waxman graph where nodes are uniformly randomly placed in a grid, then edges are inserted based on nodes' euclidean distances. More...
 

Detailed Description

Declaration of randomized graph generators.

Author
Carsten Gutwenger, Markus Chimani, Jöran Schierbaum
License:
This file is part of the Open Graph Drawing Framework (OGDF).
Copyright (C)
See README.md in the OGDF root directory for details.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License Version 2 or 3 as published by the Free Software Foundation; see the file LICENSE.txt included in the packaging of this file for details.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, see http://www.gnu.org/copyleft/gpl.html

Definition in file randomized.h.