Sorry Yggdrasil, I'm confused again. Here is the actual statement of the question: Develop a program to calculate the reversible work per unit mass to compress benzene (not ideal) in an isothermal steady flow process. Consider a temp of 600 K and an initial p = critical p. The compressibility factor Z, at this temp, as a function of the reduced pressure pr is given by Z = A0 + A1(pr) + A2(pr)2 +A3(pr)3...to A5(pr)5. If the reversible work/kg is given by w_rev = - int(vdp), calculate w_rev for final reduced pressures = 1.5, 2.0, 2.5...5.0.
What you told me before seemed very logical, but when I tried to apply the idea, I got confused. Z = Pv/RT or (pr)(vr')/(Tr) with pr = p/pc, pc = critical p, Tr = T/Tc, Tc = critical T. After I made pr in terms of vr', I don't know where to go from there. Since w_rev = - int(vdp), my v could be made in terms of pr, but can I integrate pr with respect to dp? or should I calculate pr in terms of p/pc? Also, I don't know what to do with the Tr afterwards. I don't think I can take it out of the integral since it isn't a constant.