In the world of $\textit{The Three-Body Problem}$, about 200 years later, people will live in huge underground tree buildings. In this problem, we use the tree data structure to describe tree buildings.
There is a tree with $n$ nodes and $n - 1$ edges with length, and $n$ of your friends live in the tree, one at each node. You are planning to visit your friends in the next $m$ days. Each day you choose an interval $[l, r]$ and plan to visit friends living in the nodes numbered from $l$ to $r$. You can choose an arbitrary node $u$ to start the day's visit, then travel on the tree along the edges, and finally go back to $u$. During the travel, you should visit all your friends living in the nodes numbered from $l$ to $r$. You can visit these friends $\textbf{in any order}$ and you can pass a node without visiting the friend. Please calculate the minimum total distance of the travel for each day.