# Grand canonical ensemble $d\ln(\mathcal{Z})$

Let us consider the grand canonical ensemble. Where here we have the grand partition function: $$\mathcal{Z}=\text{tr}(e^{\beta(\mu N -H)})$$ Where $$\mu$$ is the chemical potential and $$\beta =\dfrac{1}{kT}$$.

I am reading some calculations, and am unsure how a step was completed: $$d\text{ln}(\mathcal{Z})=\mathcal{Z}^{-1}d\mathcal{Z}=\mathcal{Z}^{-1}d\text{tr}(\text{tr}(e^{\beta(\mu N -H)}))$$ Which apparently equals: $$(\mu \bar{N}-\bar{E})d\beta+\beta\bar{N}d\mu.$$ How is this so?

• $\mathcal{Z}(\beta,\mu)$ can be regarder as a function of $\beta$ and $\mu$. Just make $d\ln\mathcal{Z}$ over these variables. BTW $\bar{X} = \text{Tr}(X e^{\beta(\mu N-H)})$. Oct 30, 2017 at 19:47

I'm not sure I understand what you wrote, but here's my answer. If $\cal{Z}$ is the classical GC partition function, then it is defined as $${\cal{Z}}=\sum_i e^{\beta(\mu N_i - H_i)}\equiv tr(e^{\beta(\mu N - H)})$$ where the sum if over the microstates of the system. Thus, since in principle $\mu=\mu(\beta)$, the derivative with respect to $\beta$ of its logarithm: $$\frac{d}{d\beta}\ln{\cal{Z}}=\frac{1}{\cal{Z}}\frac{d}{d\beta}{\cal{Z}}$$ which is just a property of logarithms. Therefore $$\frac{1}{\cal{Z}}\frac{d}{d\beta}\sum_i e^{\beta(\mu N_i - H_i)}= \frac{1}{\cal{Z}}\sum_i \big(\mu N_i - H_i + \beta N_i \frac{d\mu}{d\beta}\big)e^{\beta(\mu N_i - H_i)}=\mu\langle N \rangle - \langle H\rangle + \beta\langle N\rangle \frac{d\mu}{d\beta}$$ where the last equality comes from the definition of the expected value in the GC ensemble: $$\langle A\rangle_{GC}=\frac{1}{\cal{Z}}\sum_i A_i e^{\beta(\mu N_i - H_i)}$$