# What will be the transformation and Jacobian of transformation for the following case

#### Jesmin

##### New Member
Let $$X_i\sim N(\mu_i,\sigma^2)$$ ; where $$[i=1,2,\ldots,n]$$
show that $$\bar X$$ and $$(X_i-\bar X)$$ are independent.
If all $$X_i$$ had same mean $$\mu$$ then we transform the random variables $$X_i$$; $$[i=1,2,\ldots,n]$$ to

$$Y_1=\bar X$$
$$Y_2 =X_2-\bar X$$
$$Y_3 = X_3-\bar X$$
$$\vdots$$
$$Y_n = X_n-\bar X$$

and the Jacobian of the transformation can be shown to not depend on $$X_i$$ or $$\bar X$$ and is equal to the constant $$n$$.(Honestly, I don’t know how do they understand that we need to consider $$Y_1=\bar X$$ in lieu of $$Y_1= X_1-\bar X$$ and how to compute this Jacobian of the transformation )

But for the above case each $$X_i$$ has different mean $$\mu_i$$.
What will be the transformation and Jacobian of transformation here?

#### BGM

##### TS Contributor
Re: What will be the transformation and Jacobian of transformation for the following

Note that by independence, we have

$$\begin{bmatrix} X_1 \\ X_2 \\ \vdots \\ X_n \end{bmatrix} \sim \mathcal{N}\left(\begin{bmatrix} \mu_1 \\ \mu_2 \\ \vdots \\ \mu_n \end{bmatrix}, \begin{bmatrix} \sigma^2 & 0 & \ldots & 0 \\ 0 & \sigma^2 & \ldots & 0 \\ \vdots & \vdots & \ddots & \vdots \\ 0 & 0 & \ldots & \sigma^2 \end{bmatrix} \right)$$

Since they jointly follows a multivariate normal, any affine transformation will also follows a multivariate normal. Note that

$$\begin{bmatrix} \bar{X} \\ X_i - \bar{X} \end{bmatrix} = \begin{bmatrix} \frac {1} {n} & \ldots & \frac {1} {n} & \ldots & \frac {1} {n}\\ -\frac {1} {n} & \ldots & 1 - \frac {1} {n} & \ldots & -\frac {1} {n} \end{bmatrix} \begin{bmatrix} X_1 \\ \vdots \\ X_i \\ \vdots \\ X_n \end{bmatrix}$$

And for any pair of random variables jointly follows a bivariate normal, they are independent if and only if they are uncorrelated. So you merely need to check whether

$$Cov[\bar{X}, X_i - \bar{X}] = 0$$

For your second part, note the Jacobian is purely dependent on the transformation only. So as long as the transformation is the same, the corresponding Jacobian is the same, no matter what the underlying distribution is. And this part should be aid to help you to obtain another result, but not required for the first part.