GraphTheory[SpecialGraphs] - Maple Programming Help

Home : Support : Online Help : Mathematics : Discrete Mathematics : Graph Theory : GraphTheory Package : SpecialGraphs : GraphTheory/SpecialGraphs/StarGraph

GraphTheory[SpecialGraphs]

 StarGraph
 construct star graph

 Calling Sequence StarGraph(n)

Parameters

 n - positive integer

Description

 • The StarGraph(n) command returns the star graph with n leaves. Namely it returns the complete bipartite graph CompleteGraph(1,n).

Examples

 > $\mathrm{with}\left(\mathrm{GraphTheory}\right):$
 > $\mathrm{with}\left(\mathrm{SpecialGraphs}\right):$
 > $G≔\mathrm{StarGraph}\left(5\right)$
 ${G}{:=}{\mathrm{Graph 1: an undirected unweighted graph with 6 vertices and 5 edge\left(s\right)}}$ (1)
 > $\mathrm{IsTree}\left(G\right)$
 ${\mathrm{true}}$ (2)
 > $\mathrm{DrawGraph}\left(G\right)$