Stability check for thermal compositional simulation
Systems and methods are provided for determining a phase state of a thermal compositional fluid sample. An exemplary method includes: providing a first set of parameters from an oilfield operation for a thermal compositional fluid sample; constructing a mass balance function for testing whether a phase of the thermal compositional fluid sample exists; inputting a sequence of time-steps to a numerical iterations technique; solving a system of nonlinear mass and energy conservation equations associated with the thermal compositional fluid sample; determining whether the system of nonlinear mass and energy conservation equations converges to provide a first solution; determining an existing phase state of the thermal compositional fluid sample; performing a stability test on the existing phase of the thermal compositional fluid sample; determining whether the thermal compositional fluid sample includes a new phase state; and updating the first set parameters based on the results from the stability test.
1 . A method for determining a phase state of a thermal compositional fluid sample comprising:
providing, using one or more computing device processors, a first set of parameters from an oilfield operation for a thermal compositional fluid sample;
constructing, using the one or more computing device processors, a monotonic mass balance function for testing whether a phase of the thermal compositional fluid sample exists based on the first set of parameters;
inputting, using the one or more computing device processors, a sequence of time-iterations to a numerical iterations technique based on the monotonic mass balance function;
solving, using the one or more computing device processors, a system of nonlinear mass and energy conservation equations associated with the thermal compositional fluid sample using the numerical iterations technique;
determining, using the one or more computing device processors, whether the system of nonlinear mass and energy conservation equations converges over a single numerical iteration to provide a first solution to the system of nonlinear mass and energy conservation equations;
in response to the system of nonlinear mass and energy conservation equations converging, determining, using the one or more computing device processors, an existing phase state of the thermal compositional fluid sample as indicated by the first solution;
in response to determining the existing phase state, performing, using the one or more computing device processors, a stability test on the existing phase state of the thermal compositional fluid sample based on the first solution;
determining, using the one or more computing device processors, whether the thermal compositional fluid sample includes an appearance of a new phase state based on results from the stability test;
updating, using the one or more computing device processors, the first set of parameters based on the results from the stability test; and
controlling, based on the existing phase state, an actuation of a drilling tool performing the oilfield operation.
2 . The method of claim 1 , wherein providing the first set of parameters comprises providing pressure, temperature, or molar rate of the thermal compositional fluid sample.
3 . The method of claim 1 , wherein constructing the monotonic mass balance function comprises constructing the monotonic mass balance function in a gas phase split.
4 . The method of claim 1 , wherein inputting the sequence of time-iterations to the numerical iterations technique comprises providing an initial time-iteration to form the sequence of time-iterations.
5 . The method of claim 1 , wherein inputting the sequence of time-iterations to the numerical iterations technique comprises utilizing a Newton-Raphson numerical technique.
6 . The method of claim 1 , wherein solving the system of nonlinear mass and energy conservation equations comprises utilizing the system of nonlinear mass and energy conservation equations to test for existence of oleic, gaseous and aqueous phases in the thermal compositional fluid sample.
7 . The method of claim 1 , wherein performing the stability test comprises confirming a simulator architecture associated with performing the stability test.
8 . The method of claim 1 , wherein performing the stability test comprises performing the stability test on a set of primary variables used by a simulator.
9 . The method of claim 7 , wherein performing the stability test comprises computing a component mole fraction for the new phase state and the existing phase state based on the stability test.
10 . A system for determining a phase state of a thermal compositional fluid sample, the system comprising:
one or more computing device processors; and
one or more computing device memories, coupled to the one or more computing device processors, the one or more computing device memories storing instructions executed by the one or more computing device processors, wherein the instructions are configured to:
provide a first set of parameters from an oilfield operation for a thermal compositional fluid sample;
construct a monotonic mass balance function for testing whether a phase of the thermal compositional fluid sample exists based on the first set of parameters;
input a sequence of time-iterations to a numerical iterations technique based on the monotonic mass balance function;
solve a system of nonlinear mass and energy conservation equations associated with the thermal compositional fluid sample using the numerical iterations technique;
determine whether the system of nonlinear mass and energy conservation equations converges over a single numerical iteration to provide a first solution to the system of nonlinear mass and energy conservation equations;
in response to the system of nonlinear mass and energy conservation equations converging, determine an existing phase state of the thermal compositional fluid sample as indicated by the first solution;
in response to determining the existing phase state, perform a stability test on the existing phase state of the thermal compositional fluid sample based on the first solution;
determine whether the thermal compositional fluid sample includes an appearance of a new phase state based on results from the stability test;
update the first set of parameters based on the results from the stability test; and
control, based on the existing phase state, actuation of a drilling tool performing the oilfield operation.
11 . The system of claim 10 , wherein the first set of parameters comprises pressure, temperature, or molar rate of the thermal compositional fluid sample.
12 . The system of claim 10 , wherein the monotonic mass balance function is in a gas phase split.
13 . The system of claim 10 , wherein the sequence of time-iterations comprises an initial time-iteration to form the sequence of time-iterations.
14 . The system of claim 10 , wherein the numerical iterations technique is a Newton-Raphson numerical technique.
15 . The system of claim 10 , wherein the system of nonlinear mass and energy conservation equations are used to test for existence of oleic, gaseous and aqueous phases in the thermal compositional fluid sample.
16 . The system of claim 10 , wherein the stability test is used to compute a mole fraction for the new phase state and the existing phase state.
17 . The system of claim 10 , wherein the stability test requires identifying a simulator architecture used for performing the stability test.
18 . The system of claim 10 , wherein the stability test is performed on a set of primary variables used by a simulator.