Skip to content

Two roots for Carbon Dioxide at standard conditions? #31

Description

@jonnymaserati

Hi there

Any idea why the following gives a root in the liquid phase? I'd like to use this for determining the phase (and density) for differing P and T, but seems that it's not able?

import numpy as np
from pint import UnitRegistry
import pyforfluids as pff

model = pff.models.GERG2008()
ureg = UnitRegistry()
Q_ = ureg.Quantity

fluid = pff.Fluid(model, {"carbon_dioxide": 1.0}, temperature=Q_(0, ureg.celsius).to(ureg.kelvin).m, pressure=Q_('1 atm').to('Pa').m)

The last line gives a UserWarning: Two roots were found! Vapor-phase value will be used.

Ref the diagram below, 0 Celsius and 1 atm looks to me like it's well within the gas phase, so why is a fluid phase root being determined?

image

>>> fluid.density_iterator(Q_('1 atm').to('Pa').m)
(20.16256859062894, 0.044918356427274264, False)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions