필터 지우기
필터 지우기

how to draw a graph

조회 수: 5 (최근 30일)
Kajal Agrawal
Kajal Agrawal 2023년 6월 3일
댓글: Dyuman Joshi 2023년 6월 4일
i have 12 vertices and 36 edges, how to draw a regular graph (all vertices having same degree).
  댓글 수: 3
Kajal Agrawal
Kajal Agrawal 2023년 6월 3일
degree= 2 edges/ vertices
and all the vertices should be same degree. (6-regular graph).
Dyuman Joshi
Dyuman Joshi 2023년 6월 4일
My solution which is currently the accepted answer, is incorrect.
Please accept the other answer, which provides a correct and concise solution to your problem. I shall be deleting my answer shortly.

댓글을 달려면 로그인하십시오.

답변 (1개)

Diwakar Diwakar
Diwakar Diwakar 2023년 6월 3일
To draw a regular graph with 12 vertices and 36 edges, we need to find the degree of each vertex. In a regular graph, all vertices have the same degree.
To find the degree, we can use the formula:
2 * number of edges = sum of degrees of all vertices
In this case, the number of edges is 36, so:
2 * 36 = sum of degrees of all vertices
72 = sum of degrees of all vertices
Since the graph is regular, all vertices will have the same degree, which we can denote as 'd'. Therefore, we have:
12 * d = 72
Dividing both sides of the equation by 12, we find:
d = 72 / 12
d = 6
So, each vertex in the graph will have a degree of 6.
Now, let's draw the graph. Since it is a regular graph, we can use a symmetric pattern to make it easier to visualize. Here's one possible way to draw the graph:
1 -- 2 -- 3 -- 4 -- 5 -- 6 -- 7 -- 8 -- 9 -- 10 -- 11 -- 12 -- 1
In this representation, the vertices are numbered from 1 to 12, and each vertex is connected to the next vertex in a circular manner. Each vertex is connected to its two neighboring vertices, and the degree of each vertex is 6.
Note that there can be multiple valid drawings of a regular graph with the same specifications. The example above is just one possible representation.
  댓글 수: 3
Kajal Agrawal
Kajal Agrawal 2023년 6월 4일
thank you so much
John D'Errico
John D'Errico 2023년 6월 4일
As I think about it, this can lead into greater mathematical depths. For example the concept of a derangement.
A derangement is a permutation of a set, such that no element resides in its original position. For even 12 elements, the number of possible derangements is pretty large.
As well, The OEIS tells us there are 176,214,841 possible derenagements of 12 elements.
There we would also learn the subfactorial is useful to enumerate that number.
But you should also note that at least SOME of the derangements of the numbers 1:12 can lead to a regular graph with degree 2. And then we can use that idea to build a graph where each node has degree 6.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Directed Graphs에 대해 자세히 알아보기

태그

제품


릴리스

R2013a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by