# iMOD User Manual version 5.2 (html)

#### 8.5IPF-FUNCTIONS

##### 8.5.1IPFSTAT-Function

The IPFSTAT function can be used to perform statistical analyses on time series that are defined in IPF files as associated files.

Example 1

FUNCTION=IPFSTAT
IPFFILE_IN=D:\TESTS\TEST.IPF
IPFFILE_OUT=D:\TESTS\OUT.IPF
IVARS=3

The example above computes the average groundwaterlevels (or equivalent) that are associated with the IPF file TEST.IPF. The result is stored in OUT.IPF.

Example 2

FUNCTION=IPFSTAT
IPFFILE_IN=D:\TESTS\MEASURE.IPF
IPFFILE_OUT=D:\TESTS\MODEL.IPF
VARIABLES=4,5
PERC=50.0
SDATE=20100101
EDATE=20170101
MINMEASURE=18
DIFFDAY=2
IACOL=3

The example above, computes the GHG and GLG for the measurements in the second column associated with the MEASURE.IPF for the 1$^{\rm st}$ of January 2010 up to the 1$^{\rm st}$ of January 2017. It takes years into account that have at least 18 measurement for the appropriates dates of 14$^{\rm st}$ and 28$^{\rm st}$ per month, which can differ for maximal 2 days (DIFFDAY=2).

##### 8.5.2IPFSPOTIFY-Function

The IPFSPOTIFY function can be used to spotify geological formations in existing model discretisations. It gives per model layer the fraction that a geological formation exists. The output of this function (whenever OUTPUFOLDER is specified) can be used in the function CREATEIZONE, see section section 8.9.2.

Example 1

FUNCTION=IPFSPOTIFY
IPFFILE_IN=D:\WELLS\TEST.IPF
IPFFILE_OUT=D:\SPOTIFIED\OUT.IPF
NLAY=2
TOP_L1=D:\MODEL\TOP_L1.IDF
BOT_L1=D:\MODEL\BOT_L1.IDF
TOP_L2=D:\MODEL\TOP_L2.IDF
BOT_L2=D:\MODEL\BOT_L2.IDF
REGISTOP=D:\REGIS\*-T-CK.IDF
REGISBOT=D:\REGIS\*-B-CK.IDF

The example above computes the fractions for each location in the IPFFILE_IN of all geological formations in REGISTOP and REGISBOT for each model layer.

Example 2

FUNCTION=IPFSPOTIFY
OUTPUTFOLDER=D:\FRACTIONS\AQUIFER
NLAY=2
TOP_L1=D:\MODEL\TOP_L1.IDF
BOT_L1=D:\MODEL\BOT_L1.IDF
TOP_L2=D:\MODEL\TOP_L2.IDF
BOT_L2=D:\MODEL\BOT_L2.IDF
REGISTOP=D:\REGIS\*-T-CK.IDF
REGISBOT=D:\REGIS\*-B-CK.IDF

The example above, computes the fractions for each cell in the model layers for each geological formation defined by the REGISTOP and REGISBOT keywords, the results are stored in the AQUIFER folder. To spotify aquitards in it is neccessary to switch the top and bottom elevations, e.g.

FUNCTION=IPFSPOTIFY
OUTPUTFOLDER=D:\FRACTIONS\AQUITARD
NLAY=1
TOP_L1=D:\MODEL\BOT_L1.IDF
BOT_L1=D:\MODEL\TOP_L2.IDF
REGISTOP=D:\REGIS\*-T-CK.IDF
REGISBOT=D:\REGIS\*-B-CK.IDF

##### 8.5.3IPFSAMPLE-Function

The function IPFSAMPLE samples IDF-files to add values to the points defined in an IPF file.

Example 1

FUNCTION=IPFSAMPLE
IPFFILE_IN=D:\WELLS.IPF
IPFFILE_OUT=D:\WELLS_KD.IPF
SOURCEDIR=D:\DATA\KD*.IDF

This example, adds values (columns) to all points in the IPF file WELLS.IPF, with the corresponding values from the KD*.IDF-files in the folder D:\DATA.

Example 2

FUNCTION=IPFSAMPLE
IPFFILE_IN=D:\WELLS.IPF
IPFFILE_OUT=D:\WELLS.IPF
SOURCEDIR=D:\DATA\KD*.IDF
IXCOL=4
IYCOL=3

This example, adds values (columns) to all points in the IPF file WELLS.IPF, with the corresponding values from the KD*.IDF-files in the folder D:\DATA. The x- and y coordinates in the IPF file WELLS.IPF, will be read from the fourth and third column, respectively.

##### 8.5.4IPFEVALUATE-Function

The function IPFEVALUATE samples IDF-files to add model result values (e.g. heads) to the points defined in an IPF file (by using IPFSAMPLE) and evaluates if the measurements are linked to the correct model layer by comparing them to the model results. The resulting IPF-file shows the original model layer, the proposed model layer and the difference between those two.

The format of the resulting IPF-file is fixed (except for the sampled column names) and is like:

Example 1

FUNCTION=IPFEVALUATE
IPFFILE_IN=D:\WELLS_L1.IPF
IXCOL=1
IYCOL=2
IACOL=9
IMCOL=4
ILCOL=3
IPFFILE_OUT=D:\WELLS_cal_opt_l1.IPF
IPFLAYERS=D:\WELLS_opt_layers_l1.IPF

This example, adds values (columns) to all points in the IPF file WELLS_L1.IPF, with the corresponding values from the head_steady_state_l*.IDF-files in the folder D:\DATA. The x- and y coordinates in the IPF file WELLS_L1.IPF, will be read from the first and second column, respectively and the values will be added to the 9th column onwards, so in case there are 5 IDF-files in the SOURCEDIR with the given format the values will be placed in column 9, 10, 11, 12 and 13. The measurement values will be read from the fourth column and the layer number from column 3.

##### 8.5.5IPFEDIT-Function

The function IPFEDIT reorganises an existing IPF file.

Example 1

FUNCTION=IPFEDIT
IPFFILE_IN=D:\WELLS.IPF
IPFFILE_OUT=D:\WELLS_CLEANED.IPF
NCOLUMNS=3
ICOL1=1
ICOL2=2
ICOL3=8

This example, reduces the original D:\WELLS.IPF for 3 columns determined by the columns 1,2 and 8. The results is saved into D:\WELLS_CLEANED.IPF.

##### 8.5.6IPFSUM-Function

The function IPFSUM generates a list of total volumes per specified year for zone (if needed) form IPF files. This can be used to prior check the IPF files before entering the model.

Example 1

FUNCTION=IPFSUM
NFILE=1
IPFFILE_1=D:\DATA\WELL_L1.IPF
SDATE=19500101
EDATE=20191231
DDATE=4
OUTPUTFILE=D:\OUTPUT.TXT

This example, summes all volumes from the IPF file on a yearly basis (DDATE=4) in between the 1$^{\rm th}$ of January 1950 up to the 31$^{\rm st}$ of December 2019 and saves the volumes in D:\OUTPUT.TXT.

##### 8.5.7IPFEDITWEIGHT-Function

Use this function to adjust the weight value in an ipf-file by making use of a pointer grid.

Example 1

FUNCTION=IPFEDITWEIGHT
IPFFILE_IN="d:\MODELLEN \TWENTE\DBASE\MEETREEKSEN\VERSION_1\IMOD_MKIPF_WELLS_L1.IPF"
WCOL=9
FACTOR_IN=1.0
FACTOR_OUT=0.1
POINTERIDF="d:\MODELLEN \TWENTE\DBASE\MEETREEKSEN\POINTER_INSIDE.idf"
PVAL=1.0
IPFFILE_OUT="d:\MODELLEN\TWENTE\DBASE\MEETREEKSEN\VERSION_2\IMOD_MKIPF_WELLS_L1.IPF"

This example multiplies the weight values with a factor 0.1 (=FACTOR_OUT) for all locations that are located outside the pointer grid; grid values other than 1.0 (=PVAL). For locations that are linked to grid values equal to 1.0 the multiplication factor for the weight value is 1.0 (=FACTOR_IN).