SkillAgentSearch skills...

AFTAN

Seismic Surface Wave Dispersion Measurements with Automatic Frequency Time Analysis

Install / Use

/learn @NoiseCIEI/AFTAN
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

AFTAN (Automatic Frequency Time Analysis)

INTRODUCTION

The aftan Release 1.1 package provides instruments for Automatic Frequency_Time Analysis (AFTAN) of cros-correlogram of the ambient seismic noise [1,2]. The output of programs based on this package are group and phase velocities of fundamental Rayleigh and Love modes which can be used in surface wave tomographic studies (e.g.,[6],[7]). The AFTAN is a modification of previously developed and widely used FTAN (e.g., [3],[4],[5]. The AFTAN converts time series of cross-correlation functions into frequency-time diagramms of signal power as a function of frequency and group time by means of the multiple narrow-band filtering. Then it provides automatic measurements of group and phase velocities together with estimates of signal/noise ratios of these measurements.

CONTENTS

  1. PACKAGE CONTENTS

  2. INSTALLATION

  3. SYSTEM REQUIREMENTS

  4. TEST ISTALLATION

  5. DESCRIPTION OF THE AFTAN-1.1 PACKAGE REFERENCES

  6. PACKAGE CONTENTS

The contents of the package are as follows: README this file bin contains two 64-bit executable programs aftan_c_test and aftan_f_test,OS RHEL 5.9 src contains program source codes TEST1 contains precomputed example test TEST2 directory to run your own installation

  1. INSTALLATION ================ Use the gunzip and tar command to extract distribution contents.

    ...> gunzip aftan-1.1.tgz ...> tar xvf aftan-1.1.tar

This will yield a top level directory named aftan-1.1 with an executable, along with other miscellaneous files. Go to ancc-1.1/src directory and recompile, if necessary, all programs. To do that execute the following coomands ...> make clean ...> make ...> make install

The resulting binary modules aftan_c_test and aftan_f_test will be installed under aftan-1.1/bin directory. In case of problems update Makefile properly. The gftan-1.1/bin directory originally includes binary modules compiled by gcc/gfortran v4.1.2 compiler under RHEL 5.9 (RedHat Enterprise Linux 5.9) Operational System.

The package required installation of the fftw libraries version 3.2.4 or higher for the Fast Fourier Transformation fftw's libraries must be installed in system under root user for better performance. See an example of run in the directory TEST1 and try your own run in directory TEST2.

  1. SYSTEM REQUIREMENTS

    • 64-bit or 32-bit platforms
    • Software: fftw v.3.2.4 or higher
    • Linux Operation System, currently tested on RHEL 5.x, 32 and 64 bit version under gcc/gfortran v4.1.2
    • SUN OS Solaris currently tested on Solaris rel.5.7/5.8/5.10 cc/f77 WorkShop Compilers 4.2
    • Mac X currently tested on OS 10.7 (Snow Leopard), gcc/gfortran v4.6,fftw3.2.2
    • have to work under other Linux OS and compilers with minor changes.
  2. TEST INSTALLATION

    Go to aftan-1.1/TEST1 and after aftan-1.1/TEST2 and follow README files.

  3. DESCRIPTION OF THE AFTAN-1.1 PACKAGE

The atan-1.1 package consists of the set of FORTAN subroutines and C functions. Based on this set, it is possible to write separate programs or imbed into existing software, which is required FTAN analysis. The atan-1.1 package offers two programs written on C and FORTRAN language, that used as testing programs, and might be used on constant base to permorm automatic FTAN analysys for the huge scope of cross-correlation functions settled in IRIS Product [1]. Thus, aftan_c_test and aftan_f_test are those testing programs for aftan-1.1 package. Both programs must produce the same result. The aftan_c_test program includes main module driver_c.c written on C language, which is an example of C interface to aftan-1.1 package. The aftan_f_test program includes main module driver.f, which is the program interface to the aftan-1.1 package written on FORTRAN language. You may use any programs mentioned above as for testing purposes or on regular base. Also, you can modify or create your own version of the main programs driver_c.c or driver.f.

5.1 Here we briefly describe the aftan_c_test program for C-interface.

SYNOPSIS aftan_c_test param_file DESCRIPTION While starting, aftan_c_test reads line by line the parameter file pointed by path param_file. Each line includes subset of the most important parameters and path to cross-correlation SAC file. The rest parameters must be defined in the driver_c.c module. For example, some line look like

-1.0 1.5 5.0 4.0 30.0 20.0 1.0 1.0 0.2 1.0 ctest/COR_TA.M14A_TA.M17A.SAC

The line includes values for variables described later in section 5.2.2,
namely, piover4,vmin,vmax,tmin,tmax,tresh,ffact,taperl,snr,fmatch
and path name to SAC binary file in form of path_dir/file_name.
The directory path_dir may be individual for each line that we
call simply "data dir".
NOTE: SAC file name must have the extension ".SAC"  .

The other parameters  sac,nfin,npoints,perc,ffact are initialized
in the module driver_c.c.
For each line of the parameter file aftan_c_test does the following
things:
a) reads predicted phase velocity file from the data directory,
   if it exists the name has the form "file_name_PHP".
   For example, in our case, the predicted group velocity file name is
   COR_TA.M14A_TA.M17A.SAC_PHP
   NOTE: The ..._PHP file should not be very accurate. The main goal of
         this file to choose the branch of phase velocity. AFTAN alogirithm
         try to estimate right branch at single period only, namely,
         at maximal period of period range. The good approximation
         could be PREM 1D model without water layer or some phase
         dispersion cirve obtained from average regional share velocity
         model.
b) reads cross-correlation from SAC file by reading data_ function (C) ???
c) performs basic FTAN  by aftanpg_ subroutine (FORTRAN)
d) writes results on  screen and into file system inside the data directory
   by printres_ function (C)
e) makes match-filtering of FTAN diagram by aftanipg_ subroutine (FORTRAN)
f) writes results on  screen and into file system insides data directory
   by printres_ function (C)

INPUT DATA aftan_c_test reads predicted phase velocity (ASCII plane file), if it exists, from data directory. It should have the name form of "file_name_PHP". The file_name_PHP includes the following lines:

Line1: Any text size of up to 80 characters
Lines2-n: per, pha_vel      Format: Unformatted
where, per is period in sec, and pha_vel is predicted phase
velocity in km/s

OUTPUT DATA

 aftan_c_test outputs in data dir three type of ASCII flat files.
 If path to SAC file is "XXXX", then aftan_c_test creates the following
 resulting files for base FTAN:
 XXXX01_AMP, XXXX01_DISP.0, XXXX01_DISP.1
 and resulting files for match-filtered FTAN:
 XXXX02_AMP, XXXX02_DISP.0, XXXX02_DISP.1

5.1.1 Format of XXXX01_AMP and XXXX02_AMP xyz grid files The files XXXX01_AMP and XXXX02_AMP are envelop FTAN diagrams and have the same formats. The number of lines in files is nrowncol+1, see section 5.2.2. Line 1: nrow,ncol,dt,delta where, nrow - number of periods ncol - number of times dt - time step in sec delta - epicentral distance in km Lines 2-nrowncol+1: n, tamp, amp where, n is the reference number to the line in the file XXXX01_DISP.0 for XXXX01_AMP or to the line in the file XXXX02_DISP.0 for XXXX02_AMP . tamp, is a time of FTAN diagram in sec, and amp if FTAN diagram amplitude in Db, max value for each reference number n is 100 Db.

5.1.2 Format of XXXX01_DISP.0 and XXXX02_DISP.0 files. The file XXXX01_DISP.0 includes the complete results of the base FTAN and XXXX02_DISP.0 include complete results of the match filtering FTAN. The number of lines in files is nfout1 for XXXX01_DISP.0 file, and nfout2 for XXXX02_DISP.0 file. Each line of file has 8 fields: nf, cper, oper, gvel, pvel, ampl, dfunc, snr nf - filter number, starting from 1 by 1 cper - central periods, s oper - observed periods, s gvel - group velocity, km/s pvel - phase velocity, km/s or phase if nphpr=0, rad ampl - amplitudes, Db dfunc - discrimination function, second derivative of group velocity by frequence snr - signal/noise ratio, Db

5.1.3 Format of XXXX01_DISP.1 and XXXX02_DISP.1 files. The file XXXX01_DISP.1 includes the cleaned results of the base FTAN and XXXX02_DISP.1 include cleaned results of the match filtering FTAN. The number of lines in files is nfout1 for XXXX01_DISP.1 file, and nfout2 for XXXX02_DISP.1 file. Each line of file has 7 fields: nf, cper, oper, gvel, pvel, ampl, snr nf - filter number, starting from 1 by 1 cper - central periods, s oper - observed periods, s gvel - group velocity, km/s pvel - phase velocity, km/s or phase if nphpr=0, rad ampl - amplitudes, Db snr - signal/noise ratio, Db

5.2 Here we briefly describe the aftan_f_test program for FORTRAN interface:

SYNOPSIS aftan_f_test param_file

The most important subroutine/functions of the aftan package are

5.2.1 C function readdata_ , from module misc.c

NAME readdata_ reads symmetric cross-correlation from SAC file SYNOPSIS void readdata_(int *sac,char *name,int *n,double *dt,double *delta, double *t0,float sei[32768], int *ierr); DESCRIPTION Input formal arguments: sac - should be 1 all the time name - path to the SAC file Output formal arguments: n - length of cross-correlation function dt - sampling step, in sec delta - distance between pair of

View on GitHub
GitHub Stars15
CategoryDevelopment
Updated10mo ago
Forks16

Languages

PostScript

Security Score

87/100

Audited on Jun 4, 2025

No findings