How to rearrange equation to cubic polynomial form?

100 Views Asked by At

Summarize the problem

I have these 2 equations and i need a cubic polynomial in terms of Z so i can run numerical routines on it. How can i be sure that's possible to factor that way and second how can i do it?

For this particular case i know the answer but i don't know how to get there. $$ P=\frac{R*T}{v-b}-\frac{a}{v²} (1) $$

$$ v=\frac{Z*R*T}{P} (2) $$

Provide details and any research

So i Plug (2) into (1). and my goal is to arrive at (az³+bz²+cz+d=0). I know the solution in this case to be

$$ 0 = z³-(\frac{bP}{RT}+1)z²+(\frac{aP}{(RT)²})z-\frac{abP²}{(RT)³}(3) $$ When appropriate, describe what you’ve tried

Since i'm trying to solve the equation numerically, i first tried to make MATLAB do the work for me and simplify it but i had no success. I tried by hand but no luck either.