Approach to solve Query Operation on Data Structure used for Building Dynamic DFS in Undirected Graphs which is created using Segment Tree and Binary Search Tree
9. DFS Tree
x
u
v
z
y
w
s t
x z w s t y u v List L
x z w s t y u v
(x,s) (z,w) (w,s) (s,w) (t,w)
(z,t) (w,t)
Segment Tree TB
10. x z w s t y u v
Segment Tree TB
[w-s]
(s,w)
(t,w)(w,s)
(z,w)
(x,s)
BST stored at segment tree node [w-s]
(x,s) (z,w) (w,s) (s,w) (t,w)
Edge-list sorted according to List L
x z w s t y u v List L