ContentslistsavailableatScienceDirect
Applied Mathematics and Computation
journalhomepage:www.elsevier.com/locate/amc
Enumeration of cospectral and coinvariant graphs
Aida Abiad
a,b,c,∗, Carlos A. Alfaro
daDepartment of Mathematics and Computing Science, Eindhoven University of Technology, Eindhoven, The Netherlands
bDepartment of Mathematics: Analysis, Logic and Discrete Mathematics, Ghent University, Ghent, Belgium
cDepartment of Mathematics and Data Science, Vrije Universiteit Brussels, Brussels, Belgium
dBanco de México, Mexico City, Mexico
a rt i c l e i nf o
Article history:
Received 28 August 2020 Revised 29 April 2021 Accepted 2 May 2021
Keywords:
Graph invariant Eigenvalues Invariant factors Smith normal form Enumeration
a b s t ra c t
We present enumeration results onthe number ofconnected graphs up to10 vertices for whichthere isatleast one othergraphwiththe samespectrum (cospectral mate), orat leastone othergraphwith thesame Smith normalform(coinvariant mate)with respecttoseveralmatricesassociatedtoagraph.Thepresentednumericaldatagivesome indicationthatpossiblytheSmithnormalformofthedistanceLaplacianandthesignless distance Laplacianmatrices couldbe afiner invariant thanthespectrum todistinguish graphs. Finally, weprove agraphcharacterization usingthe Smith normal form ofthe distancesignlessLaplacianmatrix.
© 2021TheAuthor(s).PublishedbyElsevierInc.
ThisisanopenaccessarticleundertheCCBYlicense (http://creativecommons.org/licenses/by/4.0/)
1. Introduction
Spectral graph theory aims tounderstand to what extentgraphs are characterized by their spectra.Starting fromthe eigenvaluesofamatrixassociatedtoagraph,itseekstodeducecombinatorialpropertiesofthegraph.Forthis,weassociate agraphGtoamatrixMandanalyzetheeigenvalues ofM.TheseeigenvaluesarecalledthespectrumofGwithrespectto thematrixM,anditsmultisetisdenotedbyM-spectrum(G).M-cospectralgraphsaregraphsthatshareM-spectrum.Agraph GisdeterminedbyitsM-spectrum,M-DS,ifonlyisomorphicgraphsarecospectralwithG.
Motivatedbythegraphisomorphismproblem,itisofinterestwhatfractionofallgraphsisuniquelydeterminedbyits spectrum.HaemersconjecturedthatthefractionofgraphsonnverticeswithaM-cospectralmatetendstozeroasntends toinfinity.Anumericalstudyforn≤9wasgivenbyGodsilandMcKay[16],forn=10,11byHaemersandSpence[18]and forn=12by BrouwerandSpence[12].AouchicheandHansen[6]presentedcomputationalresultsinwhichtheystudied cospectrality forthe distance,distanceLaplacian anddistancesignless Laplacian matricesofall the connected graphson up to10 vertices.Recently,Pinheiro, SouzaandTrevisan [26] providedsome numericalevidencethat thecomplementary spectrum ofagraphdistinguishesmoregraphsthanother standardgraphspectra,buttheyalsoshowedthatitishardto computethecomplementaryspectrum.
The mainquestioniswhetherit ispossibletodefine amatrixMofGsuchthat everygraphbecomesM-DS.In[14]it wasshownthattheanswertothisquestionispositive.However,inthiscaseitismoreworktocheckcospectralityofthe matricesthan testingisomorphism.Iftherewouldbe aneasily computable matrixMforwhichevery graphbecomesM-
∗Corresponding author.
E-mail addresses: [email protected] (A. Abiad), [email protected] (C.A. Alfaro).
https://doi.org/10.1016/j.amc.2021.126348
0 096-30 03/© 2021 The Author(s). Published by Elsevier Inc. This is an open access article under the CC BY license ( http://creativecommons.org/licenses/by/4.0/ )
Table 1
Number of connected graphs with at least one cospectral mate for A , L , Qand D .
n 5 6 7 8 9 10
|G n| 21 112 853 11,117 261,080 11,716,571
|G spn(A )| 0 2 63 1353 46,930 2,462,141
|G spn(L )| 0 4 115 1611 40,560 1,367,215
|G spn(Q)| 2 10 80 1047 17,627 615,919
|G spn(D )| 0 0 22 658 25,058 1,389,986
DS,thegraphisomorphismproblemwouldbesolved.Hence,whenMisoneofthecommonlyusedmatricesassociatedto graphs(adjacency,Laplacian,distancematrices,signlessLaplacian,normalizedLaplacian),onecansaythatthereisnotsuch amatrixMforwhichallgraphsareM-DS,sincethereexistmanyexamplesofnon-isomorphic graphsthatsharethesame M-spectrum.Thisleavesopenthepossibilityofamplifyingorreplacingspectrawiththeuseofmorerefinedrepresentations forobtainingmorefaithfulgraphinformation.
The main goalofthis articleisto propose a newwayofrepresenting agraph usingthe Smithnormalform(SNF) of certain distance matrices. We provide some numerical evidence that this new algebraicgraph representation may do a better job in distinguishing graphs. Forthiswe first need to recall some definitions.Two matricesM,N areequivalent if thereexistunimodularmatricesPandQ withentriesinZsatisfyingM=PNQ.TheSmithnormalformofaintegermatrix M,denoted by SNF(M),isthe uniquediagonal matrixdiag(f1,...,fr,0,...,0)equivalentto Msuch thatr=rank(M)and fi
|
fjfori<j.Theinvariantfactors (orelementarydivisors)ofMaretheintegers inthediagonaloftheSNF(M).IfMisan integersymmetricmatrixassociatedtoagraph,thenwesaythatthegraphsGandHareM-coinvariantiftheSNFsofM(G) andM(H),computedoverZ,arethesame.Coinvariantgraphswereintroducedin[28].NotethatrelatedtotheSNFthere isthe p-rank,i.e.,therankofthematrixconsidered overthefinitefieldFp.Weshouldnotethatthe p-rankhasalsobeen usedintheliteraturetodistinguishgraphs;forinstance,the2-rankandthespectrumcharacterizesymplecticgraphsover F2 [24],the 2-rankcan beused todistinguishstronglyregular graphswiththesame parametersasthesymplectic graph [1],andsome p-ranksandthespectrumwereusedtocharacterizedistance-regulargraphs[25].Inparticular,inthisworkwestudyifthereisamatrixM(sayadjacency,Laplacian,signlessLaplacian,etc.)whoseSNF distinguishesmoregraphs.Broadlyspeaking,theideaistoverifywhethertheportionofgraphsthathaveaM-coinvariant mateissmallerthantheportionofgraphshavingaM-cospectralmateforaparticularmatrixM.Cospectralityandcoinvari- ancyboth playan importantroleinthe famousgraphisomorphismproblem. Whileitis unknownwhethertestinggraph isomorphismisahardproblemornot,determiningwhethertwographsarecospectralorcoinvariantcanbedoneinpoly- nomial time[20,27].Itisalsoknownthat testingcoinvariancyisexperimentallyfasterthantestingcospectrality[2].Thus, onecanfocusontestingisomorphismamongcoinvariantgraphs.
OurresultsshowthattheinvariantfactorsofthedistancesignlessLaplacianmatrixprovideawayofrepresentinggraphs whichdoesabetterjobthanthespectrumindistinguishingthem.ThedistanceLaplacianandthedistancesignlessLaplacian matriceshavereceived quitea lotofattentionover thelast years[7,8,10,15,22,23].Thisarticleisa sequelto theworkby AouchicheandHansen[6].Numericaldataonthenumberofcospectralandcoinvariantgraphsisgivenforseveralmatrices, andwealsotaketheopportunitytocorrectanearliervalue.ThispaperalsocomplementstheworkbyHaemersandSpence [18],LepovicitePLXBIB0022andGodsilandMcKay[17]onenumeratingcospectralgraphs.
In particular,we extendthecomputer enumerationforcospectral graphsof[17,18,21]and[6]to allconnected graphs onatmost10verticesthat haveatleastacospectralmatewithrespecttothedistanceLaplacianmatrixandthedistance signless Laplacianmatrix.We alsoenumerategraphswithatmost10vertices whichhaveatleastacoinvariant matefor several associated matrices. Finally, we present a novel method to show a graph characterization using the SNF of the distanceLaplaciananddistancesignlessLaplacianmatrix,illustratingthepoweroftheproposedgraphinvariant.
2. Enumeration
Since we will use severalgraph distance matrices, we focus on connected graphs such that ourenumeration results are comparable.Denote by Gn thesetof connectedgraphs withn vertices.Givena connectedgraphG,we willstudythe followingassociatedmatrices:theadjacencymatrixA(G),theLaplacianmatrixL(G),thedistancematrixD(G),thesignless LaplacianmatrixQ(G),thedistanceLaplacianmatrixDL(G)andthedistancesignlessLaplacianmatrixDQ(G).
LetGnsp(M)bethesetofgraphsinGnwhichhaveatleastonecospectralmateinGnwithrespecttothematrixM.Table1 providesthenumberofcospectralmatesofconnectedgraphswithrespecttoseveralassociatedmatrices.
Analogously, let Ginn(M)be thesetof graphsinGn which haveatleastonecoinvariant mateinGn withrespectto the matrixM.Table2showstheenumerationofGinn(M)forseveralassociatedmatrices.
Extensive researchhasbeendevotedtounderstandcospectralgraphs,butmuchlesshasbeendedicatedtounderstand coinvariant mates and its potential to characterize graphs.The reason forthis could be that for matricesA, L,Q and D, thereisalargeproportionofconnectedgraphshavingaM-coinvariantmate,asFig.1shows.Wefollow[13]indefiningthe
Table 2
Number of connected graphs with at least one coinvariant mate for A , L , Q and D .
n 4 5 6 7 8 9 10
|G n| 6 21 112 853 11,117 261,080 11,716,571
|G nin(A )| 4 20 112 853 11,117 261,080 11,716,571
|G nin(L )| 2 8 57 526 8027 221,834 11,036,261
|G nin(Q)| 2 11 78 620 7962 201,282 10,086,812
|G nin(D )| 2 15 102 835 11,080 260,991 11,716,249
Fig. 1. The fraction of graphs on n vertices that have at least one cospectral mate with respect to a certain associated matrix is denoted as sp. The fraction of graphs on n vertices with respect to a certain associated matrix that have at least one coinvariant mate is denoted as in .
Table 3
Number of connected graphs with a cospectral or a coinvariant mate for D Land D Q.
n 5 6 7 8 9 10
|G nsp(D L)| 0 0 43 745 20,455 787,851
|G nin(D L)| 0 0 18 455 16,505 642,002
|G nsp−in(D L)| 0 0 14 435 16,006 611,987
|G nsp(D Q)| 2 6 38 453 8168 319,324
|G nin(D Q)| 2 4 20 259 7444 264,955
|G nsp−in(D Q)| 2 4 20 243 6676 255,964
spectraluncertaintyspn(M)withrespecttoMastheratio
|
Gnsp(M)|
/|
Gn|
,andtheinvariantuncertaintyinn(M)withrespect toMastheratio|
Gnin(M)|
/|
Gn|
.Table 3 presentsthe number ofconnected graphs havingat leastone cospectral or atleast one coinvariantmate for DL andDQ.Here,
|
Gspn−in(M)|
denotes theamountofgraphswitha cospectralmatewhichisalsoacoinvariantmatewith respect to thecorresponding matrix M. Aouchiche andHansen [6]enumeratedcospectral graphsfor D,DL andDQ ofall connected graphs with at most10 vertices. While most of their results are consistent with ours, in Table 3 we obtain 20,455cospectralgraphswith9verticeswithrespecttoDL,whiletheyreportedthatthereare19,778ofsuchgraphs.Fig.2displaysthespectralandtheinvariant uncertaintyforDL andDQ.WealsoincludethespectraluncertaintyforQ, sinceaccordingtoTable1,thiswouldbethebestinvariant fordistinguishinggraphsusingthespectrum.Accordingtoour results,theSNFofDQ performsbetterthanthespectrum fordistinguishinggraphs forallconsidered matrices.Weshould alsonotethatthereisnosignificantimprovementwhenboththespectrumandtheSNFareusedtogether,astheparameter Gsp−inn (M)indicatesinTable3,thusthishasnotbeenaddedinFig.2.
Inthisworkwealsotestedthediscriminationpowerofthe p-rankondistinguishinggraphs.However,sincethep-rank can take values from0 to n, in general, it seems not such a good graph invariant. Thus we performedan enumeration of graphswiththesameSNF forthematricesintroduced aboveover Fp with p∈2,3,5,7.We usedthissincethe p-rank followsfromtheSNFofamatrixMoverFp,butnot viceversa.Theenumerationresultsshowedacleartendencytoclaim that,foranymatrixM∈
{
A,L,Q,D,DL,DQ}
,almostallgraphsonnverticeshaveanothergraphwiththesameSNFofMoverFp.Thus,wedecidednottoincludethesenumericalresultsonthetables.
Fig. 2. The fraction of graphs on n vertices that have at least one cospectral mate with respect to a certain associated matrix is denoted as sp. The fraction of graphs on n vertices with respect to a certain associated matrix that have at least one coinvariant mate is denoted as in .
Table 4
Number of connected graphs with a cospectral and a coinvariant mate for D Land D Q.
n 7 8 9 10
|G spn(D L, D Q)| 0 90 1965 61,909
|G inn(D L, D Q)| 0 44 1447 46,239
|G spn(D, D L)| 0 0 32 9449
|G inn(D, D L)| 0 32 1770 92,915
|G spn(D, D Q)| 0 0 0 7712
|G inn(D, D Q)| 0 20 432 24,517
|G spn(D, D L, D Q)| 0 0 0 7622
|G inn(D, D L, D Q)| 0 0 138 12,246
Fig. 3. The fraction of graphs on n vertices that have at least one cospectral mate with respect to a certain associated matrix is denoted as sp. The fraction of graphs on n vertices with respect to a certain associated matrix that have at least one coinvariant mate is denoted as in.
AouchicheandHansen[6]alsoexploredhowtoimprovethespectraluncertaintybyconsideringtwoandthreematrices together.Analogouslyasitwasdonein[6],inTable4weshowthenumberofcospectralandcoinvariantgraphswhentwo matricesare considered.LetGnsp(M,N) bethe setofgraphsinGn which haveacospectralmateinGn withrespectto the matricesM andN,andlet Gnin(M,N) be thesetofgraphs inGn whichhavea coinvariantmatein Gn withrespectto the matricesMandN.Thus,spn(M,N)=
|
Gnsp(M,N)|
/|
Gn|
andinn(M,N)=|
Gnin(M,N)|
/|
Gn|
.Fig.3showsthespectralandinvariantuncertaintyofthepairsofmatricesobtainedinTable4.Forthepair(DL,DQ),we see andadvantage inconsideringthe SNF.Butfortheother pairs,we observethatthe spectrumismuch better.There is
Table 5
|G 10sp−in(M, N)|.
M\N A L Q D D L D Q
A 2,151,957 24,021 22,764 1,113,103 9253 7688 L 521,200 1,059,992 121,708 192,455 562,943 44,398 Q 136,347 84,058 486,524 48,413 44,848 250,068 D 1,073,185 15,176 13,496 1,145,275 8935 7646 D L 300,596 563,219 52,757 110,574 611,989 47,004 D Q 65,627 44,475 245,529 28,061 46,941 255,964
Table 6
Number of connected graphs with a cospec- tral and a coinvariant mate for several matri- ces combination.
n 8 9 10
|G sp−inn (A, D L)| 0 32 9,253
|G sp−inn (D, D L)| 0 32 8,935
|G sp−inn (A, D Q)| 0 2 7,688
|G sp−inn (D, D Q)| 0 0 7,646
|G sp−sp−inn (A, D, D L)| 0 32 8,743
|G sp−sp−inn (A, D, D Q)| 0 0 7,550
|G sp−inn −in(A, D L, D Q)| 0 0 7,490
|G sp−inn −in(D, D L, D Q)| 0 0 7,510
a clearimprovementby takingthe spectrumofthedistancematrixtogetherwiththespectrumofeitherDL orDQ to the sameobtainedbytheSNF.Thiswillalsostandinthefollowinganalysis.
Let
|
Gnsp−in(M,N)|
denote the number of graphs witha cospectral mate with respect to the matrix M that is also acoinvariant matewith respectto the matrixN.In Table 5,we compute
|
G10sp−in(M,N)|
forall possiblepairs of associatedmatrices.Thelowestvaluesare
|
G10sp−in(A,DL)|
,|
G10sp−in(D,DL)|
,|
G10sp−in(A,DQ)|
and|
Gsp−in10 (A,DQ)|
.Itisinterestingtoobserve that the combinationof thespectrum ofD withthe SNF ofDQ givesbetter resultsthan usingonly the spectrumof the two matrices.Therefore,thissuggeststhatwhendistinguishing graphs,weshould computefirst theSNFoftheir distance signlessLaplacianmatricesandthenthespectrumoftheirdistancematrices.In order to improve the value obtained for
|
G10sp(D,DL,DQ)|
, we explore the use of the following parameters. Let|
Gspn−sp−in(M1,M2,M3)|
bethenumberofgraphswithacospectralmateforthematrixM1whichisalsoacospectralmatewithrespect toM2,andthat isalsoa coinvariantmatewithrespect tothematrix M3.Let
|
Gsp−inn −in(M1,M2,M3)|
be thenumberofgraphswithacospectralmateforthematrixM1 whichisalsoacoinvariantmatewithrespecttoM2,andisalso acoinvariantmatewithrespecttothematrixM3.TheresultsfromthisanalysisareshowninTable6.
From Table 6, we can see that
|
G10sp−sp−in(A,D,DQ)|
,|
G10sp−in−in(A,DL,DQ)|
and|
G10sp−in−in(D,DL,DQ)|
are better than|
Gsp10(D,DL,DQ)|
=7,622. Actually,the best performance is obtainedwith|
G10sp−in−in(A,DL,DQ)|
=7,490. Notethat the or- derincomputingeachparametermattersonlyintheabilityoftheparametertodistinguishgraphs.Tosumup,fromtheabovecomputationalresultsone canconcludethatthebestproceduretodistinguishgraphsusing the spectrumandtheSNF isfirsttocompute theSNF oftheir DQ matrices, sinceinn(DQ)hasthe bestperformance over the spectralandinvariant uncertaintyofall matrices.Then, ifnecessary,compute thespectrumoftheir A matrices,since
|
Gspn−in(A,DL)|
islowerthan|
Gnin(DL,DQ)|
forn≤10.FinallycomputetheSNFoftheDLmatrices.2.1. Coinvarianttrees
WeendupSection2withan observationoncoinvarianttrees.AouchicheandHansen[8]reportedenumerationresults oncospectraltreeswithatmost20verticeswithrespecttoD,DLandDQ.ForD,theyfoundthatamongthe123,867trees on 18 vertices,there are twopairs of D-cospectralmates. Among the 317,955 trees on19 vertices,there are sixpairs of D-cospectralmates. There are 14 pairsof D-cospectral mates overall the 823,065 trees on 20vertices. And surprisingly, aftertheenumerationofall1,346,023treesonatmost20vertices,theyfoundnoDL-cospectralmatesandnoDQ-cospectral mates.ThisfactleadAouchicheandHansentoconjecturethateverytreeisdeterminedbyitsdistanceLaplacianspectrum, andbyitsdistancesignlessLaplacianspectrum.
Analogously, forthe SNFofD,DL andDQ oftrees onecan obtainsome similar insights.Butforthat, firstwe need to state a resultby HouandWoo[19],who extendedtheGrahamandPollak celebratedformuladet(D(Tn+1))=(−1)nn2n−1 foranytreeTn+1withn+1verticestotheSNFofthedistancematrix.
Theorem1([19]). LetTn+1 beatreewithn+1vertices,thenSNF(D(Tn+1))=I22In−2(2n).
Fig. 4. A graph and its generalized distance matrix.
ThefollowingisastraightforwardconsequencefromTheorem1,sincethisimpliesthatalltreesonnverticeshavethe sameSNFofitsdistancematrixD.
Corollary2. AlltreeswithnverticesareD-coinvariantmates.
After enumeratingcoinvariant treeswith atmost20 verticeswith respectto DL andDQ, we found noDL-coinvariant mates andnoDQ-coinvariantmates amongall treeswithupto20vertices.Thisfactlead ustoconjecturethat almostall treesaredeterminedbytheSNFofitsDL,andanalogously,bytheSNFofitsDQ.
3. GraphsdeterminedbytheSNF
NotmuchisknownregardinggraphcharacterizationsusingtheSNF.AfewexamplesofgraphscharacterizedbytheSNF oftheadjacencyandtheLaplacianmatricesappearin[5]or[11].However,ourcomputationalresultsfromSection2provide anindicationthatpossiblyalmostnographhasacoinvariantmatewhenn→∞forthematricesDLandDQ.WhiletheSNF of DL has beenrecentlyusedto characterizecomplete graphsandstargraphs [2],toour knowledgethere isnot yetany graphcharacterizationresultusingtheSNFofDQ.Inthissectionwewillshowthatcompletegraphscanbedeterminedby consideringtheSNFofDQ.
Asmentionedbefore,itisknownthatcompletegraphsandstargraphsaredeterminedbytheSNFoftheDL matrix[2]. Theorem3([2]). CompletegraphsaredeterminedbytheSNFoftheDLmatrix.
Theorem4([2]). StargraphsaredeterminedbytheSNFoftheDLmatrix.
Inthissectionweshow ananalogousresulttoTheorem3,butusingtheSNFofthedistancesignlessLaplacianmatrix.
Inordertodosoweneedtodefinethedistanceidealsofagraph,whichwerefirstintroducedin[4].
LetG=(V,E)beaconnectedgraphandletXG=
{
xu :u∈V(G)}
beasetofindeterminatesassociatedwiththevertices ofG.Wedenotebydiag(XG),thediagonalmatrixwhoseentriesaretheindeterminatesinXG.Thematrixdiag(XG)+D(G)is knownasgeneralizeddistancematrixofG.FromthismatrixwecanrecoverthematricesD,DLandDQ justbyevaluatingthe indeterminatesXGatthezeroortransmissionvectors. Recallthatthetransmissiontr(u)ofavertexuisv∈VdG(u,v
),and the transmissionvectortr(G) isthevector whoseentries areassociatedwiththetransmission oftheverticesofG.Then, D(G)=D(G,0),DL(G)=−D(G,−tr(G))andDQ(G)=D(G,tr(G)).LetnbethenumberofverticesofG.Fork∈
{
1,...,n}
,thek-thdistanceideal Ik(G,XG)ofthegraphGisdefinedasthe idealgeneratedbythek-minorsofD(G,XG)inZ[XG],thatis,minorsk(D(G,XG)),whereminorsk(D(G,XG))isthesetofthe determinantsofthek×ksubmatricesofD(G,XG).AdistanceidealissaidtobeunitortrivialiftheidealisequaltoZ[XG], equivalently,theidealisgeneratedbytheunit.Example 5. LetGbe thegraphinFig. 4.Thesecond distanceideal I2(G,XG) hasasgeneratingset thefollowingGröbner basis
x0+1,x1+1,x2+1,x3+1,x4+1,3ThethirddistanceidealisgeneratedbythefollowingGröbnerbasis
x0x1−2x0−2x1+4,x0x2−2x0−2x2+4,x0x3−2x0−2x3+4, x0x4−2x0−2x4+4,3x0−6,x1x2−2x1−2x2+4,x1x3−2x1−2x3+4, x1x4−2x1−2x4+4,3x1−6,x2x3−2x2−2x3+4, x2x4−2x2−2x4+4,3x2−6,2x3x4−x3−x4−4.ThefourthdistanceidealisgeneratedbythefollowingGröbnerbasis
2x0x1x2−x0x1−x0x2−4x0−x1x2−4x1−4x2+20, x0x1x3−2x0x1−2x0x3+4x0−2x1x3+4x1+4x3−8, x0x1x4−2x0x1−2x0x4+4x0−2x1x4+4x1+4x4−8, x0x2x3−2x0x2−2x0x3+4x0−2x2x3+4x2+4x3−8,x0x2x4−2x0x2−2x0x4+4x0−2x2x4+4x2+4x4−8, 2x0x3x4−x0x3−x0x4−4x0−4x3x4+2x3+2x4+8, x1x2x3−2x1x2−2x1x3+4x1−2x2x3+4x2+4x3−8, x1x2x4−2x1x2−2x1x4+4x1−2x2x4+4x2+4x4−8, 2x1x3x4−x1x3−x1x4−4x1−4x3x4+2x3+2x4+8, 2x2x3x4−x2x3−x2x4−4x2−4x3x4+2x3+2x4+8
. ThelastdistanceidealisgeneratedbythefollowingGröbnerbasis x0x1x2x3x4−4x0x1x2−x0x1x3−x0x1x4+4x0x1−x0x2x3−x0x2x4+4x0x2−4x0x3x4+4x0x3+4x0x4−x1x2x3−x1x2x4+4x1x2−4x1x3x4
+4x1x3+4x1x4−4x2x3x4+4x2x3+4x2x4+16x3x4−12x3−12x4−16
.AnalternativewayofcomputingtheSNFofa matrixMisthefollowing.Letusdenotebyk(M),thegreatestcommon divisor ofall minorsofsize k ofthe matrixM.It isknown [2]that thek-thinvariant factorof thematrixM isequal to k(M)/k−1(M),where0(M)=1.
ThefollowingresultshowsarelationbetweentheSNFofthedistancematrixandthedistanceideals.
Proposition6([4]). Letd∈ZV(G).If f1
|
· · ·|
frarethenon-zeroinvariantfactorsoftheSNFofthematrixD(G,d),then Ik(
G,d)
= k
j=1
fj
=
k
(
D(
G,d))
for all1≤k≤r.Inthisway,distanceidealscanberegardedasageneralizationoftheSNFofthedistance,distanceLaplaciananddistance signlessLaplacianmatrices.Thus,wecanrecovertheSNFofthematricesD(G),DL(G)andDQ(G)byevaluatingthedistance idealsatXGequalto0,−tr(G)andtr(G),respectively.
Inordertoshowourmainresultofthissectionweneedthefollowingtheorem.
Theorem7([4]). LetKnbethecompletegraphwithnvertices.Thek-thdistanceidealofKnisgeneratedby
nj=1
(
xj−1)
+n i=1j =i
(
xj−1)
ifk=n,j∈I
(
xj−1)
:I⊂[n]and|
I|
=i−1 ifk<n.FromTheorem7wecanrecovertheSNFsofthedistance(D),distanceLaplacian(DL)anddistancesignlessLaplacian(DQ) matricesofthecomplete graphbyevaluating theirdistance ideals.Anevaluationatxv=0foreach
v
∈V,we obtainthat k(D(Kn))=1,fork∈[n−1],andn(D(Kn))=(−1)n+n(−1)n−1=n−1.From whichfollowsthat theSNFofD(Kn)is In−1(n−1).Byevaluatingthedistanceidealsatxv=−n+1foreachv
∈V,weobtaintheSNFofDL(Kn)is1nIn−20. And byevaluating thedistanceidealsatxv=n−1foreachv
∈V,weobtaintheSNF ofDQ(Kn)is1(n−2)In−22(n− 1)(n−2).OtherconsequenceofProposition6isthatifk-thinvariantfactorofamatrixobtainedofanevaluationofthegeneralized distancematrixofG,thenthek-thdistanceidealofGisnottrivial.Thus,foranygraphGandanyd∈ZV(G),thenumberof invariantfactorsequalto1ofthematrixD(G,d)isatleastthenumberoftrivialdistanceidealsofG.Therefore,thefamily ofgraphswithatmostktrivialdistanceidealscontainsthefamiliesofgraphswhosematricesD,DLandDQ haveatmostk invariantfactorsequalto1.WearegoingtousethispropertytoobtainacharacterizationofthegraphswhoseDQ matrices haveatleastoneinvariantfactorequalto1.Forthis,weneedthefollowingresult.
Theorem8([4]). LetGbeaconnectedgraph.GhasonlyonetrivialdistanceidealifandonlyifGiseitheracompletegraphor acompletebipartitegraph.
Therefore, tofind familyofgraphs such that their DQ matriceshave atmostone invariant factorequal to1,then we only needtoconsider thefamiliesofcompletegraphsandcomplete bipartitegraphs. Wehavealreadyseenthat theSNF ofDQ(Kn) is1(n−2)In−22(n−1)(n−2).Fromwhichfollowsthat completegraphswithatleast4 verticeshaveone invariant factor ofSNF ofDQ equal to one.Now we are going toprove that thisfamilyis containsall thegraphs whose distancesignlessLaplacianmatrixhaveonlyoneinvariantfactorequaltoone.
Theorem9. LetGbeaconnectedgraph.TheSNFofDQ(G)hasonlyoneinvariantfactorequalto1ifandonlyifGisacomplete graphwithn=3vertices.
Proof. It only remains to verifythat the second invariant factorof completebipartite graphs is equalto one. In [4], the second distanceidealof completebipartite graphs were computed. Let D(Km,n,
{
x1,...,xm,y1,...,yn}
) be thegeneralized distancematrixofKm,n,whichisequaltothefollowingmatrix diag(
x1,...,xm)
−2Im+2Jm Jm,nJn,m diag
(
y1,...,yn)
−2In+2Jn.
Ifm≥2andn=1,then
I2
(
Km,1,{
x1,...,xm,y1} )
=x1−2,...,xm−2,2y1−1.Afterevaluatingtheidealatxi=2m−1,andy1=m,weobtaintheideal
2m−3,2m−1⊆Z.Sincethegcd(2m−3,2m− 1)=1,itfollowsthatthesecondinvariantfactorofSNF(DQ(Km,1))is1.Ifm≥2andn≥2,thenI2
(
Km,n,{
x1,...,xm,y1,...,yn} )
=x1−2,...,xm−2,y1−2,...,yn−2,3.After evaluatingtheidealatxi=2m+n−2andyi=2n+m−2,weobtaintheideal
2m+n−4,m+2n−4,3⊆Z.Since thegcd(2m+n−4,m+2n−4,3)=1,itfollowsthatthesecondinvariantfactorofSNF(DQ(Km,n))is1.Nowwearereadytostatethemainresultofthissection.
Corollary10. CompletegraphsaredeterminedbytheSNFofthedistancesignlessLaplacianmatrix.
ItwouldbeinterestingtoobtainacharacterizationofgraphswhoseSNFofDL andDQ hastwoinvariantfactorsequalto 1.Thiscouldbe obtainedaftershowingacharacterizationofgraphshavingtwotrivialdistanceideals.However, thelatter problemseemstobedifficult,sincethereexistinfinitelymanyminimalinducedforbiddengraphs[3](mostofthemarethe sameneededinthecharacterizationofthewell-knownStrongPerfectGraphTheorem).
4. Concludingremarks
While theadjacency,LaplacianandsignlessLaplacianmatriceshaveattractedalotofattentioninthefield ofspectral characterizations ofgraphs,forsuchmatrices, theSNFdoesnotseemusefultodistinguish graphs,since almostallgraphs on10verticeshaveacoinvariantmate.However,ourenumerationresultssuggestthattheinvariantfactorsofthedistance LaplacianandthedistancesignlessLaplacianmatricescouldbeafinerinvarianttodistinguishgraphsincaseswhereother algebraicinvariants,suchasthosederivedfromthespectrum,fail.ThisconfirmswhatwassuggestedbyBiggs[9].Another argument to considerthe SNF asa parameter to distinguish graphs isthat this isa finer invariant than the p-rank: the p-rankisjustthenumberofinvariantfactorsnotdivisiblebyp.
In this work we show that the results by Aouchiche and Hansen [6]can be extended evenfurther. Inparticular, we providenumericalevidencethatusingtheinvariant factorsoftheSNFofcertain distancematricesonecanimprovesome oftheresultsbyAouchicheandHansen.Inthisregard,ourcomputationalresultssuggestthatpossiblyalmostnographhas acoinvariantmatewhenn→∞forthematricesDL andDQ.
Acknowledgements
TheauthorswouldliketothankWillemHaemersforacarefulreadingofthemanuscriptandforusefulcomments.The research ofA.AbiadispartiallysupportedbytheFWOgrant1285921N.Theresearch ofC.Alfaroispartiallysupportedby CONACyTandSNI.
References
[1] A. Abiad , W.H. Haemers , Switched symplectic graphs and their 2-ranks, Des. Codes Crypt. volume 81 (2016) 35–41 . [2] A. Abiad, C. A. Alfaro, K. Heysse, M. C. Vargas, Eigenvalues, smith normal form and determinantal ideals. arXiv:: 1910.12502 . [3] C.A. Alfaro , On graphs with 2 trivial distance ideals, Linear Algebra Appl. 597 (2020) 69–85 .
[4] C.A. Alfaro , L. Taylor , Distance ideals of graphs, Linear Algebra Appl. 584 (2020) 127–144 .
[5] C.A. Alfaro , C.E. Valencia , On the sandpile group of the cone of a graph, Linear Algebra Appl. 436 (2012) 1154–1176 . [6] M. Aouchiche , P. Hansen , Cospectrality of graphs with respect to distance matrices, Appl. Math. Comput. 325 (2018) 309–321 . [7] M. Aouchiche , P. Hansen , Some properties of the distance laplacian eigenvalues of a graph, Czech. Math. J. 64 (2014) 751–761 . [8] M. Aouchiche , P. Hansen , Two laplacians for the distance matrix of a graph, Linear Algebra Appl. 439 (2013) 21–33 . [9] N. Biggs , Chip-firing and the critical group of a graph, J. Alg. Combin. 9 (1999) 25–46 .
[10] B. Brimkov , K. Duna , L. Hogben , K. Lorenzen , C. Reinhart , S.Y. Song , M. Yarrow , Graphs that are cospectral for the distance laplacian, The Electronic Journal of Linear Algebra 36 (2020) .
[11] A.E. Brouwer , W.H. Haemers , Spectra of graphs, Universitext, Springer, 2012 .
[12] A.E. Brouwer , E. Spence , Cospectral graphs on 12 vertices, Electron. J. Combin. 16 (2009) .
[13] D. Cvetkovi ´c , P. Rowlinson , S.K. Simi ´c , Signless laplacians of finite graphs, Linear Algebra Appl. 423 (2007) 155–171 . [14] E.R. van Dam , W.H. Haemers , Which graphs are determined by their spectrum? Linear Algebra Appl. 373 (2003) 241–272 .
[15] K.C. Das , M. Aouchiche , P. Hansen , On distance laplacian and distance signless laplacian eigenvalues of graphs, Linear and Multilinear Algebra (2018) 1–18 .
[16] C. Godsil , B.D.M. Kay , Some Computational Results on the Spectra of Graphs, in: Combinatorial Mathematics IV, in: LNM, volume vol. 560, Springer, 1976, pp. 73–92 .
[17] C.D. Godsil , B.D.M. Kay , Constructing cospectral graphs, Aequationes Math. 25 (1982) 257–268 .
[18] W.H. Haemers , E. Spence , Enumeration of cospectral graphs, European Journal of Combinatorics 25 (2004) 199–211 . [19] Y. Hou , C. Woo , Distance unimodular equivalence of graphs, Linear and Multilinear Algebra 56 (2008) 611–626 .
[20] R. Kannan , A. Bachem , Polynomial algorithms for computing the smith and hermite normal forms of an integer matrix, SIAM J. Comput. 8 (1979) 499–507 .
[21] M. Lepovi ´c , Some statistical data on graphs with 10 vertices, Univ. Beograd. Publ. Elektrotehn. Fak. Ser. Mat. 9 (1998) 79–88 . [22] K. Lorenzen, Cospectral constructions for several graph matrices using cousin vertices, arXiv: 2002.08248
[23] M. Nath , S. Paul , On the distance laplacian spectra of graphs, Linear Algebra Appl. 460 (2014) 97–110 .
[24] M.J.P. Peeters , Uniqueness of strongly regular graphs having minimal p-rank, Linear Algebra Appl. 226–228 (1995) 9–31 .
[25] M.J.P. Peeters , On the p-ranks of the adjacency matrices of distance-regular graphs, Journal of Algebraic Combinatorics 15 (2002) 127–149 .
[26] L.K. Pinheiro , B.S. Souza , V. Trevisan , Determining graphs by the complementary spectrum, Discussiones Mathematicae Graph Theory 40 (2) (2020) 607–620 .
[27] A. Storjohann , A Solution to the Extended GCD Problem with Applications, in: Proceedings of the 1997 International Symposium on Symbolic and Algebraic Computation (Kihei, HI), pages 109–116 (electronic), New York, ACM, 1997 .
[28] A. Vince , Elementary divisors of graphs and matroids, Europ. J. Combinatorics 12 (1991) 445–453 .