First input is T, a Triplet list of indices -whom each row actually contains the three indices of a triangle vertices-. size(T) = [nb_triangles, 3]. Second input is e = [e1, e2], a row vector, couple of indices. Output S is the triplet list of indices which Share the edge e. For instance, if
e = [2, 4]
and T a tetrahedron
T = [1, 2, 3;... 1, 3, 4;... 1, 2, 4;... 2, 3, 4]
then the output of the function is
S = [1, 2, 4;... 2, 3, 4]
since both triangles [1, 2, 4] and [2, 3, 4] contain the edge [2, 4].
Conditions :
Info : T is actually a triangulation -list of triangles-, in which each index corresponding to the row index of a vertex in another list -a vertices list-, it is a widely used technique used to store and write triangular meshes in mesh processing. Here below the example is a tetrahedron -4 facets-.
I actually realize this problem looks like a lot to my second problem, "Find a common edge" ( https://fr.mathworks.com/matlabcentral/cody/problems/45218-find-a-common-edge ) ...
Back to basics 23 - Triangular matrix
635 Solvers
Getting the indices from a vector
2065 Solvers
Given a window, how many subsets of a vector sum positive
885 Solvers
1005 Solvers
19 Solvers