jcaiuwyo / cantera

Automatically exported from code.google.com/p/cantera
0 stars 0 forks source link

Error: wrong root found for sat. liquid or vapor at P = 2.2089e+007 #21

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Using Cantera toolbox in Matlab: Define water state (i.e. w=Water;)
2. set(w,'T',647.25,'P',10001000);

What is the expected output? What do you see instead?
Expected: (what I get with T rounded to 647)
water:

        temperature             647  K
           pressure     1.0001e+007  Pa
            density          40.914  kg/m^3
   mean mol. weight          18.016  amu
     vapor fraction               1 

                           1 kg            1 kmol
                        -----------      ------------
           enthalpy    -1.29592e+007      -2.335e+008     J
    internal energy    -1.32036e+007      -2.379e+008     J
            entropy          9603.3        1.73e+005     J/K
     Gibbs function    -1.91725e+007      -3.454e+008     J
  heat capacity c_p          3438.8       6.195e+004     J/K
  heat capacity c_v         2126.22       3.831e+004     J/K

What I see instead:
??? Error using ==> ctmethods

************************************************
                Cantera Error!
************************************************

Procedure: tpx::Substance::update_sat
Error:   wrong root found for sat. liquid or vapor at P = 2.20795e+007

Error in ==> thermo_set at 5
  i = ctmethods(20,n,-job,a);

Error in ==> ThermoPhase.setPressure at 11
thermo_set(a.tp_id,1,p);
Error in ==> Solution.set at 156
    setPressure(a, pval);

What version of the product are you using? On what operating system?
Cantera-1.7.0.win32-py2.5
Windows XP version 5.1 with Service pack 2

Please provide any additional information below.
I can't see any pattern why this happens with some temperature values but not 
others.  Any insight would be GREATLY appreciated!  Thank you!

Original issue reported on code.google.com by wags...@gmail.com on 15 Jun 2010 at 4:32

GoogleCodeExporter commented 9 years ago

Original comment by yarmond on 28 May 2011 at 12:59

GoogleCodeExporter commented 9 years ago
In in r1450, I made some adjustments to the algorithm for finding the saturated 
states at a given temperature that fix this issue and some other convergence 
issues in the pure fluid model.

Original comment by yarmond on 11 May 2012 at 3:32