TuranGraph
The complete r-partite graph on n vertices with parts as equal in size as possible.
✓ checked against that system · ! checked, with disagreements (hover a chip)Wolfram Language
TuranGraph✓TuranGraph(n, r)n vertices split into r parts (sizes differ by at most 1), every pair in DIFFERENT parts joined.SageMath
enumeratio_graph(graphs.TuranGraph(n, r))Typed signatures
| Type | Package | Applies |
|---|---|---|
(integer, integer) -> value | combinatorics | always |
Details
- The extremal K_(r+1)-free graph on n vertices with the most edges (Turán's theorem). r = n gives CompleteGraph(n); r = 1 gives the empty graph on n vertices.
- Vertex-to-part assignment order (which vertices land in the larger parts) is a labelling choice, kernel-unverified against Wolfram's own.
Examples
Applications #
Eccentricities on the five vertices; the last vertex, in the small part, is adjacent to all others
live ↗InOut
About
| Examples | 5 |
|---|---|
| Checked against | Wolfram Language 5 agreeSageMath 1 agree3 differ |
| Crosswalk | Wolfram LanguageSageMath |
Implementation
mapped
sagepackages/oracle/src/mappings.ts See also: CompleteGraph