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

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