# FLOW_CONDITION for time-dependent pressure, temperature and saturation¶

FLOW_CONDITION can be used to assign a set of time-dependent pressure, temperature and saturations constant in space. Such a flow condition, can be applied to the reservoir with BOUNDARY_CONDITION to emulate a transient well or boundary conditions.

FLOW_CONDITION <flow_condition_name>
TYPE
OIL_PRESSURE dirichlet
OIL_SATURATION dirichlet
GAS_SATURATION dirichlet
BUBBLE_POINT dirichlet
SOLVENT_SATURATION dirichlet
TEMPERATURE dirichlet
/
OIL_PRESSURE <oil_pressure_data>
OIL_SATURATION <oil_saturation_data>
GAS_SATURATION <gas_saturation_data>
BUBBLE_POINT <bubble_point_data>
SOLVENT_SATURATION <solvent_saturation_data>
TEMPERATURE <temp_data>
INTERPOLATION <interpolation_type>
/


where:

• <flow_condition_name>: name to be used in the BOUNDARY_CONDITION coupler blocks, to associate the flow condition with a surface region.

• <oil_pressure_data>: specify the pressure values for the whole region or at the datum. This can be either be a constant value or a list in case of a time-dependent data (see transient data block)

• <oil_saturation_data>: specify the oil saturation values for the whole region. This can be either a constant value or a list in case of time-dependent data (see transient data block).

• <gas_saturation_data>: specify the gas saturation values for the whole region. This can be either a constant value or a list in case of time-dependent data (see transient data block).

• <bubble_point_data>: specify the bubble point values for the whole region. This can be either a constant value or a list in case of time-dependent data (see transient data block).

• <temp_data> specify the temperature values for the whole region. This can be either a constant value or a list in case of time-dependent data (see transient data block)

• <interpolation_type>: specifies the type of interpolation when a time-series for transient data are specified. It can be either “step” (the default), or “linear”. See transient data block for mode details.

## Transient data block to define time-dependent values within a flow condition¶

When the value to be associated with a variable (e.g. pressure, saturation, temperature) is time dependent, a time-series must be specified to define variable changes with time. This can be done directly in the in input deck using the LIST sub-block, when the data to be provided in the input deck is not too large. For a time series requiring n entries, LIST can be used as follows:

<VAR_NAME> LIST
TIME_UNITS <time_units>
DATA_UNITS <var_data_units>
<t_1> <var_value_t_1>
.....................
<t_i> <var_value_t_i>
......................
<t_n> <var_value_t_n>
END


During the simulation, the value of the variable at time t is updated using the value specified at the previous time if INTERPOLATION, in FLOW_CONDITION is set to “step”, i.e.:

$\mbox{for } t_i < t < t_{(i+1)} => \mbox{var_t} = \mbox{var_value_t_i}$

Or with a linear interpolation between the two values corresponding to t_i and t_(i+1), if INTERPOLATION is set to “linear”.

See example below:

FLOW_CONDITION source
TYPE
RATE mass_rate
TEMPERATURE dirichlet
END
RATE LIST
TIME_UNITS d
DATA_UNITS kg/s
0.     1.0   0.0
10.    1.0   0.0
10.001 0.    0.0
1d22   0.0   0.0
/
TEMPERATURE 80.0 C
END


In the example above, RATE LIST is used to impose a transient rate. TIME_UNITS and DATA_UNITS specify the units of the data entered. Each transient rate entry, under RATE LIST specifies: the time for which the rate entries are given, the water rate, the oil rate, the energy rate. In this specific case, the water rate is equal to 1.0 kg/s between 0 and 10 days, it then changes to 0 for the remainder of the simulation.

When the amount of data required to describe the time series becomes too large, this can be provided by an external file, using a FILE keyword followed by the file name, as described in the example below:

FLOW_CONDITION source
TYPE
RATE mass_rate
TEMPERATURE dirichlet
END
RATE FILE injection_rate.dat
TEMPERATURE 80.0 C
END


where the file injection_rate.dat contains the time series, with the same format used by LIST, see example below:

DATA_UNITS kg/s
0.   0.3 0.0
1.   0.5 0.0
2.   0.8 0.0
3.   1.0 0.0
4.   1.1 0.0
5.   1.2 0.0
6.   0.0 0.0
1d22 0.0 0.0