#hhkb2020f. [hhkb2020_f]Random Max

[hhkb2020_f]Random Max

$$(n + 1)! \times \int_{L_1}^{R_1} \int_{L_2}^{R_2} \dots \int_{L_n}^{R_n} \max(X_1, X_2, \dots, X_n) dX_n dX_{n-1} \dots dX_1 \bmod (10^9+7) $$

具象化地说,设随机变量 X1,X2,,XnX_1, X_2, \dots, X_n 分别在区间 [L1,R1],[L2,R2],,[Ln,Rn][L_1, R_1], [L_2, R_2], \dots, [L_n, R_n] 上均匀分布,求 max(X1,X2,,Xn)\max(X_1, X_2, \dots, X_n) 的期望值乘上 $(n + 1)! \times \prod_{i=1}^n \left (R_i - L_i \right)$ 对 109+710^9+7 取模的值。