IsDominatingSet - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


GraphTheory

  

IsDominatingSet

  

test whether set is dominating set for graph

  

IsIndependentSet

  

test whether set is independent set for graph

 

Calling Sequence

Parameters

Description

Definitions

Examples

Compatibility

Calling Sequence

IsDominatingSet(G,S)

IsIndependentSet(G, S)

Parameters

G

-

undirected graph

S

-

(optional) list or set of vertices

Description

• 

IsDominatingSet(G, S) returns true if the collection of vertices S is a dominating set for G, and returns false otherwise.

• 

IsIndependentSet(G, S) returns true if the collection of vertices S represents an independent set in G, and returns false otherwise.

• 

To find a minimum dominating set or a maximum independent set for G, use MaximumIndependentSet.

Definitions

• 

A dominating set of a graph G is a subset S of the vertices of G, with the condition that every vertex in G must either be an element of S or the neighbor of an element of S.

• 

An independent set of a graph G is a subset S of the vertices of G, with the condition that if any vertices v1 and v2 are both members of S, the graph G must not contain an edge between them. An independent set of G is a clique of the complement of G.

Examples

withGraphTheory:

GPathGraph5

GGraph 1: an undirected graph with 5 vertices and 4 edge(s)

(1)

S11,2,3,4,5

S11,2,3,4,5

(2)

IsDominatingSetG,S1

true

(3)

IsIndependentSetG,S1

false

(4)

S21,3

S21,3

(5)

IsDominatingSetG,S2

false

(6)

IsIndependentSetG,S2

true

(7)

S31,3,5

S31,3,5

(8)

IsDominatingSetG,S3

true

(9)

IsIndependentSetG,S3

true

(10)

Compatibility

• 

The GraphTheory[IsDominatingSet] and GraphTheory[IsIndependentSet] commands were introduced in Maple 2024.

• 

For more information on Maple 2024 changes, see Updates in Maple 2024.

See Also

IsClique

MaximumIndependentSet