let's call LCT graph, splay tree. to avoid ambiguity
every prefered path(component, real edge, heavy path) is a splay tree by depth.(aka, in-order the splay tree, sorted by depth in graph). let's call it S. since it's a splay tree.
how each S. connected? by S's root -> S's smallest depth(in graph)(left-most in-order in tree)'s parent. called path parent pointer(ppp).
for short memorization, LCT definition
by store information in this way, allow us to do dynamic operation.
first, key part
well, access actually does is making the path from graph's root to v be prefered.
by loop up S. splay(x), make their ppp real, till the graph's root. (this key short explantion, and rembember LCT'def)
in the end, we can splay(v) or not, depends.
link the two graph. there is option, the link could be prefered or not(light).
separate to two graph.
hint. keep in mind what access does.
In [ ]: