4 #ifndef __2dModelServiceH
5 #define __2dModelServiceH
7 #include "vel2dmod.hpp"
8 #include "vel2dmod_global.hpp"
15 int initial_kn1, initial_kn2;
29 friend class Vel2dModelGEDB;
35 Bound(
double *xx,
double *zz,
int nn,
bool *flag,
double rc,
double sp,
36 double *xx1 = NULL,
double *zz1 = NULL,
int nn1 = 0);
39 Bound(
double *xx,
double *zz,
int nn,
double rc,
double sp);
42 Bound(
double *xx,
double *zz,
double *dx,
double *dz,
double *curv,
bool *flag,
int nn,
43 double *init_x = NULL,
double *init_z = NULL,
bool *init_flags = NULL,
int init_num = 0);
46 Bound(
double *xx,
double *zz,
double *dx,
double *dz,
double *curv,
bool *flag,
int nn,
int app_type,
47 double *init_x = NULL,
double *init_z = NULL,
bool *init_flags = NULL,
int init_num = 0);
60 bool BoundInt(
double x1,
double z1,
double x2,
double z2,
61 double eps,
double &resultX,
double &resultZ,
bool flag=
true,
62 bool finitLine=
true,
int *nn=NULL);
65 void GetEndPoints(
double &x1,
double &z1,
double &x2,
double &z2);
70 int GetSegNum(
double x,
double z);
73 void GetInitialPoints(
double *x,
double *z,
bool *flags);
74 void GetRC_SP(
double &rc,
double &sp);
76 void ReInterpolate(
double *x,
double *z,
bool *flag,
int n,
double r_c = 0,
double s_p = 0,
bool *im_flag=NULL);
78 void GetZLimits(
double &z_min,
double &z_max);
80 void GetFirstPoint(
double &x,
double &z) {
if ((initial_x!=NULL)&&(initial_z!=NULL)&&(initial_pnum>0)&&
filled)
81 { x=initial_x[0]; z=initial_z[0]; }
else {x=0; z=0;} }
83 void GetLastPoint(
double &x,
double &z) {
if ((initial_x!=NULL)&&(initial_z!=NULL)&&(initial_pnum>0)&&
filled)
84 { x=initial_x[initial_pnum-1]; z=initial_z[initial_pnum-1]; }
102 double GetPeak(
double *x,
double *z,
bool top);
103 void SetRC_SP(
double rc,
double sp);
148 BodyParam(
int vMN,
double *x,
double *z,
double *vp,
double *vs,
double *pkz,
149 double *skz,
double *den,
double ma_xmin,
double ma_xmax,
150 double an_kp,
double an_ks,
double R);
152 BodyParam(
double vp,
double vs,
double pkz,
double skz,
double den,
double ma_xmin,
double ma_xmax,
153 double an_kp,
double an_ks,
double R);
155 BodyParam(
int vMN,
double *x,
double *vp,
double *vs,
double *pkz,
156 double *skz,
double *den,
double ma_xmin,
double ma_xmax,
157 double an_kp,
double an_ks,
double R);
164 double GetV0(
double x, WAVE_TYPE wt);
167 double GetKx(
double x, WAVE_TYPE wt);
172 double GetCVel(WAVE_TYPE wt);
175 double GetCKz(WAVE_TYPE wt);
179 void GetParams(
int &pn,
double *&px,
double *&pz,
double *&pPVel,
double *&pSVel,
180 double *&pPKz,
double *&pSKz,
double *&pDen);
189 void RebuildParams(
int vMN,
double *new_x,
double *new_vp,
double *new_vs,
double *new_kzp,
190 double *new_kzs,
double *new_den);
195 void GetMASizes(
double &xmn,
double &xmx) { xmn=x_min; xmx=x_max; };
200 int GetParamNum() {
return paramNum; };
202 double GetAnCoef(WAVE_TYPE wt,
double ang);
204 double GetAn(WAVE_TYPE wt);
216 void SetAnKP(
double an_kp) { m_an_kp = an_kp; }
219 void SetAnKS(
double an_ks) { m_an_ks = an_ks; }
227 void Replace(
int N,
double *M,
int i,
int j);
230 void RefreshParams(
int vMN,
double *new_x,
double *new_vp,
double *new_vs,
double *new_kzp,
231 double *new_kzs,
double *new_den);
289 bool BodyBorder(
int bNum,
double x,
double &z);
295 void SetConstParams(
double vp,
double vs,
double kzp,
double kzs,
double den,
296 double an_kp = 1,
double an_ks = 1,
double R = 1);
299 void SetParams(
int pNum,
double *x,
double *vp,
double *vs,
double *kzp,
double *kzs,
double *den,
300 double an_kp = 1,
double an_ks = 1,
double R = 1);
308 bool GetLateralBounds(
int &left_bN,
int &right_bN);
310 void GetZLimits(
double &z_min,
double &z_max);
312 void GetLZLimits(
double &z_min,
double &z_max);
314 void GetRZlimits(
double &z_min,
double &z_max);
357 ParamsInfoAr *Params;
Class, describing bodies bound.
Definition: vel2dmod_service.hpp:23
Bound(double *xx, double *zz, int nn, bool *flag, double rc, double sp, double *xx1=NULL, double *zz1=NULL, int nn1=0)
Definition: spline.hpp:24
double GetV0(double x, WAVE_TYPE wt)
Class, describing the geological body.
Definition: vel2dmod_service.hpp:268
void SetConstParams(double vp, double vs, double kzp, double kzs, double den, double an_kp=1, double an_ks=1, double R=1)
int getApproxType()
Definition: vel2dmod_service.hpp:54
int bNum1
Definition: vel2dmod_service.hpp:93
double an_ks
Definition: vel2dmod_service.hpp:362
double GetRParam()
Definition: vel2dmod_service.hpp:213
void GetBodyBrd(int &num, int *&brds)
bool filled
Definition: vel2dmod_service.hpp:97
double GetCKz(WAVE_TYPE wt)
double GetAnKS()
Definition: vel2dmod_service.hpp:210
Class, containing bodies parameters.
Definition: vel2dmod_service.hpp:144
int * bounds
Definition: vel2dmod_service.hpp:321
Definition: vel2dmod_service.hpp:345
BodyParam * Param
Definition: vel2dmod_service.hpp:316
bool BotBorder(double x, double &z)
bool paramsConst
Definition: vel2dmod_service.hpp:186
Definition: objectar.hpp:57
Definition: vel2dmod_service.hpp:355
bool BoundInt(double x1, double z1, double x2, double z2, double eps, double &resultX, double &resultZ, bool flag=true, bool finitLine=true, int *nn=NULL)
Definition: vel2dmod_ldb.hpp:16
Definition: parspline.hpp:14
void SetAnKS(double an_ks)
Definition: vel2dmod_service.hpp:219
bool TopBorder(double x, double &z)
int boundNum
Definition: vel2dmod_service.hpp:320
double GetKx(double x, WAVE_TYPE wt)
bool * n_direct
Definition: vel2dmod_service.hpp:328
void AddBoundPtr(Bound *pB)
void GetEndPoints(double &x1, double &z1, double &x2, double &z2)
Definition: objectar.hpp:55
void SetParams(int pNum, double *x, double *vp, double *vs, double *kzp, double *kzs, double *den, double an_kp=1, double an_ks=1, double R=1)
int * bPos
Definition: vel2dmod_service.hpp:322
double R
Definition: vel2dmod_service.hpp:363
int num
Definition: vel2dmod_service.hpp:319
bool filled
Definition: vel2dmod_service.hpp:183
bool BodyBorder(int bNum, double x, double &z)
BoundsAr Bounds
Definition: vel2dmod_service.hpp:336
void SetAnKP(double an_kp)
Definition: vel2dmod_service.hpp:216
void SetRParam(double R)
Definition: vel2dmod_service.hpp:222
void RebuildParams(int vMN, double *new_x, double *new_vp, double *new_vs, double *new_kzp, double *new_kzs, double *new_den)
double GetAnKP()
Definition: vel2dmod_service.hpp:207
int num
Definition: vel2dmod_service.hpp:90
Structure, describing bound segment (a part of bound between the special points)
Definition: vel2dmod_service.hpp:12