1 Introduction

Throughout this paper, graphs are finite, simple and undirected. Let \(\Gamma \) be a graph with vertex set \(V(\Gamma )\) and edge set \(E(\Gamma )\). For \(u,v\in V(\Gamma )\), we say u is adjacent to v if there is an edge between u and v, and we denote it by \(u \sim v\) (or \(uv \in E(\Gamma )\)). By degree of a vertex v in \(\Gamma \), we mean the number of edges incident with v and we denote it as deg(v). We denote the complete graph on n vertices by \(K_n\) and the star graph on \(m+1\) vertices by \(K_{1,m}\). We refer to West (1996) for other unexplained graph theoretic terminologies used in this paper.

For two graphs \(\Gamma _1\) and \(\Gamma _2\) with disjoint vertex sets, the join graph \(\Gamma _1 \vee \Gamma _2\) of \(\Gamma _1\) and \(\Gamma _2\) is the graph obtained from the union of \(\Gamma _1\) and \(\Gamma _2\) by adding new edges from each vertex of \(\Gamma _1\) to every vertex of \(\Gamma _2.\) The following is a generalization of the definition of join graph (which is called generalized composition graph in Schwenk (1974)):

Definition 1.1

Let \(\Im \) be a graph on k vertices with \(V(\Im ) = \{v_1,v_2, \ldots , v_k\}\) and let \(\Gamma _1, \Gamma _2, \ldots , \Gamma _k\) be pairwise vertex disjoint graphs. The \(\Im \)-generalized join graph \(\Im [\Gamma _1, \Gamma _2, \ldots , \Gamma _k]\) of \(\Gamma _1, \Gamma _2, \ldots , \Gamma _k\) is the graph formed by replacing each vertex \(v_i\) of \(\Im \) by the graph \(\Gamma _i\) and then joining each vertex of \(\Gamma _i\) to every vertex of \(\Gamma _j\) whenever \(v_i \sim v_j\) in \(\Im \).

Note that \(K_2[\Gamma _1,\Gamma _2]\) coincides with the usual join \(\Gamma _1 \vee \Gamma _2\) of \(\Gamma _1\) and \(\Gamma _2\). The following result is useful and tells about the connectedness of \(\Im [\Gamma _1, \Gamma _2, \ldots , \Gamma _k]\).

Lemma 1.2

(Chattopadhyay et al. 2020, Lemma 2.2) Let \(\Im \) be a graph on k vertices with \(V(\Im ) = \{v_1,v_2, \ldots , v_k\}\) and let \(\Gamma _1,\Gamma _2, \ldots , \Gamma _k\) be pairwise vertex disjoint graphs. If the \(\Im \)-generalized join graph \(\Im [\Gamma _1, \Gamma _2, \ldots , \Gamma _k]\) is connected then \(\Im \) is connected. Conversely, if \(k\ge 2\) and \(\Im \) is connected then \(\Im [\Gamma _1, \Gamma _2, \ldots , \Gamma _k]\) is connected.

Graphs defined on groups have a long history. Many graphs are defined with vertex set being a group G and the edge set reflecting the structure of G in some way, for example, Cayley graph, commuting graph, power graph, prime graph, intersection graph etc. For more on different graphs defined on groups, we refer to the survey paper by Cameron (2022). Add to this study, Arunkumar et al. in (2022), introduced the notion of super graphs on groups. Let G be a finite group and let \(\mathcal {R}\) be an equivalence relation defined on G. For \(g\in G\), let \([g]_{\mathcal {R}}\) be the \(\mathcal {R}\)-equivalence class of g in G. Let \(\Gamma \) be a graph with \(V(\Gamma )=G\). The \(\mathcal {R}\)-super \(\Gamma \) graph is the simple graph with vertex set G and two vertices g and h are adjacent if and only if there exists \(g'\in [g]_{\mathcal {R}}\) and \(h'\in [h]_{\mathcal {R}}\) such that \(g'\) and \(h'\) are adjacent in the graph \(\Gamma \). It is also assumed that the subgraph induced by the vertices of \([g]_{\mathcal {R}}\) in the \(\mathcal {R}\)-super \(\Gamma \) graph is complete and the reason has been discussed in Arunkumar et al. (2022) (see Sect. 1.2). In this article we have extended this notion of super graph on groups to any simple graph \(\Gamma \) over an equivalence relation on \(V(\Gamma )\).

The paper is organized as follows: In Sect. 2, some known results related to different matrices associated with graphs are discussed. In Sect. 3, the \(\mathcal {R}\)-super graph of a graph is defined and its adjacency and Laplacian characteristic polynomials are studied. In Sect. 4, we determine the adjacency and Laplacian spectrum of conjugacy super commuting graphs and order super commuting graphs of some classes of nonabelian groups.

2 Preliminaries

Study of graph spectra is one of the most prevalent quests in graph theory. It has applications in various subjects like biology, chemistry, physics, economics, computer science, information and communication technologies, for example see Trinajstic (1992); Van Mieghem (2010) and references therein. Different approaches have been considered to study spectral properties of several graphs, one can refer to Cvetković et al. (1982) for a comprehensive study of the literature of graph spectra.

There are several matrices defined on a graph. Among these, the spectrum of adjacency and Laplacian matrices are studied most frequently. Let \(\Gamma \) be a finite simple graph with vertex set \(V(\Gamma )=\{v_1,v_2,\ldots ,v_n\}\). The adjacency matrix of \(\Gamma \) is the \(n\times n\) matrix \(A(\Gamma )=(a_{ij})\) where \(a_{ij}=1\) if \(v_i \sim v_j\) and 0 otherwise. The Laplacian matrix \(L(\Gamma )\) of \(\Gamma \) is defined as \(L(\Gamma )=D(\Gamma ) - A(\Gamma ),\) where \(D(\Gamma )=\textrm{diag}(d_1, d_2, \ldots , d_n)\) with \(d_i=deg(v_i)\), \(i = 1, 2, \ldots , n\). It is well known that \(L(\Gamma )\) is symmetric and positive semidefinite with the smallest eigenvalue 0. For more on adjacency matrices of graphs, we refer to the book Cvetković et al. (1982, 2010) and for Laplacian matrices of graphs, we refer to the survey papers by Merris (1994) and Mohar (1992).

Let B be a square matrix. The spectrum of B, denoted by \(\sigma (B)\), is the multiset of all the eigenvalues of B. If \(\lambda _1< \lambda _2< \cdots < \lambda _r\) be the distinct eigenvalues of B with multiplicities \(m_1, m_2, \ldots , m_r\), respectively then we shall denote the spectrum of B by \(\displaystyle \sigma (B)=\begin{pmatrix} \lambda _1 &{} \lambda _2 &{} \cdots &{} \lambda _r\\ m_1 &{} m_2 &{} \cdots &{} m_r \end{pmatrix}\). It is known that \(\displaystyle \sigma (A(K_n))=\begin{pmatrix} -1 &{} n-1\\ n-1 &{} 1 \end{pmatrix}\) and \(\displaystyle \sigma (L(K_n))=\begin{pmatrix} 0 &{} n \\ 1 &{} n-1 \end{pmatrix}\).

By \(\chi (B,x)\) and det(B), we mean the characteristic polynomial and the determinant of B, respectively. We denote the square matrix of order n having all the entries 1 by \(J_n.\) A principal submatrix of B is a matrix obtained from B by deleting some rows and corresponding columns. The following theorem provides an important relation between the eigenvalues of an \(n\times n\) symmetric matrix and its principal submatrices.

Theorem 2.1

(Horn and Johnson 1990, Interlacing Theorem) Let B be an \(n\times n\) real symmetric matrix and let m be an integer with \(1\le m \le n.\) Let \(B_m\) be an \(m\times m\) principal submatrix of B. Suppose \(\lambda _1 \le \cdots \le \lambda _n\) are the eigenvalues of B and \(\beta _1 \le \cdots \le \beta _m\) are the eigenvalues of \(B_m\). Then

$$\begin{aligned}\lambda _k \le \beta _k \le \lambda _{k + n -m} ~ \text {for} ~k=1, 2, \dots , m. \end{aligned}$$

In particular if \(m = n-1,\) then

$$\begin{aligned}\lambda _1 \le \beta _1 \le \lambda _{2}\le \beta _2 \le \lambda _{3} \le \cdots \le \beta _{n - 1} \le \lambda _{n}.\end{aligned}$$

To study the characteristic polynomials of different matrices associated with a graph simultaneously, the generalised characteristic polynomial is introduced in Cvetković et al. (1982). The generalized characteristic polynomial of the graph \(\Gamma \) is a bivariate polynomial, defined as

$$\begin{aligned}\phi _{\Gamma }(x, t) = \textrm{det} (xI_n - (A(\Gamma ) - tD(\Gamma ))).\end{aligned}$$

The following remark is straightforward.

Remark 2.2

Let \(\Gamma \) be a graph on n vertices. Then

  • \(\chi (A(\Gamma ), x) = \phi _{\Gamma }(x, 0);\)

  • \(\chi (L(\Gamma ), x) = (-1)^n \phi _{\Gamma }(-x, 1).\)

The next result tells about the generalized characteristic polynomial of generalized join of a family of regular graphs, which is very useful for the study of the spectrum of super graphs defined on groups.

Theorem 2.3

(Chen and Chen 2019, Theorem 3.1) Let \(\Im \) be a connected graph with \(V(\Im )=\{v_1,v_2,\ldots ,v_k\}\) and let \(\Gamma =\Im [\Gamma _1, \Gamma _2, \ldots , \Gamma _k]\) be the \(\Im \)-generalized join graph of \(\Gamma _1, \Gamma _2, \ldots , \Gamma _k\), where \(\Gamma _i\) is an \(r_i\)-regular graph with \(n_i\) vertices for \(i = 1, \ldots , k\). Then

$$\begin{aligned}\phi _{\Gamma }(x, t) = \chi (N(t), x) \prod \limits _{i = 1}^{k} \frac{\phi _{\Gamma _i}(x + tN_i, t)}{x - r_i + t(r_i + N_i)}, \end{aligned}$$

where \(N(t) = \displaystyle \begin{bmatrix} r_1 -t(r_1 + N_1) &{} \sqrt{n_1n_2}\rho _{12} &{} \cdots &{} \sqrt{n_1n_k}\rho _{1k} \\ \sqrt{n_1n_2}\rho _{12} &{} r_2 -t(r_2 + N_2) &{} \cdots &{} \sqrt{n_2n_k}\rho _{2k}\\ \; \; \vdots &{} \; \; \vdots &{} \ddots &{} \; \; \vdots \\ \sqrt{n_1n_k}\rho _{1k} &{} \sqrt{n_2n_k}\rho _{2k} &{} \cdots &{} r_k -t(r_k + N_k) \end{bmatrix}\) with

\(N_i = \sum \limits _{v_iv_j \in E(\Im )} n_j\) and \(\rho _{ij} = \rho _{ji} = \left\{ \begin{array}{ll} 1 &{} \quad v_iv_j \in E(\Im )\text{, }\\ 0&{} \quad \text{ otherwise. }\end{array} \right. \)

3 \(\mathcal {R}\)-super graph of a graph

Let X be a nonempty set and let \(\mathcal {R}\) be an equivalence relation on X. For \(x\in X\), we denote the \(\mathcal {R}\)-equivalence class of x by \([x]_{\mathcal {R}}\). Let \(\mathcal {R}_1\) and \(\mathcal {R}_2\) be two equivalence relations on X. We say \(\mathcal {R}_1\) is contained in \(\mathcal {R}_2\), denoted by \(\mathcal {R}_1\subseteq \mathcal {R}_2\) if \([x]_{\mathcal {R}_1}\subseteq [x]_{\mathcal {R}_2}\) for any \(x\in X\). Let \(T_X\) be the set of all equivalence relations on X. Then \((T_X, \; \subseteq )\) is a partially ordered set with \(\mathcal {R}_l\) and \(\mathcal {R}_g\) as the least and the greatest elements respectively, where for any \(x\in X\), \([x]_{_{\mathcal {R}_l}}=\{x\}\) and \([x]_{_{\mathcal {R}_g}}=X\). For a given graph \(\Gamma \), we will now define some graphs based on the equivalence relation on \(V(\Gamma )\).

Let \(\Gamma \) be a graph and let \(\mathcal {R}\) be an equivalence relation on \(V(\Gamma )\). Let \(C_1, C_2, \ldots , C_k\) be the distinct \(\mathcal {R}\)-equivalence classes of \(V(\Gamma )\) with \(|C_i|=n_i\), for \(1\le i \le k\). The \(\mathcal {R}\)-compressed \(\Gamma \) graph \(\Im _{_{\Gamma ^{\mathcal {R}}}}\) is a simple graph with \(V(\Im _{_{\Gamma ^{\mathcal {R}}}})=\{C_1, C_2, \ldots , C_k\}\) and two distinct vertices \(C_i\) and \(C_j\) are adjacent if there exist \(x \in C_i\) and \(y \in C_j\) such that x is adjacent to y in \(\Gamma \). We now define a super graph of \(\Gamma \) which is a generalization of super graphs defined on groups.

The \(\mathcal {R}\)-super \(\Gamma \) graph \(\Gamma ^{\mathcal {R}}\) is a simple graph with vertex set \(V(\Gamma )\) and two distinct vertices are adjacent if either they are in the same \(\mathcal {R}\)-equivalence class or there are elements in their respective \(\mathcal {R}\)-equivalence classes that are adjacent in the original graph \(\Gamma \).

Note that if \([v]_{\mathcal {R}}=\{v\}\) for any \(v\in V(\Gamma )\) then \(\Gamma ^{\mathcal {R}}=\Gamma \) and if \([v]_{\mathcal {R}}=V(\Gamma )\) for any \(v\in V(\Gamma )\) then \(\Gamma ^{\mathcal {R}}\) is a complete graph with vertex set \(V(\Gamma )\). The proof of the following result on \(\Gamma ^{\mathcal {R}}\) is straight forward and hence omitted.

Proposition 3.1

Let \(\Gamma \) be a graph and let \(\mathcal {R}_1\) and \(\mathcal {R}_2\) be two equivalence relations on \(V(\Gamma )\). If \(\mathcal {R}_1\subseteq \mathcal {R}_2\) then \(\Gamma ^{\mathcal {R}_1}\) is a spanning subgraph of \(\Gamma ^{\mathcal {R}_2}\).

The next result tells about the structure of \(\Gamma ^{\mathcal {R}}\) in terms of generalized join of complete graphs.

Theorem 3.2

Let \(\Gamma \) be a graph and let \(\mathcal {R}\) be an equivalence relation on \(V(\Gamma )\). Let \(C_1, C_2, \ldots , C_k\) be the distinct \(\mathcal {R}\)-equivalence classes of \(V(\Gamma )\) with \(|C_i|=n_i\) for \(1\le i \le k\). Then \(\Gamma ^{\mathcal {R}}\) is isomorphic to \(\Im _{_{\Gamma ^{R}}}[K_{n_1}, K_{n_2},\ldots , K_{n_k}].\)

Proof

It is clear from the construction of \(\Gamma ^{\mathcal {R}}\) that the induced subgraph of \(\Gamma ^{\mathcal {R}}\) with vertex set \(C_i\) is isomorphic to \(K_{n_i},\) for \(1\le i \le k.\) The result follows from the definition of generalized join graph and the construction of \(\mathcal {R}\)-compressed \(\Gamma \) graph. \(\square \)

Consider the graph \(\Gamma \) with \(V(\Gamma )=\{v_1,v_2,v_3\}\) and \(E(\Gamma )=\{v_2v_3\}\). Let \(\mathcal {R}\) be the equivalence relation on \(V(\Gamma )\) with equivalence classes \(C_1=\{v_1,v_2\}\) and \(C_2=\{v_3\}\). Then \(\Im _{_{\Gamma ^{\mathcal {R}}}}\) is isomorphic to \(K_2\). In this case, though \(\Gamma \) is disconnected but the \(\mathcal {R}\)-compressed \(\Gamma \) graph is connected. The next result is a straight forward application of Theorem 3.2 and Lemma 1.2 and hence the proof is omitted. It tells about how both the graphs \(\Gamma \) and \(\Im _{_{\Gamma ^{\mathcal {R}}}}\) are related through connectedness.

Theorem 3.3

Let \(\Gamma \) be a graph and let \(\mathcal {R}\) be an equivalence relation on \(V(\Gamma )\). Let \(C_1, C_2, \ldots , C_k\) be the distinct \(\mathcal {R}\)-equivalence classes of \(V(\Gamma )\) and let \(\Gamma _i\) be the induced subgraph of \(\Gamma \) with vertex set \(C_i\), for \(1\le i \le k\). If \(\Gamma \) is connected then \(\Im _{_{\Gamma ^{\mathcal {R}}}}\) is connected. Conversely, if \(\Im _{_{\Gamma ^{\mathcal {R}}}}\) is connected and all the \(\Gamma _i\)s are connected then \(\Gamma \) is connected.

We will now discuss the adjacency and Laplacian characteristic polynomials of the \(\mathcal {R}\)-super \(\Gamma \) graph \(\Gamma ^{\mathcal {R}}\). Let \(\Gamma \) be a connected graph. Let \(\mathcal {R}\) be an equivalence relation on \(V(\Gamma )\) with k distinct equivalence classes. If \(k\le 2\) then \(\Gamma ^{\mathcal {R}}\) is complete. So, for rest of this section, we consider \(k\ge 3\).

Theorem 3.4

Let \(\Gamma \) be a connected graph on n vertices and let \(\mathcal {R}\) be an equivalence relation on \(V(\Gamma )\). Let \(C_1, C_2, \ldots , C_k\) be the distinct \(\mathcal {R}\)-equivalence classes of \(V(\Gamma )\) with \(|C_i|=n_i\) for \(1\le i \le k\). Suppose \(A(\Im _{_{\Gamma ^{\mathcal {R}}}})=[\rho _{ij}]\) and \( N_i = \sum \limits _{C_iC_j \in E(\Im _{_{\Gamma ^{\mathcal {R}}}})}n_j\), for \(1\le i \le k.\) Then we have the following:

  1. (i)

    The characteristic polynomial of \(A(\Gamma ^{\mathcal {R}})\) is given by

    $$\begin{aligned} \chi (A(\Gamma ^{\mathcal {R}}), x) = \chi (N(0), x) (x + 1)^{n - k}, \end{aligned}$$

    where \(N(0) = \displaystyle \begin{bmatrix} n_1-1 &{} \sqrt{n_1n_2}\rho _{12} &{} \cdots &{} \sqrt{n_1n_k}\rho _{1k} \\ \sqrt{n_1n_2}\rho _{12} &{} n_2-1 &{} \cdots &{} \sqrt{n_2n_k}\rho _{2k}\\ \; \; \vdots &{} \; \; \vdots &{} \ddots &{} \; \; \vdots \\ \sqrt{n_1n_k}\rho _{1k} &{} \sqrt{n_2n_k}\rho _{2k} &{} \cdots &{} n_k-1 \end{bmatrix}.\)

  2. (ii)

    The characteristic polynomial of \(L(\Gamma ^{\mathcal {R}})\) is given by

    $$\begin{aligned}\chi (L(\Gamma ^{\mathcal {R}}), x) = \chi (-N(1), x) \prod \limits _{i = 1}^{k} (x- N_i- n_i)^{n_i - 1},\end{aligned}$$

    where \(N(1) = \displaystyle \begin{bmatrix} - N_1 &{} \sqrt{n_1n_2}\rho _{12} &{} \cdots &{} \sqrt{n_1n_k}\rho _{1k} \\ \sqrt{n_1n_2}\rho _{12} &{} -N_2 &{} \cdots &{} \sqrt{n_2n_k}\rho _{2k}\\ \; \; \vdots &{} \; \; \vdots &{} \ddots &{} \; \; \vdots \\ \sqrt{n_1n_k}\rho _{1k} &{} \sqrt{n_2n_k}\rho _{2k} &{} \cdots &{}- N_k \end{bmatrix}.\)

Proof

By Theorem 3.3, \(\Im _{_{\Gamma ^{\mathcal {R}}}}\) is connected as \(\Gamma \) is connected. For \(1\le i \le k\), the induced subgraph of \(\Gamma ^{\mathcal {R}}\) with vertex set \(C_i\) is isomorphic to \(K_{n_i}\) and by Theorem 3.2, \(\Gamma ^{\mathcal {R}}\) is isomorphic to \(\Im _{_{\Gamma ^{R}}}[K_{n_1}, K_{n_2},\ldots , K_{n_k}].\)

We have

\(\begin{aligned} \phi _{K_{n_i}}(x + tN_i, t)&=\textrm{det} [(x+tN_i)I_{n_i} - A(K_{n_i}) + t(n_i-1)I_{n_i}]\\&= \textrm{det}[(x+t(N_i+n_i-1))I_{n_i}- A(K_{n_i})]\\&=(x+1+t(n_i-1+N_i))^{n_i-1}(x-(n_i-1)+t(n_i-1+N_i)). \end{aligned}\)

  1. (i)

    Then in view of Theorem 2.3 and Remark 2.2, we have

    $$\begin{aligned} \chi (A(\Gamma ^{\mathcal {R}}), x) = \chi (N(0), x)(x + 1)^{n - k}, \end{aligned}$$

    where \(N(0) = \displaystyle \begin{bmatrix} n_1-1 &{} \sqrt{n_1n_2}\rho _{12} &{} \cdots &{} \sqrt{n_1n_k}\rho _{1k}\\ \sqrt{n_1n_2}\rho _{12} &{} n_2-1 &{} \cdots &{} \sqrt{n_2n_k}\rho _{2k}\\ \; \; \vdots &{} \; \; \vdots &{} \ddots &{} \; \; \vdots \\ \sqrt{n_1n_k}\rho _{1k} &{} \sqrt{n_2n_k}\rho _{2k} &{} \cdots &{} n_k-1 \end{bmatrix}\).

  2. (ii)

    Again, from Theorem 2.3 and Remark 2.2, we have

    $$\begin{aligned}\chi (L(\Gamma ^{\mathcal {R}}), x) = (-1)^n \chi (N(1), -x) (-1)^{n-k}\prod \limits _{i = 1}^{k}(x-N_i-n_i)^{n_i-1}, \end{aligned}$$

    where \(N(1) = \displaystyle \begin{bmatrix} -N_1 &{} \sqrt{n_1n_2}\rho _{12} &{} \cdots &{} \sqrt{n_1n_k}\rho _{1k} \\ \sqrt{n_1n_2}\rho _{12} &{} - N_2 &{} \cdots &{} \sqrt{n_2n_k}\rho _{2k}\\ \; \; \vdots &{} \; \; \vdots &{} \ddots &{} \; \; \vdots \\ \sqrt{n_1n_k}\rho _{1k} &{} \sqrt{n_2n_k}\rho _{2k} &{} \cdots &{} -N_k \end{bmatrix}.\) Hence,

    $$\chi (L(\Gamma ^{\mathcal {R}}), x)=\chi (-N(1), x) \prod \limits _{i = 1}^{k} (x- N_i- n_i)^{n_i - 1}.$$

    This completes the proof.

\(\square \)

For the star graph \(K_{1,k-1}\) with vertex set \(\{v_1,v_2,\ldots ,v_k\}\) and \(k\ge 2\), we consider \(v_1\) as the central vertex, i.e. deg\((v_1)=k-1\). Then we have the following corollaries which are very useful.

Corollary 3.5

Let \(\Gamma \) be the generalized join graph \(K_{1,k-1}[K_{n_1},K_{n_2},\ldots , K_{n_k}]\) with \(n=n_1+n_2+\cdots +n_k\). Then we have the following:

  1. (i)

    The characteristic polynomial of \(A(\Gamma )\) is given by

    $$\begin{aligned}\chi (A(\Gamma ), x)= & {} (x + 1)^{n -k} \Bigg (\prod _{i = 1}^{k}(x- n_i + 1) - n_1n_2 \prod _{i = 3}^{k}(x- n_i + 1) - \cdots \\{} & {} -n_1n_l\prod _{i = 2,~ i \ne l}^{k}(x- n_i + 1) - \cdots - n_1n_k\prod _{i = 2}^{k-1}(x- n_i + 1)\Bigg ).\end{aligned}$$
  2. (ii)

    The characteristic polynomial of \(L(\Gamma )\) is given by

    $$\chi (L(\Gamma ), x) = x(x - n)(x-n_1)^{k-2}\prod \limits _{i = 1}^{k}(x- N_i- n_i)^{n_i - 1},$$

    where \( N_i = \sum \limits _{v_iv_j \in E(K_{1,k-1})}n_j\), for \(1\le i \le k.\)

Proof

  1. (i)

    Let \(A(K_{1,k-1})=[\rho _{ij}]\). Then for \(2\le j\le k\), \(\rho _{1j}= \rho _{j1}= 1\) and for \(2 \le i, j \le k,\; \; i\ne j,\) \(\rho _{ij} = 0\). By Theorem 3.4(i), we have

    $$\begin{aligned} \chi (A(\Gamma ), x) = \chi (N(0), x) (x + 1)^{n - k}, \end{aligned}$$

    where

    $$\begin{aligned}\chi (N(0), x) = \displaystyle \begin{vmatrix} x -n_1 +1&- \sqrt{n_1n_2}&- \sqrt{n_1n_3}&\cdots&- \sqrt{n_1n_k}\\ - \sqrt{n_1n_2}&x- n_2 + 1&0&\cdots&0\\ - \sqrt{n_1n_3}&0&x- n_3 + 1&\cdots&0\\ \; \; \vdots&\; \; \vdots&\; \; \vdots&\ddots&\; \; \vdots \\ - \sqrt{n_1n_k}&0&0&\cdots&x - n_{k} + 1 \end{vmatrix}.\end{aligned}$$

    Expanding the above determinant by first row and then solving the minors, we get

    $$\begin{aligned}\chi (N(0), x)= & {} \prod _{i = 1}^{k}(x- n_i + 1) - n_1n_2 \prod _{i = 3}^{k}(x- n_i + 1) - \cdots \\{} & {} -n_1n_l\prod _{i = 2,~ i \ne l}^{k}(x- n_i + 1) - \cdots - n_1n_k\prod _{i = 2}^{k-1}(x- n_i + 1).\end{aligned}$$
  2. (ii)

    We have \(N_1 = n - n_1\) and for \(2 \le i \le k\), \(N_i = n_1\). Then by Theorem 3.4,

    $$\chi (L(\Gamma ^{\mathcal {R}}), x) = \chi (-N(1), x) \prod \limits _{i = 1}^{k} (x- N_i- n_i)^{n_i - 1}$$

    where

    $$\begin{aligned}N(1) = \displaystyle \begin{bmatrix} -(|V(\Gamma )| - n_1) &{}\quad \sqrt{n_1n_2} &{}\quad \cdots &{}\quad \sqrt{n_1n_k} \\ \sqrt{n_1n_2} &{}\quad - n_1 &{}\quad \cdots &{}\quad 0\\ \; \; \vdots &{}\quad \; \; \vdots &{}\quad \ddots &{}\quad \; \; \vdots \\ \sqrt{n_1n_k} &{}\quad 0 &{}\quad \cdots &{}\quad -n_1 \end{bmatrix}.\end{aligned}$$

So, \(\chi (-N(1), x) = \displaystyle \begin{vmatrix} x -(n - n_1)&\sqrt{n_1n_2}&\sqrt{n_1n_3}&\cdots&\sqrt{n_1n_k}\\ \sqrt{n_1n_2}&x- n_1&0&\cdots&0\\ \sqrt{n_1n_3}&0&x- n_1&\cdots&0\\ \; \; \vdots&\; \; \vdots&\; \; \vdots&\ddots&\; \; \vdots \\ \sqrt{n_1n_k}&0&0&\cdots&x - n_1 \end{vmatrix} \) and by expanding the determinant as above, we get

\(\begin{aligned} \chi (-N(1), x)&= (x -n+ n_1)(x-n_1)^{k-1} \\&\quad - n_1 n_2 (x-n_1)^{k-2} - \cdots - n_1n_k(x-n_1)^{k-2}\\&= (x-n_1)^{k-2}(x -n)x. \end{aligned}\)

Thus, \(\chi (L(\Gamma ), x) = x(x -n)(x-n_1)^{k-2}\prod \limits _{i = 1}^{k}(x- N_i- n_i)^{n_i - 1}.\)

This completes the proof. \(\square \)

Corollary 3.6

Let \(\Gamma \) be the generalized join graph \(K_{1,k-1}[K_{l},K_{m},\ldots , K_{m}]\). Then

$$ \sigma (A(\Gamma )) = \displaystyle \begin{pmatrix} \frac{m+l-2-\sqrt{m^2+l^2+(4k-6)ml}}{2} &{} -1 &{} m-1 &{} \frac{m+l-2+\sqrt{m^2+l^2+(4k-6)ml}}{2}\\ 1 &{} m(k-1)+l-k &{} k-2 &{} 1 \end{pmatrix}.$$

Proof

By Corollary 3.5, we have

\(\begin{aligned} \chi (A(\Gamma ), x)&= (x + 1)^{m(k-1)+l-k} \{(x-l+1)(x-m+1)^{k-1} \\ {}&- (k-1)ml(x-m+1)^{k-2}\}\\&=(x {+} 1)^{m(k-1)+l-k}(x{-}m{+}1)^{k-2}\{(x-l+1)(x-m+1) {-} (k-1)ml\}\\&=(x + 1)^{m(k-1)+l-k}(x-m+1)^{k-2}(x-\alpha )(x-\beta ), \end{aligned}\)

where

$$\alpha {=}\frac{m+l-2{+}\sqrt{m^2+l^2{+}(4k-6)ml}}{2}\;\; \text{ and }\;\; \beta {=}\frac{m+l-2-\sqrt{m^2+l^2{+}(4k-6)ml}}{2}.$$

Hence the result follows. \(\square \)

The next section is devoted to construction of some classes of graphs which are isomorphic to star generalized join of some complete graphs.

4 Super commuting graph

Let G be a finite group with the identity element e. For \(a\in G\), by \(\langle a \rangle \) we mean the cyclic subgroup of G generated by a. The commuting graph \(\Delta (G)\) of G is a simple graph with vertex set G and two distinct vertices are adjacent whenever they commute. The commuting graph of G was introduced by Brauer and Fowler in (1955) where they have considered vertex set as \(G -\{e\}.\) Later some authors have considered \(\Delta (G)\) with vertex set \(G-Z(G)\), where Z(G) is the center of G. There are many graphs defined on G with vertex set as the whole group G. To compare different graphs defined on G and study their hierarchy, recently people have started considering commuting graph \(\Delta (G)\) with vertex set as whole G (see Cameron (2022)). So we have considered commuting graph \(\Delta (G)\) with vertex set as whole G. For more on commuting graphs on different algebraic structures, we refer to Araújo et al. (2011, 2015); Dolžan et al. (2016); Giudici and Pope (2010); Kumar et al. (2021); Shitov (2018); Woodcock (2015).

For the study of super commuting graphs on G, we consider the following two equivalence relations on G:

  1. (i)

    conjugacy relation, \((x, y) \in \mathcal {R}_c\) if and only if \(x = gyg^{-1}\) for some \(g \in G\);

  2. (ii)

    order relation, \((x, y) \in \mathcal {R}_o\) if and only if \(o(x) = o(y)\), where o(g) denotes the order of \(g\in G\).

We denote the \(\mathcal {R}_c\)-super commuting graph on G by \(\Delta ^c(G)\) and the \(\mathcal {R}_o\)-super commuting graph by \(\Delta ^o(G).\) For \(x,y\in G\), if x is conjugate to y in G then \(o(x)=o(y)\). So, \(\mathcal {R}_c \subseteq \mathcal {R}_o\) and hence by Proposition 3.1, \(\Delta ^c(G)\) is a spanning subgraph of \(\Delta ^o(G).\) The study about the graphs \(\Delta ^c(G)\) and \(\Delta ^o(G)\) is started by Arunkumar et al. in (2022) and then continued in Dalal et al. (2024). For an abelian group G of order n, \(\Delta (G)\cong K_n\) and hence \(\Delta ^c(G)=\Delta ^o(G)\cong K_n.\) So we consider nonabelian groups only. For our study, we examine the following three classes of groups:

  1. (i)

    Dihedral group: \(D_{2n} = \langle a, b : \; a^{n} = b^2 = e, \; ab = ba^{-1} \rangle , n\ge 3;\)

  2. (ii)

    Generalized quaternion group: \(Q_{4n} = \langle a, b : \; a^{2n} = e, \; b^2 = a^n, \; ab = ba^{-1} \rangle , n\ge 2;\)

  3. (iii)

    Nonabelian group of order pq(p and q are distinct primes with q|(p–1):

    $$\begin{aligned}\mathbb {Z}_p \rtimes \mathbb {Z}_q{} & {} = \langle a, b: b^p = a^q = e, aba^{-1} = b^m \; with \; m^q \equiv 1 ( \textrm{mod}~ p)\; \\ {}{} & {} \quad \quad and \; m \not \equiv 1 ( \textrm{mod}~ p)\rangle .\end{aligned}$$

The generalized quaternion group is also known as dicyclic group and the group \(\mathbb {Z}_p \rtimes \mathbb {Z}_q\) is the nontrivial semidirect product of the cyclic groups \(\mathbb {Z}_p\) and \(\mathbb {Z}_q.\) Element wise we can express the above groups as following:

  1. (i)

    \(D_{2n}=\{e\}\cup \{a^i:1\le i \le n-1\}\cup \{ba^i: 0\le i \le n-1\};\)

  2. (ii)

    \(Q_{4n}=\{e\}\cup \{a^i:1\le i \le 2n-1\}\cup \{ba^i: 0\le i \le 2n-1\};\)

  3. (iii)

    \(\mathbb {Z}_p \rtimes \mathbb {Z}_q=\{e\}\cup \{b^i:1\le i \le p-1\}\cup \{b^ia^j: 0\le i \le p-1,1\le j \le q-1 \}.\)

It is important to know the order of the elements of the above groups to study the order super commuting graph of these groups. In \(D_{2n},\) for \(0\le i \le n-1,\) we have \(o(ba^i)=2\) and \(o(a^i)=\dfrac{n}{gcd(i,n)}.\) In the group \(Q_{4n},\) \(o(ba^i)=4\) and \(o(a^i)=\dfrac{2n}{gcd(i,2n)}\) for \(0\le i\le 2n-1\). Since there is a unique Sylow p-subgroup of \(\mathbb {Z}_p \rtimes \mathbb {Z}_q\), we have \(o(b^i)=p\) for \(1\le i \le p-1\) and \(o(b^ia^j)=q\) for \(0\le i \le p-1,1\le j \le q-1.\)

4.1 Order super commuting graph

In this subsection, we will first discuss the adjacency and Laplacian spectrum of \(\Delta ^o(G),\) for \(G=D_{2n}, Q_{4n},\mathbb {Z}_p \rtimes \mathbb {Z}_q.\)

First consider \(n=2m\) for some positive integer m. In \(D_{2n}\), let \(C_1=\{ba^i: 0\le i \le n-1\}\cup \{a^m\}\) and \(C_2=\langle a \rangle -\{e,a^m\}\). The induced subgraphs of \(\Delta ^o(D_{2n})\) with vertex set \(C_1\) and \(C_2\) are complete as \(C_1\) is the order 2 equivalence class and \(C_2\) is a subset of the cyclic group \(\langle a \rangle \). As \(a^m\) is adjacent to all the elements of \(C_2\) in \(\Delta ^o(D_{2n})\) so every element of \(C_1\) is adjacent with each elements of \(C_2\). Since e is adjacent to all other vertices of \(\Delta ^o(D_{2n})\) so \(\Delta ^o(D_{2n})\cong K_{2n}\). Similarly, one can check that \(\Delta ^o(Q_{4n})\cong K_{4n}\) when n is even.

Theorem 4.1

Let \(n\ge 3\) be odd and let p and q be distinct primes with \(q|(p-1)\). Then

  1. (i)

    \(\chi (A(\Delta ^o(D_{2n})),x)=(x+1)^{2n - 3}[x^3 - x^2 (2n -3) + x (n^2 - 5n + 3) + (2n^2 - 4n + 1)].\) Furthermore, \( \sigma (A(\Delta ^o(D_{2n}))) = \displaystyle \begin{pmatrix} \alpha &{} -1 &{} \beta &{} \gamma \\ 1 &{} 2n-3 &{} 1 &{} 1 \end{pmatrix}\), where \(-2< \alpha< -1,~ n -2< \beta < n - 1\) and \(n< \gamma < n+1.\)

  2. (ii)

    \(\chi (A(\Delta ^o(Q_{4n})),x) =(x+1)^{4n - 3} [x^3 - x^2 (4n -3) + x (4n^2 - 12n + 3) + (12n^2 - 16n + 1)].\) Furthermore, \( \sigma (A(\Delta ^o(Q_{4n}))) = \displaystyle \begin{pmatrix} \alpha &{} -1 &{} \beta &{} \gamma \\ 1 &{} 4n-3 &{} 1 &{} 1 \end{pmatrix}\), where \(-3< \alpha< -2,~ 2n -3< \beta < 2n - 2\) and \(2n+1< \gamma < 2n+2\) for \(3\le n \le 13\), otherwise \(2n+2< \gamma < 2n+3.\)

  3. (iii)

    \(\chi (A(\Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q)),x)=(x+1)^{pq- 3} [x^3 - x^2(pq - 3) + x(p^2q - 3pq - p^2 + p + 3) + (2p^2q - 3pq - 2p^2 + 2p + 1)].\) Furthermore, \( \sigma (A(\Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q))) = \displaystyle \begin{pmatrix} \alpha &{} -1 &{} \beta &{} \gamma \\ 1 &{} pq-3 &{} 1 &{} 1 \end{pmatrix}\), where \(-2< \alpha< -1,~ p -2< \beta < p - 1\) and \(pq-p< \gamma < pq-p+1\).

Proof

  1. (i)

    For the group \(D_{2n},\) let \(C_1=\{ba^i: 0\le i \le n-1\}\) and \(C_2=\langle a \rangle -\{e\}\). As n is odd, so \(C_1\) is the order 2 equivalence class and hence the induced subgraph of \(\Delta ^o(D_{2n})\) with vertex set \(C_1\) is isomorphic to \(K_n\). Also the induced subgraph of \(\Delta ^o(D_{2n})\) with vertex set \(C_2\) is isomorphic to \(K_{n-1}\) as \(C_2\) is a subset of the cyclic group \(\langle a \rangle \). There is no edge between \(C_1\) and \(C_2\) in \(\Delta ^o(D_{2n})\) as no element of \(C_1\) commutes with any element of \(C_2\). Since e is adjacent with all other elements of \(D_{2n}\) so \(\Delta ^o(D_{2n})\) is isomorphic to the generalized join graph \(K_{1,2}[K_1, K_{n-1}, K_n]\). Then by Corollary 3.5(i), we get

    $$\begin{aligned}\chi (A(\Delta ^o(D_{2n})), x)= & {} (x+1)^{2n - 3} \big [x (x -n + 2)(x - n+1) -(n-1)(x- n + 1)\\ {}{} & {} \quad - n(x-n + 2)\big ] \\= & {} (x+1)^{2n - 3} \big [x^3 - x^2 (2n -3) + x (n^2 - 5n + 3) \\ {}{} & {} \quad + (2n^2 - 4n + 1)\big ].\end{aligned}$$

    By deleting the first row and first column of \(A(\Delta ^o(D_{2n}))\), we obtain a block diagonal matrix B whose two blocks are the adjacency matrices of \(K_{n-1}\) and \(K_n\), respectively. Note that the eigenvalues of the matrix B are \(\beta _1 = \beta _2 = \cdots = \beta _{2n -3} = -1, \beta _{2n-2} = n -2\) and \(\beta _{2n-1} = n -1\). Let \(\lambda _1\le \lambda _2\le \cdots \le \lambda _{2n-1}\le \lambda _{2n}\) be the eigenvalues of \(A(\Delta ^o(D_{2n}))\). Then by Interlacing theorem, we get

    $$\begin{aligned}\lambda _1 \le \lambda _2 = \lambda _3 = \cdots = \lambda _{2n - 3} = -1 \le \lambda _{2n - 2} \le n - 2 \le \lambda _{2n - 1} \le n - 1 \le \lambda _{2n}.\end{aligned}$$

    Let \(f(x)=x^3 - x^2 (2n -3) + x (n^2 - 5n + 3) + (2n^2 - 4n + 1)\). Then \(f(-1)=n^2-n>0\) and \(f(-2)=-(2n+1)<0\) as \(n\ge 3\). Since the characteristic polynomial of \(A(\Delta ^o(D_{2n}))=(x+1)^{2n-3}f(x)\), then by Intermediate value theorem we get \(\lambda _{2n - 2} = -1\) and \(-2<\lambda _1 < -1\). It can be checked that \(f(n-2)=n-1>0,f(n-1)=-n<0,f(n)=-n+1<0\) and \(f(n+1)=n+8>0\). Thus the result follows from Intermediate value theorem.

  2. (ii)

    For the group \(Q_{4n},\) let \(C_1=\{e,a^n\}, C_2=\langle a \rangle -\{e, a^n\}\) and \(C_3=\{ba^i: 0\le i \le 2n-1\}.\) As n is odd, so \(C_3\) is the order 4 equivalence class and hence the induced subgraph of \(\Delta ^o(Q_{4n})\) with vertex set \(C_3\) is isomorphic to \(K_{2n}.\) The induced subgraph of \(\Delta ^o(Q_{4n})\) with vertex set \(C_2\) is isomorphic to \(K_{2n-2}\) as \(C_2\) is a subset of the cyclic group \(\langle a \rangle \). There is no edge between \(C_2\) and \(C_3\) in \(\Delta ^o(Q_{4n})\) as no element of \(C_2\) commutes with any element of \(C_3\). Also \(a^n\) is the only element of order 2 and it commutes with all other elements of \(Q_{4n}.\) So \(\Delta ^o(Q_{4n})\) is isomorphic to the generalized join graph \(K_{1,2}[K_2, K_{2n-2}, K_{2n}]\) as e is adjacent with all other elements. Then by Corollary 3.5(i), we get

    $$\begin{aligned}\chi (A(\Delta ^o(Q_{4n})),x)= & {} (x+1)^{4n - 3} \big [(x-1)(x -2n + 3)(x - 2n+1) \\ {}{} & {} -4(n -1)(x- 2n + 1) - 4n(x-2n + 3)\big ] \\= & {} (x+1)^{4n - 3} \big [x^3 - x^2 (4n -3) + x (4n^2 - 12n + 3) \\ {}{} & {} + (12n^2 - 16n + 1)\big ].\end{aligned}$$

    By deleting the first two rows and first two columns of \(A(\Delta ^o(Q_{4n}))\), we obtain a block diagonal matrix B whose two blocks are the adjacency matrices of \(K_{2n-2}\) and \(K_{2n}\), respectively. The eigenvalues of the matrix B are \(\beta _1 = \beta _2 = \cdots = \beta _{4n -4} = -1, \beta _{4n-3} = 2n -3\) and \(\beta _{4n-2} = 2n -1\). Let \(\lambda _1\le \lambda _2\le \cdots \le \lambda _{4n-1}\le \lambda _{4n}\) be the eigenvalues of \(A(\Delta ^o(Q_{4n}))\). Then by Interlacing theorem, we get \(2n-3=\beta _{4n-3}\le \lambda _{4n-1}\) and \(2n-1= \beta _{4n-2}\le \lambda _{4n}.\) Let \(f(x)=x^3 - x^2 (4n -3) + x (4n^2 - 12n + 3) + (12n^2 - 16n + 1).\) Then \(f(-2)=4n^2-8n-1>0\) and \(f(-3)=-8(2n+1)<0\) as \(n\ge 3\). Since the characteristic polynomial of \(A(\Delta ^o(Q_{4n}))=(x+1)^{4n-3}f(x)\), then by Intermediate value theorem we get \(-3<\lambda _1 < -2\) and \(\lambda _2= \lambda _3= \cdots = \lambda _{4n-2}=-1.\) It can be checked that \(f(2n-3)=8(n-1)>0,f(2n-2)=-2n-1<0,f(2n+1)=-8n+8<0, f(2n+2)=-2n+27\) and \(f(2n+3)=8(n+8)>0.\) As \(f(2n+2)>0\) for \(3\le n\le 13\) and \(f(2n+2)<0\) for \(n\ge 15\) so the result follows from Intermediate value theorem.

  3. (iii)

    For the group \(\mathbb {Z}_p \rtimes \mathbb {Z}_q\), let \(C_2=\langle b \rangle -\{e\}\) and \(C_3=\{b^ia^j: 0\le i \le p-1,1\le j \le q-1 \}.\) Then \(C_2\) is the order p equivalence class and \(C_3\) is the order q equivalence class. Hence the induced subgraph of \(\Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\) with vertex set \(C_2\) and \(C_3\) are isomorphic to \(K_{p-1}\) and \(K_{pq-p},\) respectively. There is no edge between \(C_2\) and \(C_3\) in \(\Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\) as no element of \(C_2\) commutes with any element of \(C_3\). Since e is adjacent with all other elements of \(\mathbb {Z}_p \rtimes \mathbb {Z}_q\) so \(\Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\) is isomorphic to the generalized join graph \(K_{1,2}[K_1, K_{p-1}, K_{pq-p}]\). Then by Corollary 3.5(i), we get

    $$\begin{aligned}\chi (A(\Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q)),x)= & {} (x+1)^{pq - 3} [x (x -p + 2)(x - pq + p + 1) \\ {}{} & {} -(p - 1)(x- pq + p + 1)- (pq - p)(x- p + 2)] \\= & {} (x+1)^{pq- 3} [x^3 - x^2(pq - 3) + x(p^2q - 3pq - p^2 + p + 3) \\{} & {} + (2p^2q - 3pq - 2p^2 + 2p + 1)]. \end{aligned}$$

    The rest part of the proof is similar to the proof of (i).

\(\square \)

Theorem 4.2

Let \(n\ge 3\) be odd and let p and q be distinct primes with \(q|(p-1)\). Then

  1. (i)

    \( \sigma (L(\Delta ^o(D_{2n}))) = \displaystyle \begin{pmatrix} 0 &{} 1 &{} n &{} n+1 &{} 2n\\ 1 &{} 1 &{} n-2 &{} n-1 &{} 1 \end{pmatrix}\);

  2. (ii)

    \( \sigma (L(\Delta ^o(Q_{4n}))) = \displaystyle \begin{pmatrix} 0 &{} 2 &{} 2n &{} 2n+2 &{} 4n\\ 1 &{} 1 &{} 2n-3 &{} 2n-1 &{} 2 \end{pmatrix}\);

  3. (iii)

    \( \sigma (L(\Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q))) = \displaystyle \begin{pmatrix} 0 &{} 1 &{} p &{} pq-p+1 &{} pq\\ 1 &{} 1 &{} p-2 &{} pq-p-1 &{} 1 \end{pmatrix}\).

Proof

By the proof of Theorem 4.1, we have \(\Delta ^o(D_{2n}) \cong K_{1,2}[K_1, K_{n-1}, K_n]\), \(\Delta ^o(Q_{4n})\cong K_{1,2}[K_2, K_{2n-2}, K_{2n}]\) and \(\Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\cong K_{1,2}[K_1, K_{p-1}, K_{pq-p}]\). Then the result follows from Corollary 3.5(ii). \(\square \)

4.2 Conjugacy super commuting graph

In this subsection, our aim is to study the conjugacy super commuting graph \(\Delta ^c(G)\) , where \(G\in \{D_{2n},Q_{4n}, \mathbb {Z}_p \rtimes \mathbb {Z}_q \}.\)

Theorem 4.3

Let \(n\ge 3\) be a positive integer. Then

$$\begin{aligned} \Delta ^c (D_{2n} ) \cong \left\{ {\begin{array}{*{20}l} {K_{1,3} [K_2 ,K_{\frac{n}{2}} ,K_{\frac{n}{2}} ,K_{n - 2} ]} &{} \quad {{\text {if}}\quad n \equiv 0\;[mod~4],} \\ {K_{1,2} [K_2 ,K_{n - 2} ,K_n ]} &{} \quad {{\text {if}}\quad n \equiv 2\;[mod~4],} \\ {K_{1,2} [K_1 ,K_{n - 1} ,K_n ]} &{} \quad {{\text {if}}\quad n\;is\;odd.} \\ \end{array} } \right. \end{aligned}$$

Proof

First let \(n=2k\) with \(k\ge 2.\) Then it is known that the conjugacy classes of Dihedral group \(D_{2n}\) are

$$\begin{aligned}\{e\}, \{a^k\}, \{a^{\pm 1}\}, \{a^{\pm 2}\}, \ldots , \{a^{\pm (k-1)}\}, \{ba^{2i}: 1 \le i \le k\}, ~ \textrm{and}~ \{ba^{2i - 1}: 1 \le i \le k\}.\end{aligned}$$

Take \(C_1=\{ba^{2i}: 1 \le i \le k\}, C_2=\{ba^{2i - 1}: 1 \le i \le k\} ~ \textrm{and}~ C_3=\langle a \rangle - \{e, a^k\}.\) It can be seen that no element of \(C_3\) commute with any element of \(C_1\) or \(C_2\). Then for \(j\in \{1,2,3\}\), the induced subgraph of \(\Delta ^c(D_{2n})\) with vertex set \(C_j\) is complete. Now, one element of the form \(ba^{2i}\), for \(1\le i\le k\) and one element of the form \(ba^{2j-1}\), for \(1\le j\le k\) commute if and only if \(4i-4j+2\equiv 0\) [mod n] which is possible if and only if \(n\equiv 2\) [mod 4]. As e and \(a^k\) commute with every element of \(D_{2n}\), we can say that \(\Delta ^c(D_{2n})\cong K_{1,3}[K_2, K_{\frac{n}{2}}, K_{\frac{n}{2}}, K_{n-2}]\) if k is even and \(\Delta ^c(D_{2n})\cong K_{1,2}[K_2, K_{n-2}, K_{n}]\) if k is odd.

Let \(n = 2k + 1\) with \(k\ge 1\). Then the conjugacy classes of \(D_{2n}\) are

$$\begin{aligned}\{e\}, \{a^{\pm 1}\}, \{a^{\pm 2}\}, \ldots , \{a^{\pm k}\}, ~ \textrm{and}~ \{ba^{i}: 1 \le i \le n\}.\end{aligned}$$

Take \(C'_1=\langle a \rangle - \{ e \}\) and \(C'_2=\{ba^{i} : 1 \le i \le n\}\). Then the induced subgraphs of \(\Delta ^c(D_{2n})\) with vertex set \(C'_1\) and \(C'_2\) are complete graphs. As no element of \(C'_1\) commutes with any element of \(C'_2\), we have \(\Delta ^c(D_{2n})\cong K_{1,2}[K_1, K_{n-1}, K_n]\). \(\square \)

If n is odd then by Theorem 4.3, \(\Delta ^c(D_{2n})=\Delta ^o(D_{2n})\) and in this case the spectrum of \(\Delta ^c(D_{2n})\) are already discussed in Theorem 4.1(i). For \(n=2m \; (m\ge 2)\), we will relate \(\Delta ^c(D_{2n})\) and \(\Delta ^c(Q_{4\,m})\) in the next result.

Theorem 4.4

Let \(n\ge 2\) be a positive integer. Then

$$\begin{aligned} \Delta ^c (Q_{4n} ) \cong \left\{ {\begin{array}{*{20}l} {K_{1,3} [K_2 ,K_n ,K_n ,K_{2n - 2} ]} &{} \quad {if\quad n\;iseven,} \\ {K_{1,2} [K_2 ,K_{2n - 2} ,K_{2n} ]} &{} \quad {if\quad n\;is\;odd.} \\ \end{array} } \right. \end{aligned}$$

Proof

It is easy to verify that the conjugacy classes of \(Q_{4n}\) are

$$\begin{aligned}\{e\}, \{a^n\}, \{a^{\pm 1}\}, \{a^{\pm 2}\}, \ldots , \{a^{\pm (n-1)}\}, \{ba^{2i}: 1 \le i \le n\}, ~ \textrm{and}~ \{ba^{2i - 1}: 1 \le i \le n\}.\end{aligned}$$

Again, one element of the form \(ba^{2i}\), for \(1\le i\le n\) and one element of the form \(ba^{2j-1}\), for \(1\le j\le n\) commute if and only if \(4i-4j+2\equiv 0\) [mod 2n] which is possible if and only if \(n\equiv 1\) [mod 2]. Hence, by using a similar argument given in proof of Theorem 4.3 the result follows. \(\square \)

Note that the results of Theorems 4.3 and 4.4 are also independently obtained in Arunkumar and Cameron (2024) (see Theorems 5.3 and 5.4) and we came to know about this during the review process of this article.

By Theorems 4.3 and 4.4, for \(n=2m \;(m\ge 2)\), \(\Delta ^c(D_{2n}) \cong \Delta ^c(Q_{4m}).\) Then by Corollary 3.5, we have the following;

  • When m is even, we have

    $$\displaystyle \sigma (L(\Delta ^c(D_{4\,m})))=\sigma (L(\Delta ^c(Q_{4\,m})))=\begin{pmatrix} 0 &{} 2 &{} m+2 &{} 2\,m &{} 4\,m\\ 1 &{} 2 &{} 2\,m-2 &{} 2\,m-3 &{} 2 \end{pmatrix}$$

    and \(\chi (A(\Delta ^c(D_{4m})),x)=\chi (A(\Delta ^c(Q_{4m})),x)=(x+1)^{4m-4}(x-m+1)[x^3-(3m-3)x^2+(2m^2-10m+3)x+(10m^2-15m+1)].\)

  • When m is odd, we have

    $$\displaystyle \sigma (L(\Delta ^c(D_{4\,m})))=\sigma (L(\Delta ^c(Q_{4\,m})))=\begin{pmatrix} 0 &{} 2 &{} 2\,m &{} 2\,m+2 &{} 4\,m\\ 1 &{} 1 &{} 2\,m-3 &{} 2\,m-1 &{} 2 \end{pmatrix}$$

    and \(\chi (A(\Delta ^c(D_{4m})),x)=\chi (A(\Delta ^c(Q_{4m})),x)=(x+1)^{4m-3}[x^3-(4m-3)x^2+(4m^2-12m+3)x+(12m^2-16m+1)].\)

Theorem 4.5

Let p and q be distinct primes with \(q \mid (p-1)\). Then \(\Delta ^c(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\cong K_{1,2}[K_1, K_{p-1}, K_{pq-p}].\)

Proof

We have \(\mathbb {Z}_p \rtimes \mathbb {Z}_q = \langle a, b: b^p = a^q = e, aba^{-1} = b^m \rangle \) with \(m^q \equiv 1 ( \textrm{mod}~ p)\) and \(m \not \equiv 1 ( \textrm{mod}~ p).\) As \(ab = b^m a\), we get

$$\begin{aligned}ab^i = b^{mi} a, ~ a^i b = b^{m^i} a^i ~ \textrm{and} ~ a^{i}b^j = b^{m^ij}a^i. \end{aligned}$$

Let \(x = a^j\) for some \(1 \le j \le q-1\). Let CL(x) be the conjugacy class of x and let \(y\in CL(x).\) Then by using the above relations, we can see that y is of the below form;

$$y=b^ka^l(x)a^{-l}b^{-k} = b^ka^jb^{-k} = b^{k(1-m^j)} a^j.$$

For \(1\le j\le q-1\), let \(C_j\) denote the set \(\{b^i a^j: 0 \le i \le p-1\}\) . Then \(|C_j|=p\) and from the above calculation, it can be seen that \(CL(a^j)\subseteq C_j\). Now, for \(1\le j \le q-1\) the centralizer of \(a^j\), i.e. \(C_{\mathbb {Z}_p \rtimes \mathbb {Z}_q}(a^j)= \langle a \rangle \). Hence \(|CL(a^j)|=\dfrac{|\mathbb {Z}_p \rtimes \mathbb {Z}_q|}{|C_{\mathbb {Z}_p \rtimes \mathbb {Z}_q}(a^j)|}=p\). So, for \(1\le j \le q-1\), \(CL(a^j) =C_j.\) Now, let \(j_1,j_2\in \{1,2,\dots , q-1\}\) with \(j_1\ne j_2\). Then every element of \(C_{j_1}\) is adjacent to every element of \(C_{j_2}\) in \(\Delta ^c(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\) as \(a^{j_1}a^{j_2}=a^{j_2}a^{j_1}.\) Let \(H=C_1\cup C_2 \cup \cdots \cup C_{q-1}\). Then the induced subgraph of \(\Delta ^c(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\) with vertex set H is a complete graph on \(pq-p\) vertices. Let \(H'= \langle b \rangle -\{e\}\). Then the induced subgraph of \(\Delta ^c(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\) over the set \(H'\) is a complete graph on \(p-1\) vertices and clearly no vertex of \(H'\) is adjacent with any vertex of H. Since e is adjacent to every vertex of \(\Delta ^c(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\), we have \(\Delta ^c(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\cong K_{1,2}[K_1, K_{p-1}, K_{pq-p}].\) \(\square \)

We have \(\Delta ^c(\mathbb {Z}_p \rtimes \mathbb {Z}_q)= \Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\) and both the adjacency and Laplacian spectrum of \(\Delta ^o(\mathbb {Z}_p \rtimes \mathbb {Z}_q)\) are already discussed in Theorems 4.1 and 4.2, respectively.