Loading [MathJax]/jax/output/HTML-CSS/jax.js
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

asked 5 years ago

Captcha gravatar image

How to draw the following graph

I want to write the following code in sagemath but unable to write it:

Suppose we consider the group Zn.

We consider an element aZn and form the subgroup generated by a i.e. a=a,2a,3a,0.

We form a graph G whose vertices are a and a and b are adjacent if either ab or ba .

How to plot the graph G is Sagemath?

I am giving an example to clear the question:

Consider Z4 then consider 0, 1 , 2, 3

Clearly 0=0, 1=1,2,3,0 , 2=2,0, 3=0,1,2,3.

Thus the graph G has vertices as 0, 1 , 2, 3 and 0 is adjacent to 1 , 2, 3,

1 is adjacent to 2 , 0,

2 is adjacent to 1 , 0, 3

and 3 is adjacent to 0, 2

Thus G becomes

image description

How to draw the following graph

I want to write the following code in sagemath but unable to write it:

Suppose we consider the group Zn.

We consider an element aZn and form the subgroup generated by a i.e. a=a,2a,3a,0.

We form a graph G whose vertices are a and a and b are adjacent if either ab or ba .

How to plot the graph G is Sagemath?

I am giving an example to clear the question:

Consider Z4 then consider 0, 1 , 2, 3

Clearly 0=0, 1=1,2,3,0 , 2=2,0, 3=0,1,2,3.

Thus the graph G has vertices as 0, 1 , 2, 3 and 0 is adjacent to 1 , 2, 3,

1 is adjacent to 2 , 0,

2 is adjacent to 1 , 0, 3

and 3 is adjacent to 0, 2

Thus G becomes

image descriptionhttps://imgur.com/Ef9P4uz