UNIVERS  15.3
UNIVERS base processing software API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
rt_storage.hpp
1 // rt_storage.hpp
2 // $Id: rt_storage.hpp,v 1.5 2006/10/05 07:49:01 guser4 Exp $
3 //-----------------------------------------------------------------------------
4 #ifndef __rtStorageH
5 #define __rtStorageH
6 
7 #include "vel2dmod_raytr_global.hpp"
8 
9 #ifndef GE_BUILD_RAYTR
10 #include <vel2dmod/vel2dmod_global.hpp>
11 #else
12 #include <vel2dmod_global.hpp>
13 #endif
14 
15 
16 
17 //== Structures ================================================================
18 typedef struct
19 {
20  int bNum; /* bounds[0]=-1 means shot point */
21  int segNum;
22  WAVE_TYPE wType; /* PRESSURE or SHEAR */
23  bool trFlag; /* TRUE-transfer, FALSE-reflection from the bound */
24 } CodeItem;
25 
26 
27 
29 
30 /*
31 #define AnyAr CodeAr
32 #define AnyType CodeItem
33 #include <mix/AnyAr.H>
34 */
35 
36 
37 
39 //=============================================================================
40 struct RayIntSt
41 {
42  int bNum1, bNum2;
43  int boundNum;
44  double ix, iz;
45  double coeff;
46  double t;
47  double f1;
48  double f2;
49  double iAngle;
50  double iCurv;
51 };
52 
54 //=============================================================================
55 struct RayWIntSt
56 {
57  double x, z;
58  double f;
59  double t;
60  double ampl;
61 };
62 
64 
65 /*
66 #define AnyType RayIntSt
67 #define AnyAr RayIntStAr
68 #include <mix/AnyAr.H>
69 */
70 
71 //=============================================================================
73 
74 class RayInfo
75 {
76  public:
77 
79  RayInfo(double shotX, double shotZ, double startAngle);
80 
81  ~RayInfo();
82 
84  void AddPoint(double x, double z);
85 
87  void AddRayAngle(double f);
88 
90  void GetStartParams(double &x, double &z, double &f);
91 
93  void GetRayCode(CodeAr &rCode);
94 
96  int GetPointsNum();
97 
99  void GetPoints(double *x, double *z);
100 
102  void GetLastPoint(double &x, double &z);
103 
104  void GetRayAngles(double *f);
105 
106  double GetLastAngle();
107 
109  int GetRayCodeNum();
110 
112  void SetRayCode(CodeAr rCode);
113 
115  void AddRayInt(double x, double z,double f1, double f2, double time, int bn1,
116  int bn2, int boundN, double coeff, double iAngle, double iCurv);
117 
119  void AddRayWInt(double x, double z, double f, double t);
120 
122  int GetRayIntNum();
123 
125  void GetRayInt(double* x, double* z, int* bn1, int* bn2, int* boundN,
126  double* coeff, int &n, double *t = NULL, double *f1 = NULL,
127  double *f2 = NULL, double *iAngle = NULL, double *iCurv = NULL);
128 
130  bool GetRayNInt(int N, double &x, double &z, int &bn1, int &bn2, int &boundN, double &coeff, double &t,
131  double &f1, double &f2, double &iAngle, double &iCurv);
132  void GetRayIntN(int n, double &x, double &z);
133 
135  bool GetBoundIntInfo(int boundNum, double &x, double &z, int &bn1, int &bn2, double &coeff, double &t,
136  double &f1, double &f2, double &iAngle, double &iCurv);
137 
139  void GetRayIntN(int n, int &bn);
140 
142  void GetRayInt1(double &x, double &z, int &bn1, int &bn2, int &boundN, double &coeff,
143  double &t, double &f1, double &f2, double &iA, double &iCurv);
144 
146  void GetRayIBNums(int_ar *iBNums);
147 
149  int GetRayWIntNum();
150 
152  void GetRayWInt(double *x, double *z, double *f, double *t, int &n);
153 
155  void GetRayWInt1(double &x, double &z, double &f, double &t);
156 
158  double GetSD();
159 
161  void SetSD(double SD);
162 
163  void SetResParams(double resAmpl, double resAngle, double resTime,
164  double resX, double resZ);
165 
166  void GetResParams(double &resAmpl, double &resAngle, double &resTime,
167  double &resX, double &resZ);
168 
169  void CalcRayPz(double f, double az, double &pf, double &paz, WAVE_TYPE vPS);
170 
172  void SetOOMFlag();
174  bool GetOOMFlag();
175 
176  private:
177 
179  double spX, spZ;
180  double stAngle;
181  double sd;
182 
183  double resAmpl, resAngle, resTime, resX, resZ;
184 
185  int *codeBN;
186  WAVE_TYPE *codeVPS;
187  bool *codeRTR;
188  int codeNum;
189 
190  int pNum;
191  double_ar *rx;
192  double_ar *rz;
193  double_ar *rf;
194  RayIntStAr RayInt;
195 
196  // RayWIntStAr RayWInt;
197 
198  double wx, wz, wf, wt, wampl;
199  bool outOfModel;
200 
201 };
202 
203 #endif
void AddRayInt(double x, double z, double f1, double f2, double time, int bn1, int bn2, int boundN, double coeff, double iAngle, double iCurv)
RayInfo(double shotX, double shotZ, double startAngle)
void SetSD(double SD)
void GetStartParams(double &x, double &z, double &f)
double f1
Definition: rt_storage.hpp:47
int bNum2
Definition: rt_storage.hpp:42
void GetRayIBNums(int_ar *iBNums)
Strucure describing well intersections.
Definition: rt_storage.hpp:55
void GetRayCode(CodeAr &rCode)
void AddRayAngle(double f)
void GetRayInt1(double &x, double &z, int &bn1, int &bn2, int &boundN, double &coeff, double &t, double &f1, double &f2, double &iA, double &iCurv)
bool GetOOMFlag()
void AddPoint(double x, double z)
void AddRayWInt(double x, double z, double f, double t)
Ray data storage sturcture.
Definition: rt_storage.hpp:74
void GetRayInt(double *x, double *z, int *bn1, int *bn2, int *boundN, double *coeff, int &n, double *t=NULL, double *f1=NULL, double *f2=NULL, double *iAngle=NULL, double *iCurv=NULL)
double GetSD()
int GetPointsNum()
double iCurv
Definition: rt_storage.hpp:50
void GetRayWInt1(double &x, double &z, double &f, double &t)
void GetRayWInt(double *x, double *z, double *f, double *t, int &n)
void SetOOMFlag()
double coeff
Definition: rt_storage.hpp:45
Definition: rt_storage.hpp:18
bool GetRayNInt(int N, double &x, double &z, int &bn1, int &bn2, int &boundN, double &coeff, double &t, double &f1, double &f2, double &iAngle, double &iCurv)
Definition: objectar.hpp:57
int GetRayIntNum()
double f2
Definition: rt_storage.hpp:48
double t
Definition: rt_storage.hpp:46
double iAngle
Definition: rt_storage.hpp:49
int boundNum
Definition: rt_storage.hpp:43
bool GetBoundIntInfo(int boundNum, double &x, double &z, int &bn1, int &bn2, double &coeff, double &t, double &f1, double &f2, double &iAngle, double &iCurv)
int GetRayWIntNum()
int GetRayCodeNum()
Definition: objectar.hpp:55
Structure describing ray intersections.
Definition: rt_storage.hpp:40
double iz
Definition: rt_storage.hpp:44
void SetRayCode(CodeAr rCode)
void GetLastPoint(double &x, double &z)
void GetPoints(double *x, double *z)