InducedSubgraph - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Mozilla Firefox.

Online Help

All Products    Maple    MapleSim


GraphTheory

  

InducedSubgraph

  

construct induced subgraph

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

InducedSubgraph(G, S)

Parameters

G

-

graph

S

-

set or list of vertices

Description

• 

The InducedSubgraph command returns the subgraph induced by a specified set (or list) of vertices.

• 

To construct a subgraph using a set of edges, use the Subgraph command.

Examples

> 

with⁡GraphTheory:

> 

C6≔CycleGraph⁡6

C6≔Graph 1: an undirected graph with 6 vertices and 6 edges

(1)
> 

H≔InducedSubgraph⁡C6,1,2,6

H≔Graph 2: an undirected graph with 3 vertices and 2 edges

(2)
> 

Vertices⁡H

1,2,6

(3)
> 

Edges⁡H

1,2,1,6

(4)
> 

with⁡SpecialGraphs:

> 

P≔PetersenGraph⁡

P≔Graph 3: an undirected graph with 10 vertices and 15 edges

(5)
> 

DrawGraph⁡P

> 

H≔InducedSubgraph⁡P,1,2,3,6,7,9

H≔Graph 4: an undirected graph with 6 vertices and 6 edges

(6)
> 

DrawGraph⁡H

See Also

DeleteVertex

Subgraph