# EOS properties database¶

The database file must contain an header that states the number of nodes used to discretise the pressure (NUM_DP) and temperature (NUM_DT), and the block DATA_LIST_ORDER, which describes what are the properties listed in the database, and their column order.

The data section is then initiated by the keyword DATA, see example below:

NUM_DP 4
NUM_DT 4
DATA_LIST_ORDER
PRESSURE ! MPa
TEMPERATURE ! °C
DENSITY ! kg/m3
ENTHALPY ! J/kg
VISCOSITY ! Pa.s
END
DATA
1.0E-002 1.0E+001 7.38E+002 1.00E+004 1.040E-003
1.0E-002 3.0E+001 7.23E+002 3.00E+004 8.243E-004
.....................................................


In the example above the pressure and temperature ranges are both discretised by four nodes, thus the data section must contain 16 entries, otherwise the code will return an error. DATA_LIST_ORDER specifies that the first column is pressure, the second is temperature, the third is density and so on. The first column must be pressure and the second temperature.

The data must be reported for growing pressure and temperature, with the temperature looping faster.

The database can be used to define only some of the oil fluid properties in combination with other databases or analytical models. However when used to define a user defined gas, or CO2 it must contain all the properties required by the flow model (density, viscosity and enthalpy). The properties database cannot be used to define water.

In this example an oil database is used to define only the density:

EOS OIL
DENSITY DATABASE oil_database.dat
ENTHALPY LINEAR_TEMP 1.d3 !J/kg/°C
VISCOSITY CONSTANT 0.987d-3
END