Ask Your Question
1

Generalized sierpinski graph construction

asked 2022-05-13 07:50:04 +0100

vidyarthi gravatar image

updated 2023-01-10 00:01:05 +0100

tmonteil gravatar image

How do we construct the generalised sierpinski graph $S[n,k]$ which has order $nk$ and size $\frac{(k+1)n(n-1)}{2}$ in SageMath. The graphs.SierpinskiGasketGraph is just the graph $S[3,k]$. But I want to generalise this. Is there any direct command available? Thanks beforehand.

edit retag flag offensive close merge delete

2 Answers

Sort by » oldest newest most voted
1

answered 2022-05-15 16:06:51 +0100

See https://trac.sagemath.org/ticket/33854. This is the generalized Sierpinski graphs generator as proposed in [1]. To get a Sierpinski graph, it suffices to call the generator with a clique.

Note that the Sierpinski-Gasket graphs are not isomorphic to Sierpinski graphs. The construction is different.


[1] Sylvain Gravier, Matjaz Kovse and Aline Parreau. Generalized Sierpinski graphs. Poster, European Conference on Combinatorics, Graph Theory and Applications (EuroComb’11), Budapest, 2011. https://www.renyi.hu/conferences/ec11...

edit flag offensive delete link more

Comments

How do we call the function, like is it graphs.GeneralizedSierpinskiGraph or should we do from sage.graphs.GeneralizedSierpinskiGraphs import GneralizedSierpinskiGraph?

vidyarthi gravatar imagevidyarthi ( 2022-05-30 12:15:57 +0100 )edit
1

answered 2022-05-13 09:49:49 +0100

tmonteil gravatar image

The documentation of graphs.SierpinskiGasketGraph, which you can get with:

sage: graphs.SierpinskiGasketGraph?

tells that some generalization with two parameters can be found as graphs.HanoiTowerGraph.

If it is not what you are looking for, you can get the source code for the construction of (ungeneralized) Sierpinski gasket graphs, and try to generalize it with:

sage: graphs.SierpinskiGasketGraph??
edit flag offensive delete link more

Comments

Thanks!, I saw the source code, but I am afraid it looks complicated. I just dont understand how to scale it for any graph. From here,( preliminary portion), I must label the vertices in a certain way. Is that possible. And, moreover, when I define a function that uses graph as a parameter, I dont get the required base graph.

vidyarthi gravatar imagevidyarthi ( 2022-05-13 20:02:04 +0100 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2022-05-13 07:50:04 +0100

Seen: 284 times

Last updated: May 15 '22