globvar.h 3.79 KB
Newer Older
Tilman Steinweg's avatar
Tilman Steinweg committed
1
/*------------------------------------------------------------------------
2
 *   globvar.h - global variables of viscoelastic FD programs
Tilman Steinweg's avatar
Tilman Steinweg committed
3 4 5 6 7 8 9 10
 *
 *  ----------------------------------------------------------------------*/

/* definition of global variables used in the finite difference programs*/
/* generally, for the names of the global variables uppercase letters are used */

/* Add new variables also in exchange_par.c and read_par_json.c */

11
float XS, YS, DH, TIME, DT, TS, VPPML, PLANE_WAVE_DEPTH, PHI;
Tilman Steinweg's avatar
Tilman Steinweg committed
12 13 14 15 16
float TSNAP1, TSNAP2, TSNAPINC, *FL, TAU, F_REF;
float XREC1, XREC2, YREC1, YREC2;
float REC_ARRAY_DEPTH, REC_ARRAY_DIST;
float REFREC[4]={0.0, 0.0, 0.0, 0.0}, FPML;
int   SEISMO, NDT, NGEOPH, NSRC=1, SEIS_FORMAT, FREE_SURF, READMOD, READREC, SRCREC, FW=0;
17
int   NX, NY, NT, SOURCE_SHAPE,SOURCE_SHAPE_SH, SOURCE_TYPE, SNAP, SNAP_FORMAT, REC_ARRAY, RUN_MULTIPLE_SHOTS, NTRG;
18
int   L, BOUNDARY, DC, DRX, NXG, NYG, IDX, IDY, FDORDER, MAXRELERROR;
19
char  SNAP_FILE[STRING_SIZE], SOURCE_FILE[STRING_SIZE], SIGNAL_FILE[STRING_SIZE], SIGNAL_FILE_SH[STRING_SIZE];
20
char  MFILE[STRING_SIZE], REC_FILE[STRING_SIZE];
21 22
char  LOG_FILE[STRING_SIZE];
char  SEIS_FILE[STRING_SIZE];
Tilman Steinweg's avatar
Tilman Steinweg committed
23 24
FILE *FP;

25
int VERBOSE;
Tilman Steinweg's avatar
Tilman Steinweg committed
26 27 28 29 30 31 32 33 34
/* Mpi-variables */
int   NP, NPSP, NPROC, NPROCX, NPROCY, MYID, IENDX, IENDY;
int   POS[3], INDEX[5];     
const int TAG1=1,TAG2=2, TAG3=3, TAG4=4, TAG5=5,TAG6=6; 

/* spatial adaptive Code variables*/
int   check_id, cfgt_id, cfgt, jumpid;
float DH1;

Florian Wittkamp's avatar
Florian Wittkamp committed
35
/* TDFWI Code IFOS_elastic*/
Tilman Steinweg's avatar
Tilman Steinweg committed
36
char JACOBIAN[STRING_SIZE], DATA_DIR[STRING_SIZE], FREQ_FILE[STRING_SIZE];
37 38 39

int USE_WORKFLOW;
char FILE_WORKFLOW[STRING_SIZE];
40
int WORKFLOW_STAGE;
41

Tilman Steinweg's avatar
Tilman Steinweg committed
42 43
int TAPER, TAPERLENGTH, INVTYPE;
int GRADT1,GRADT2,GRADT3,GRADT4;
44
int ITERMAX, REC1, REC2, PARAMETERIZATION, FORWARD_ONLY, ADJOINT_TYPE;
Florian Wittkamp's avatar
Florian Wittkamp committed
45 46
int  GRAD_METHOD;
float TSHIFT_back;
Tilman Steinweg's avatar
Tilman Steinweg committed
47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70
int MODEL_FILTER, FILT_SIZE;
float EPSILON, MUN, EPSILON_u, EPSILON_rho;

int TESTSHOT_START, TESTSHOT_END, TESTSHOT_INCR, NO_OF_TESTSHOTS; 
int SWS_TAPER_GRAD_VERT, SWS_TAPER_GRAD_HOR, SWS_TAPER_GRAD_SOURCES, SWS_TAPER_CIRCULAR_PER_SHOT, SRTSHAPE, FILTSIZE;
int SWS_TAPER_FILE, SWS_TAPER_FILE_PER_SHOT;
float SRTRADIUS;
char TAPER_FILE_NAME[STRING_SIZE], TAPER_FILE_NAME_U[STRING_SIZE], TAPER_FILE_NAME_RHO[STRING_SIZE];

int SPATFILTER, SPAT_FILT_SIZE, SPAT_FILT_1, SPAT_FILT_ITER;

int INV_RHO_ITER, INV_VS_ITER, INV_VP_ITER;

int MIN_ITER;

char INV_MODELFILE[STRING_SIZE];
int nfstart, nf;

int nfstart_jac, nf_jac;

float VPUPPERLIM, VPLOWERLIM, VSUPPERLIM, VSLOWERLIM, RHOUPPERLIM, RHOLOWERLIM;

float npower, k_max_PML;

Florian Wittkamp's avatar
Florian Wittkamp committed
71 72
int TAPER_STF;
int INV_STF, N_STF, N_STF_START,TW_IND;
Tilman Steinweg's avatar
Tilman Steinweg committed
73 74 75
char PARA[STRING_SIZE];

int TIME_FILT, ORDER, ZERO_PHASE;
76
int WRITE_FILTERED_DATA;
Tilman Steinweg's avatar
Tilman Steinweg committed
77 78 79 80 81 82 83 84 85
float FC_START, FC_END, FC_INCR, F_HP;

int LNORM, DTINV;

int STEPMAX;
float EPS_SCALE, SCALEFAC;

float PRO;

86
int EPRECOND;
87
float EPSILON_WE,EPSILON_WE_SH;
88 89
int EPRECOND_ITER;
int EPRECOND_PER_SHOT;
90
int EPRECOND_PER_SHOT_SH;
91 92 93 94 95 96 97 98

int N_LBFGS;
int LBFGS_SURFACE;
int LBFGS_STEP_LENGTH;

int WOLFE_CONDITION=0;
int WOLFE_NUM_TEST=5;
int WOLFE_TRY_OLD_STEPLENGTH=1;
Florian Wittkamp's avatar
Florian Wittkamp committed
99 100
float WOLFE_C1_SL;
float WOLFE_C2_SL;
101

Tilman Steinweg's avatar
Tilman Steinweg committed
102 103 104 105
/* trace kill variables */
int TRKILL;
char TRKILL_FILE[STRING_SIZE];

106 107 108 109
int TRKILL_OFFSET;
float TRKILL_OFFSET_LOWER;
float TRKILL_OFFSET_UPPER;

Tilman Steinweg's avatar
Tilman Steinweg committed
110 111 112 113
/* trace kill STF variables */
int TRKILL_STF;
char TRKILL_FILE_STF[STRING_SIZE];

114 115 116 117
int TRKILL_STF_OFFSET;
float TRKILL_STF_OFFSET_LOWER;
float TRKILL_STF_OFFSET_UPPER;

118
int TIMEWIN, NORMALIZE;
Tilman Steinweg's avatar
Tilman Steinweg committed
119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138
float TWLENGTH_PLUS, TWLENGTH_MINUS, GAMMA;
char PICKS_FILE[STRING_SIZE];
char MISFIT_LOG_FILE[STRING_SIZE]; 

int GRAD_FILTER, FILT_SIZE_GRAD;

int VELOCITY;

float WATERLEVEL_LNORM8;

float VP_VS_RATIO;

int S;

float S_VP, S_VS, S_RHO;

int GRAD_FILT_WAVELENGTH;
float A;

int ACOUSTIC;
139 140 141 142 143 144 145 146 147

int VERBOSE;

int WAVETYPE;
int JOINT_INVERSION_PSV_SH_TYPE;

float JOINT_INVERSION_PSV_SH_ALPHA_VS;
float JOINT_INVERSION_PSV_SH_ALPHA_RHO;
int SNAPSHOT_START,SNAPSHOT_END,SNAPSHOT_INCR;