OpendTect  6.6
welld2tmodel.h
Go to the documentation of this file.
1 #pragma once
2 
3 /*+
4 ________________________________________________________________________
5 
6  (C) dGB Beheer B.V.; (LICENSE) http://opendtect.org/OpendTect_license.txt
7  Author: Bert Bril
8  Date: Aug 2003
9  RCS: $Id$
10 ________________________________________________________________________
11 
12 
13 -*/
14 
15 #include "wellmod.h"
16 #include "welldahobj.h"
17 #include "uistring.h"
18 
19 class TimeDepthModel;
20 class uiString;
21 
22 namespace Well
23 {
24 
25 class Data;
26 class Track;
27 class Info;
28 
35 public:
36 
37  D2TModel( const char* nm= 0 )
38  : DahObj(nm) {}
39  D2TModel( const D2TModel& d2t )
40  : DahObj("") { *this = d2t; }
41  D2TModel& operator =(const D2TModel&);
42  bool operator ==(const D2TModel&) const;
43  bool operator !=(const D2TModel&) const;
44 
45  float getTime(float d_ah, const Track&) const;
46  float getDepth(float time, const Track&) const;
47  float getDah(float time, const Track&) const;
48  double getVelocityForDah(float d_ah,const Track&) const;
49  double getVelocityForDepth(float dpt,const Track&) const;
50  double getVelocityForTwt(float twt,const Track&) const;
52  TimeDepthModel&) const;
53 
54  inline float t( int idx ) const { return t_[idx]; }
55  float value( int idx ) const { return t(idx); }
56  float* valArr() { return t_.arr(); }
57  const float* valArr() const { return t_.arr(); }
58 
61 
62  static const char* sKeyTimeWell();
63  static const char* sKeyDataSrc();
65 
66  void add( float d_ah, float tm )
67  { dah_ += d_ah; t_ += tm; }
68  bool insertAtDah(float d_ah,float t);
69 
70  void makeFromTrack(const Track&, float cstvel,
71  float replvel);
74  bool ensureValid(const Well::Data&,uiString& errmsg,
75  TypeSet<double>* zvals=0,
76  TypeSet<double>* tvals=0);
79 
80 protected:
81 
83 
84  void removeAux( int idx ) { t_.removeSingle(idx); }
85  void eraseAux() { t_.erase(); }
86 
87  bool getVelocityBoundsForDah(float d_ah,const Track&,
88  Interval<double>& depths,
89  Interval<float>& times) const;
90  bool getVelocityBoundsForTwt(float twt,const Track&,
91  Interval<double>& depths,
92  Interval<float>& times) const;
94  int getVelocityIdx(float pos,const Track&,
95  bool posisdah=true) const;
96 
97 protected:
98 
99  inline float getDepth( float time ) const { return mUdf(float); }
101  bool getOldVelocityBoundsForDah(float d_ah,const Track&,
102  Interval<double>& depths,
103  Interval<float>& times) const;
105  bool getOldVelocityBoundsForTwt(float twt,const Track&,
106  Interval<double>& depths,
107  Interval<float>& times) const;
109  static bool getTVDD2TModel( Well::D2TModel& d2t, const Well::Data& wll,
110  TypeSet<double>& zvals, TypeSet<double>& tvals,
111  uiString& errmsg, uiString& warnmsg );
112  static void convertDepthsToMD( const Well::Track& track,
113  const TypeSet<double>& zvals,
114  TypeSet<float>& dahs );
115  static void shiftTimesIfNecessary( TypeSet<double>& tvals, double wllheadz,
116  double vrepl, double origintwtinfile,
117  uiString& msg );
119  double vreplinfile,
120  uiString& msg );
121 };
122 
129 
130 
131 }; // namespace Well
132 
Well::getDefaultVelocity
float getDefaultVelocity()
Well::D2TModel::getVelocityForDepth
double getVelocityForDepth(float dpt, const Track &) const
Well::D2TModel::desc
BufferString desc
Definition: welld2tmodel.h:59
Well::D2TModel::getVelocityForTwt
double getVelocityForTwt(float twt, const Track &) const
Well::D2TModel::getTVDD2TModel
static bool getTVDD2TModel(Well::D2TModel &d2t, const Well::Data &wll, TypeSet< double > &zvals, TypeSet< double > &tvals, uiString &errmsg, uiString &warnmsg)
uistring.h
Well::Data
The holder of all data concerning a certain well.
Definition: welldata.h:121
mGlobal
#define mGlobal(module)
Definition: commondefs.h:180
Well::D2TModel::D2TModel
D2TModel(const D2TModel &d2t)
Definition: welld2tmodel.h:39
mExpClass
#define mExpClass(module)
Definition: commondefs.h:177
Well::D2TModel::makeFromTrack
void makeFromTrack(const Track &, float cstvel, float replvel)
Well::D2TModel::valArr
float * valArr()
Definition: welld2tmodel.h:56
Well::D2TModel::ensureValid
bool ensureValid(const Well::Data &, uiString &errmsg, TypeSet< double > *zvals=0, TypeSet< double > *tvals=0)
Well::D2TModel::convertDepthsToMD
static void convertDepthsToMD(const Well::Track &track, const TypeSet< double > &zvals, TypeSet< float > &dahs)
Well::Info
Information about a certain well.
Definition: welldata.h:45
Repos::Data
@ Data
Definition: repos.h:24
Well::D2TModel::mODTextTranslationClass
mODTextTranslationClass(D2TModel)
operator==
bool operator==(const ArrayNDInfo &a1, const ArrayNDInfo &a2)
Definition: arrayndinfo.h:81
Well::D2TModel::shiftTimesIfNecessary
static void shiftTimesIfNecessary(TypeSet< double > &tvals, double wllheadz, double vrepl, double origintwtinfile, uiString &msg)
Well::D2TModel::t_
TypeSet< float > t_
Definition: welld2tmodel.h:82
Well::D2TModel::eraseAux
void eraseAux()
Definition: welld2tmodel.h:85
Well::D2TModel::D2TModel
D2TModel(const char *nm=0)
Definition: welld2tmodel.h:37
Well::Track
Well track.
Definition: welltrack.h:29
TimeDepthModel
Converts between time, depth and velocity given a model. The velocity model can be either RMO-velocit...
Definition: velocitycalc.h:31
Well
Definition: directionalsurvey.h:20
Well::D2TModel::t
float t(int idx) const
Definition: welld2tmodel.h:54
Well::D2TModel::datasource
BufferString datasource
Definition: welld2tmodel.h:60
Well::D2TModel::getVelocityForDah
double getVelocityForDah(float d_ah, const Track &) const
Well::D2TModel::getVelocityBoundsForTwt
bool getVelocityBoundsForTwt(float twt, const Track &, Interval< double > &depths, Interval< float > &times) const
Well::D2TModel::getOldVelocityBoundsForTwt
bool getOldVelocityBoundsForTwt(float twt, const Track &, Interval< double > &depths, Interval< float > &times) const
Read legacy incorrect time-depth model.
operator!=
bool operator!=(const ArrayNDInfo &a1, const ArrayNDInfo &a2)
Definition: arrayndinfo.h:90
Well::D2TModel::getDepth
float getDepth(float time, const Track &) const
Well::D2TModel::getOldVelocityBoundsForDah
bool getOldVelocityBoundsForDah(float d_ah, const Track &, Interval< double > &depths, Interval< float > &times) const
Read legacy incorrect time-depth model.
Well::D2TModel::getTime
float getTime(float d_ah, const Track &) const
Well::D2TModel::getVelocityBoundsForDah
bool getVelocityBoundsForDah(float d_ah, const Track &, Interval< double > &depths, Interval< float > &times) const
BufferString
OD::String with its own variable length buffer. The buffer has a guaranteed minimum size.
Definition: bufstring.h:40
Well::D2TModel::removeAux
void removeAux(int idx)
Definition: welld2tmodel.h:84
Well::D2TModel::value
float value(int idx) const
Definition: welld2tmodel.h:55
uiString
String that is able to hold international (UTF-8) strings for the user interface.
Definition: uistring.h:121
welldahobj.h
Well::D2TModel::sKeyTimeWell
static const char * sKeyTimeWell()
known in time
Well::D2TModel::getDah
float getDah(float time, const Track &) const
mUdf
#define mUdf(type)
Use this macro to get the undefined for simple types.
Definition: undefval.h:274
Well::D2TModel::getTimeDepthModel
bool getTimeDepthModel(const Well::Data &, TimeDepthModel &) const
Interval< double >
Well::D2TModel::insertAtDah
bool insertAtDah(float d_ah, float t)
Well::D2TModel::getVelocityIdx
int getVelocityIdx(float pos, const Track &, bool posisdah=true) const
Well::D2TModel
Depth to time model.
Definition: welld2tmodel.h:34
Well::D2TModel::valArr
const float * valArr() const
Definition: welld2tmodel.h:57
Well::D2TModel::getDepth
float getDepth(float time) const
Legacy, misleading name. Use getDah().
Definition: welld2tmodel.h:99
Well::D2TModel::add
void add(float d_ah, float tm)
Definition: welld2tmodel.h:66
Well::D2TModel::checkReplacementVelocity
static void checkReplacementVelocity(Well::Info &info, double vreplinfile, uiString &msg)
TypeSet< double >
Well::DahObj
Depth/Distance along hole object.
Definition: welldahobj.h:28

Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B.V. 1995-2021