jeanbellynck / Cayley-Graph-Generator

Graphicayley (formerly Cayley Graph Generator) is an Unity Application to convert group presentations into pretty Cayley Graphs.
https://jeanbellynck.github.io/graphicayley.html
MIT License
1 stars 0 forks source link

Do the maths (checking for reduction of words) and physics (moving vertices) in background #95

Open p4jo opened 8 months ago

p4jo commented 8 months ago

This expands upon my original issue, #16.

My idea is to do the graph manipulations on an abstract graph (labeled, positioned, but not drawn immediately) and let the drawn graph follow this path smoothly and draw only a ball with ever growing radius which is proportional to, but smaller than, the current radius of generation. (this can actually be done on the same graph just making the game objects not follow the abstract position immediately and making them visible only later) This should reduce all kinds of spasms. I actually imagine it looking like we just turn on a light with growing radius in an existing graph. (which might be actually true if #94 is implemented). I know this is in opposition to #23.

p4jo commented 8 months ago

I actually want to be able to run more iterations of the physics for new vertices, before they're shown.

(Even before that, I want to know to a reasonable ceratinty that they're not going to be merged)

Currently there's lots of spasms at the very beginning (at least with small groups)

jeanbellynck commented 7 months ago

Having a radius of generatiion and a radius of drawing is actually a nice compromise I didn't think of. The distance of a vertex can be calculated from its paths to the identity so this shouldn't be too hard to implement. Just don't draw anything under a certain radius and increase the draw radius gradually I definitely want to keep the aesthetic that the graph is being visually build. Your idea still allows this building process to be seen.

The above already reduces spasms at the beginning. I don't think an additional smooth following of vertices would be necessary.

The word problem tells us that it is not possible to know whether to group elements are the same. Therefore it is not possible to know whether two elements will be merged or not. I think the above suffices.