gstlearn  0.2.1
Geostatistics & Machine Learning toolbox
spill.cpp File Reference
#include "geoslib_old_f.h"
#include "Basic/Utilities.hpp"
#include "Basic/File.hpp"
#include "Db/Db.hpp"
#include "Db/DbGrid.hpp"
#include "Basic/String.hpp"
#include "Basic/OptDbg.hpp"
#include <string.h>

Classes

struct  SPIMG
 

Functions

int spill_point (DbGrid *dbgrid, int ind_depth, int ind_data, int flag_up, int flag_cross, int flag_unknown, int flag_verbose, double hmax, double *h, double *th, int *ix0, int *iy0)
 

Function Documentation

◆ spill_point()

int spill_point ( DbGrid dbgrid,
int  ind_depth,
int  ind_data,
int  flag_up,
int  flag_cross,
int  flag_unknown,
int  flag_verbose,
double  hmax,
double *  h,
double *  th,
int *  ix0,
int *  iy0 
)

Evaluates the spill point

Returns
Error return code
- Memory problem
- Maximum Reservoir Thickness violation when turning UNKNOWN into
INSIDE
Parameters
[in]dbgridGrid Db structure
[in]ind_depthRank of the variable containing the depth
[in]ind_dataRank of the variable containing the data
[in]flag_up1 when working in elevation; 0 in depth
[in]flag_cross1 for 4-connectivity; 0 for 8-connectivity
[in]flag_unknown1 if Unknown must be converted into Reservoir; 0 otherwise
[in]flag_verbose1 for a verbose output
[in]hmaxmaximum reservoir thickness (FFFF not used)
[out]helevation of the spill point
[out]thmaximum reservoir thickness
[out]ix0location of the spill point grid node along X
[out]iy0location of the spill point grid node along Y
Remarks
The variable 'ind_data', which contains the constraints, must
be set to:
0 for an idle node
1 for a node located outside the reservoir
2 for a node belonging to the reservoir
The numbering of the grid node corresponding to the spill point
must start with 1