$$\int{\exp((x_2-x_1)^2+k_1x_1+k_2x_2)dx_1dx_2}$$
I can perform the integration of the integral above easily by changing the variable \begin{align} u&=x_2+x_1\\ v&=x_2-x_1 \end{align} Of course first computing the Jacobian, and integrating over $u$ and $v$
I am wondering how you perform the change of variable for 4-dimensional integral like below:
$$\int{\exp\left(\sum_{i=1}^{4}((x_{i}-x_{i-1})^2+k_ix_i)\right)dx_1dx_2dx_3dx_4}$$
Is it something like: \begin{align} x_2-x_1&=u \\ x_2+x_1&=v \\ x_4-x_3&=p \\ x_4+x_3&=q \end{align} Should this be enough? I think one only needs 4 new variables right? Because I was thinking the integral would be easier if I could do something like: \begin{align} x_2-x_1&=u \\ x_3-x_2&=v \\ x_4-x_3&=p \\ x_1-x_4&=q \end{align} Or in general, how do you perform change of variable in multi-dimensional case. Should you generally perform it by doing:
\begin{align} u&=a_1x_1+a_2x_2+a_3x_3+a_4x_4 \\ v&=b_1x_1+b_2x_2+b_3x_3+b_4x_4 \\ p&=c_1x_1+c_2x_2+c_3x_3+c_4x_4 \\ q&=d_1x_1+d_2x_2+d_3x_3+d_4x_4 \end{align}
And what kind of change of variable does one need to perform to perform the integration of such integration easily?