acd.hh

Go to the documentation of this file.
00001 #ifndef __IWAVE_ACD_INFO
00002 #define __IWAVE_ACD_INFO
00003 
00004 //#include "iwinfo.hh"
00005 #include "iwave.h"
00006 #include "except.hh"
00007 #include "acd_gfdm.h"
00008 #include "acd_gfdm2.h"
00009 
00010 #define OLD
00011 
00012 /*
00013   int acd_modelinit(PARARRAY *pars,
00014   FILE *stream,
00015   grid const & g,
00016   ireal dt,
00017   std::vector<std::string> & active,
00018   void ** specs);
00019 */
00020 int acd_modelinit(PARARRAY pars,
00021           FILE *stream,
00022           IMODEL & model);
00023 
00024 void acd_modeldest(void ** specs);
00025 
00026 int acd_timegrid(PARARRAY * pars, 
00027          FILE * stream, 
00028          grid const & g, 
00029          ireal & dt,
00030          ireal & rhs);
00031 
00032 void acd_timestep(std::vector<RDOM *> dom, 
00033           bool fwd, 
00034           int iv, 
00035           void* fdpars);
00036 
00037 int acd_create_sten(void *, 
00038             FILE *, 
00039             int, 
00040             IPNT[RDOM_MAX_NARR], 
00041             STENCIL *);
00042 
00043 void acd_check(RDOM * dom,
00044            void * specs,
00045            FILE * stream);
00046 
00047 void acd_loop_refine(int const * gmin, int const * gmax,
00048              float tmax, int input,
00049              FILE * stream, void * specs);
00050 
00051 typedef struct {
00052   ireal dt;      /* time step - copied from IMODEL.tsinfo */
00053   RPNT lam;      /* courant params */
00054   int k;         /* scheme half-order */
00055   int ndim;      /* dimension, copied from IMODEL.grid */
00056   IPNT lbc;      /* flag left boundary conditions */
00057   IPNT rbc;      /* flag right boundary conditions */
00058   // FD coefficients - old style
00059   ireal c0;
00060   RPNT c1;
00061   RPNT c2;
00062   RPNT c3; 
00063   RPNT c4;
00064   // FD coefficients - new style
00065   ireal ** c;
00066   // workspace for inner loops
00067   ireal * lap;
00068   ireal * lap1;
00069   ireal * lap2;
00070   ireal * lap3;
00071   // number of samples in each axis
00072   IPNT n;
00073   // axis origins in local indices
00074   IPNT z;
00075   // axis steps
00076   RPNT dx;
00077   // number of extended axes
00078   int next;
00079   // physical background flag
00080   int pbg;
00081   // test params
00082   ireal cmax;
00083   ireal cmin;
00084   // additional loop limit workspace
00085   float looprad;
00086   IPNT rs; // receiver min index - set to s0 initially
00087   IPNT re; // receiver max index - set to e0 initially
00088   IPNT ss; // source min index - set to s0 initially
00089   IPNT se; // source max index - set to e0 initially
00090   IPNT dyns; // min loop limits - based on tmax, cmax, dx, source and receiver boxes
00091   IPNT dyne; // min loop limits - based on tmax, cmax, dx, source and receiver boxes
00092 } ACD_TS_PARS;  
00093 
00094 /*
00095   Indices of arrays - const density acoustic. 
00096   D_UC  :  current acoustic potential
00097   D_UP  :  past acoustic potential
00098   D_CSQ :  square velocity (multiplier of Laplacian)
00099 */
00100 #define D_UC  1
00101 #define D_UP  2
00102 #define D_CSQ 0
00103 
00104 /* default fraction of max time step */
00105 #define CFL_DEF 0.95
00106 
00107 #endif
00108 
00109 

Generated on 5 Jan 2017 for IWAVEACD by  doxygen 1.4.7