I'm working on an exercise for an advanced statistical physics course. The question I'm struggling with is this:
$$TdS=dE+PdV-\mu dN\tag{1}$$
Write the first law $(1)$ as $dS=....$ Applying the exterior differential $d$ to the resulting equation and using $d(dS)=0$, derive the relation
$$\frac{\partial T}{\partial V}\Bigg|_{E,N}-P\frac{\partial T}{\partial E}\Bigg|_{V,N}+T\frac{\partial P}{\partial E}\Bigg|_{V,N}=0\tag{3}$$
(Hint: Keep in mind that $dEdV=-dVdE$.)
So I've written down the first law of thermodynamics of the form $S(E,V,N)$ in terms of dS: $$dS=\frac{1}{T}dE+\frac{P}{T}dV-\frac{\mu}{T}dN$$ I can also write dS in terms of its partial derivatives: $$dS=\frac{\partial S}{\partial E}dE+\frac{\partial S}{\partial V}dV+\frac{\partial S}{\partial N}dN$$
Now I'm being asked to apply the exterior differential, to calculate $d(dS)$, and then use $d(dS)=0$ to prove the statement from the exercise.
I thought I needed to calculate the exterior differential as follows: $$ d(dS)=\frac{-1}{T^2}dTdE+\frac{1}{T}d(dE)-\frac{P}{T^2}dTdV+\frac{1}{T}dPdV+\frac{P}{T}d(dV)-\frac{1}{T}d\mu dN+\frac{\mu}{T^2}dTdN-\frac{\mu}{T}d(dN) $$
where I would then use that $d(dE)=d(dV)=d(dN)=0$ to eliminate those terms. But then I'm stuck. Nothing seems to get me to the required equation. Could anyone point me in the right direction?
edit: thanks to the hint from Michael Albanese i've made some progress.
I've written $dT$ in terms of $dE,dV,dN$ which gives me:
$$ dT=\frac{1}{S}dE+\frac{P}{S}dV-\frac{\mu}{S}dN $$ and $$ dT=\frac{\partial T}{\partial E}dE+\frac{\partial T}{\partial V}dV+\frac{\partial T}{\partial N}dN $$
So that i now have that $\frac{\partial T}{\partial V}=\frac{P}{S}$ and $\frac{\partial T}{\partial E}=\frac{1}{S}$.
Then I tried writing $dP$ in terms of $dE,dV,dN$ and I'm getting stuck again.
I started with
$$ P = \frac{TS+\mu N-E}{V} $$
and then took the derivative:
$$ dP = \frac{1-\mu -TS}{V^2}dV+\frac{\mu}{V}dN-\frac{1}{V}dE $$ along with $$ dP = \frac{\partial P}{\partial V}dV+\frac{\partial P}{\partial N}dN+\frac{\partial P}{\partial E}dE $$
to give me $\frac{\partial P}{\partial E}=-\frac{1}{V}$
Now the equation that i'm supposed to derive turns into:
$$ \frac{P}{S}-P*\frac{1}{S}+T*\frac{-1}{V} \neq 0 $$
am i missing a very obvious step? I also haven't figured out how to use $d(dS)$ up until this point...
If a 1-form has the expression $\omega =\sum_i \alpha_i d x_i$, then the expression of its exterior derivative is \begin{equation} d\omega =\sum_i\sum_j \frac{\partial \alpha_i}{\partial x_j} d x_j\wedge d x_i \end{equation} Use this with $E, V, N$ as the $x_i$'s and $d S$ as $\omega$ (which implies that $d\omega = d(dS) = 0$).