Only with geometry checks are you close to optimal.
You need 4 comparisons (in 2d) to determine which, if any, the boundary pair is adjacent. If adjacency is detected, you need to detect the presence or absence of 2d overlap. You do this with two inclusion checks using <= and> =. You will not do much better. If true answers are more likely than false, it may be worth checking first whether one endpoint is strictly contained in another edge. If all of these tests fail, the logic must pass before the final verification of identical edges. (This additional check makes the method more expensive if false answers are common.)
Efficiency is available if you add βdepthβ to each node. This will quickly tell you which cell is larger or if they are the same size, which allows you to do only one of two inclusion checks. A single depth comparison avoids several comparisons with the coordinates of the edge.
Finally, if you put parent pointers in nodes, you can do this comparison by looking for paths to the least common ancestor. You can check these paths to get an answer. However, since it is unlikely that finding and testing them will be faster than the numerical comparison that you already have, I will not go into this.
source share