Oneeq19b

Name: Oneeq19b - Compressibility factor from the RK equation - one solution
       
Source: Cutlip, M. B. and Shacham, M, Problem Solving in Chemical
  Engineering with Numerical Methods (2nd Ed), Prentice Hall Inc., 1999
Reference/s      
       
Model: 1 implicit equation, indep. variable name: z
  Average difficulty level
  Constraints: z>0
  Discontinuities: none in the range of interest
  Initial range: zmin=-0.5, zmax=1.2
       
Solved by Shacham, M., POLYMATH 5.1, build 19, April 1, 2001
       
Model Eqs. Compressibility factor from the RK equation - one solution |POLVER05_1

EXCEL FILE 

f(z)=z^3-z^2-Q*z-r #

TEXT FILE 

P = 200 #

POLYMATH FILE 

Pc=33.5 #
  T= 631 #
  Tc=126.2 #
  Pr=P/Pc #
  Tr=T/Tc #
  Asqr=0.4278*Pr/(Tr^2.5) #
  B=0.0867*Pr/Tr #
  Q=B^2+B-Asqr #
  r=Asqr*B #
  p=(-3*Q-1)/3 #
  q=(-27*r-9*Q-2)/27 #
  R=(p/3)^3+(q/2)^2 #
  V=if(R>0)then((-q/2+sqrt(R))^(1/3))else(0) #
  WW=if(R>0)then(-q/2-sqrt(R))else(0) #
  psi1 = if(R<0)then(arccos(sqrt((q^2/4)/(-p^3/27))))else(0) #
  W = if(R>0)then(sign(WW)*(abs(WW))^(1/3))else(0) #
  z1 = if(R<0)then(2*sqrt(-p/3)*cos((psi1/3)+2*3.1416*0/3)+1/3)else(0) #
  z2 = if(R<0)then(2*sqrt(-p/3)*cos((psi1/3)+2*3.1416*1/3)+1/3)else(0) #
  z3 = if(R<0)then(2*sqrt(-p/3)*cos((psi1/3)+2*3.1416*2/3)+1/3)else(0) #
  z0=if(R>0)then(V+W+1/3)else(0) #
  z(min)=-.5, z(max)=1.2
       
Variable/function values Variable Value f(x)
  z 0.35 -1.0835E-01
  P 200  
  Pc 33.5  
  T 631  
  Tc 126.2  
  Pr 5.970149254  
  Tr 5  
  Asqr 0.045687875  
  B 0.103522388  
  Q 0.068551398  
  r 0.004729718  
  p -0.401884731  
  q -0.101654258  
  R 0.000179362  
  V 0.400457283  
  WW 0.037434511  
  psi1 0  
  W 0.334521515  
  z1 0  
  z2 0  
  z3 0  
  z0 1.068312132  
       
Root Variable Value f(x)
  z 1.06831213384200 2.89E-16
  P 200  
  Pc 33.5  
  T 631  
  Tc 126.2  
  Pr 5.970149254  
  Tr 5  
  Asqr 0.04568787490270  
  B 0.10352238805970  
  Q 0.06855139798660  
  r 0.00472971791530  
  p -0.40188473132000  
  q -0.10165425798490  
  R 0.00017936221260  
  V 0.40045728293280  
  WW 0.03743451115230  
  psi1 0  
  W 0.33452151531760  
  z1 0  
  z2 0  
  z3 0  
  z0 1.06831213158400  
       
Additional Information The plot can be interpreted as there is a double root in the
  vicinity of z =0. The analytical solution shows however that
  there is only a single root. The absolute function value
  is minimal at z=-0.03267 where f(z) = -0.0035
       
Function plot