Since $dA=-SdT-PdV$ to $T=cte$ gives us $P=-\left(\frac{\partial{A}}{\partial{V}}\right)_{T=cte}$

Differentiating the equation $A=-NkTlnq$ with respect to volume and substituting into P gives:

\begin{equation}P=NkT\left(\frac{\partial{lnq}}{\partial{V}}\right)_T=cte}\label{ec38}\end{equation}