Internal pressure of ideal gas
In fact, you need to use two of the fundamental relations.

For an ideal gas, the internal energy $U$ can be considered to be a function of $V$ and $T$. So, the total differential of $U$ would read

$$\mathrm{d}U = \left(\frac{\partial U}{\partial V}\right)_{\!T}\,\mathrm{d}V + \left(\frac{\partial U}{\partial T}\right)_{\!V}\,\mathrm{d}T \tag{1}$$

The first partial derivative is the internal pressure, which we are trying to determine.

The other thing that we know is that (assuming only expansion work and no net reaction)

$$\mathrm{d}U = T\,\mathrm{d}S - p\,\mathrm{d}V \tag{2}$$

The idea here is that we want to change the term involving $\mathrm{d}S$ into a combination of $\mathrm{d}T$ and $\mathrm{d}V$, so that we can compare coefficients with equation $(1)$. So, we just express $S$ as a function of $T$ and $V$:

$$\mathrm{d}S = \left(\frac{\partial S}{\partial V}\right)_{\!T}\,\mathrm{d}V + \left(\frac{\partial S}{\partial T}\right)_{\!V}\,\mathrm{d}T \tag{3}$$

Substituting $(3)$ into $(2)$

$$\begin{align}
\mathrm{d}U &amp;= T\left[\left(\frac{\partial S}{\partial V}\right)_{\!T}\,\mathrm{d}V + \left(\frac{\partial S}{\partial T}\right)_{\!V}\,\mathrm{d}T\right] - p\,\mathrm{d}V \tag{4} \\
&amp;= \left[T\left(\frac{\partial S}{\partial V}\right)_{\!T} - p\right]\mathrm{d}V + \left[T\left(\frac{\partial S}{\partial T}\right)_{\!V}\right]\mathrm{d}T \tag{5}
\end{align}$$

Comparing the coefficient of the $\mathrm{d}V$ term with $(1)$ we find that1

$$\left(\frac{\partial U}{\partial V}\right)_{\!T} = T\left(\frac{\partial S}{\partial V}\right)_{\!T} - p \tag{6}$$

Equation $(6)$ is entirely general and applies to all substances, not just ideal gases. Now, we turn to the Helmholtz free energy:

$$\mathrm{d}A = -S\,\mathrm{d}T - p\,\mathrm{d}V \tag{7}$$

From this we obtain the Maxwell relation

$$\left(\frac{\partial S}{\partial V}\right)_{\!T} = \left(\frac{\partial p}{\partial T}\right)_{\!V} \tag{8}$$

For an ideal gas $p = nRT/V$, so

$$\left(\frac{\partial p}{\partial T}\right)_{\!V} = \frac{nR}{V} \tag{9}$$

Finally, substituting $(8)$ and $(9)$ into $(6)$ gives

$$\begin{align}
\left(\frac{\partial U}{\partial V}\right)_{\!T} &amp;= T\left(\frac{nR}{V}\right) - p \tag{10} \\
&amp;= \frac{nRT}{V} - p \tag{11} \\
&amp;= p - p \tag{12} \\
&amp;= 0 \tag{13}
\end{align}$$

as desired.



Notes

1 Some texts may write that you can obtain $(6)$ from $(2)$ simply by "dividing" by $\mathrm{d}V$ and imposing conditions of constant temperature:

$$\begin{align}
\mathrm{d}U &amp;= T\,\mathrm{d}S - p\,\mathrm{d}V &amp; &amp; \tag{2} \\
\frac{\mathrm{d}U}{\mathrm{d}V} &amp;= T\frac{\mathrm{d}S}{\mathrm{d}V} - p\frac{\mathrm{d}V}{\mathrm{d}V} &amp; &amp;\text{(dividing by }\mathrm{d}V\text{)} \tag{14} \\
\left(\frac{\partial U}{\partial V}\right)_{\!T} &amp;= T\left(\frac{\partial S}{\partial V}\right)_{\!T} - p\left(\frac{\partial V}{\partial V}\right)_{\!T} &amp; &amp;\text{(constant }T\text{)} \tag{15} \\
&amp;= T\left(\frac{\partial S}{\partial V}\right)_{\!T} - p &amp; &amp;\text{(derivative of }V\text{ with respect to itself is }1\text{)} \tag{6}
\end{align}$$

This gives the correct result, and in general this "shortcut" works, but it is mathematically not rigorous.