Rhason Cheung had a naive problem, and asked Teacher Mai for help. But Teacher Mai thought this problem was too simple, sometimes naive. So she ask you for help.
She has a tree with $n$ vertices, numbered from $1$ to $n$. The weight of $i$-th node is $w_i$.
You need to support two kinds of operations: modification and query.
For a modification operation $u,w$, you need to change the weight of $u$-th node into $w$.
For a query operation $u,v$, you should output $\sum_{i=1}^n \sum_{j=1}^n f(i,j)$. If there is a vertex on the path from $u$ to $v$ and the path from $i$ to $j$ in the tree, $f(i,j)=w_iw_j$, otherwise $f(i,j)=0$. The number can be large, so print the number modulo $10^9+7$