3 ms·
I think, that they presented on Internet as a soup of pointers, because it is the obvious and general way to do it. Other ways like connectivity matrix are less
by ordu 4y ago
I think, that they presented on Internet as a soup of pointers, because it is the obvious and general way to do it. Other ways like connectivity matrix are less general: if you have a lot of nodes, and by several orders of magnitude less then N^2 edges, then the most of matrix elements will be empty. Moreover it is not obvious way, you need to explain it also on top of your goal to explain what you are explaining about geometry/topology. So if you tried to do it you'd spend all the allotted time talking about pros and cons of different representations of topology.
I believe that if someone tried to talk about topology while using Rust as a language for sample code, he/she would use some other representation, because a soup of pointers is a PITA in Rust. It is easier to claim that we will be using a connectivity matrix, or a Vec of edges, and to explain how it works, than to juggle with pointers.