Home ] Up ]

Windows Application For Listing Earthquakes In and Around India

Data Arrangement

Using The Application

Output and Input files

Selecting Events

Applications Starting Window

Selections Menu 

Display of Listed Events

Event Selection Dialog Box

Rebuilding The Application

Building On the command line

Setting The Environment Variables

VCVARS32.BAT File 

Building In Developer Studio

 

The application allows the user to list date, times and hypocentral data (latitude, longitude and depths) along with the magnitude. Data up to the year 1964 have been catalogued from various catalogues in India and published literature. After 1964 these are mostly based on the USGS data base. The data cover latitudes between 5 and 40 degrees North and longitude 65 and 95 degrees East. However, these limits might have varied, and in case of the area under consideration falls towards the boundaries, it is advised that the original data base is consulted again.

Data Arrangement

Earthquake Data are arranged in convenient size files. These files have been named :

EQTO64.DAT

EQ65_76.DAT

EQ77_89.DAT                 download these files

EQ90_99.DAT

EQ00_05.DAT

 The names of the files are indicative of what the files contain. With passage of time more and more events will be added to the list. A user can add  additional data to the list by downloading from the USGS database:

http://wwwneic.cr.usgs.gov/neis/epic/epic_rect.html

The downloaded data will need some editing for compatibility with the EQ ASCII files.

Using The Application

The application is named Evt.EXE. After Evt is typed on the  command line  the applications Window will open as shown below:

Applications Starting Window

The selection Menu is as shown below

 

Output and Input Files

After cliking the Selections Menu, the user will be presented a dialog box for  selecting the  output file name. The user has the choice to either accept the default output file name, or enter a chosen file name.

After the output file is selected the earthquake data file (or input file) is to be selected. After clicking the input file item on the Selections menu a dialog box appears along with a list box listing all .dat files in the directory. One of these can be selected by highlighting it. It is necessary to keep the data files in the same directory where the .exe file is located.

Selecting Events

Events are to be selected for a certain range of locations, time or magnitude then the user may select "Selection Events" on the Selections menu. This will present a dialog box shown below:

Event Selection Dialog Box

The selection values are read as integers, hence the multiplying factors are given. No decimals are accepted by the application. After the user clicks OK on this dialog box, the evnts are displayed in a scroll window as shown below:

Display of Listed Events

These events are also listed in the output file, which can be copied, printed and even edited.

Rebuilding The Application

 

   The source code and the make file of the application are included in the download of the application. Though the scope of the application is limited only to listing and selecting events, and modifications are unlikely to become the need in this case, an important objective of the inclusion of this code is to catalogue the window procedures: the basic window parameters, input/output and scrolling the window. In case a user wants to experiment with any of the features the application can be modified and rebuilt. It can be done either on the command line or in the Microsofts Developer Studio.

 

Building On the command line

 

For building the application the application on the command line the make file is used. The application is built by typing

 

NMAKE   EVT.MAKE

 

on the command line. However, before building the application in this manner, the various variables of the MAK file, and the information on the paths of the various libraries, need to be added to the computing environment. The variables are specified by including these to the autoexecute file by adding the following statements.

 

Setting The Environment Variables

 

REM -------------------------------------------------------------------------

REM  MSC.BAT -- Set up environment for Microsoft C/C++ 5.0 NMAKE

REM -------------------------------------------------------------------------

SET CC=cl

SET CFLAGS=-c -DSTRICT -G3 -Ow -W3 -Zp -Tp

SET CFLAGSMT=-c -DSTRICT -G3 -MT -Ow -W3 -Zp -Tp

SET LINKER=link

SET GUIFLAGS=-SUBSYSTEM:windows

SET DLLFLAGS=-SUBSYSTEM:windows -DLL

SET GUILIBS=-DEFAULTLIB:user32.lib gdi32.lib winmm.lib comdlg32.lib comctl32.lib

SET RC=rc

SET RCVARS=-r -DWIN32

 

(For mor details on using the NMAKE Application refer to "Programming Windows 95 by Charles Petzold, Microsoft Press)

 

The paths to the various libraries of the Developer Studio are listed in the file vcvars32.bat, which is automaticaaly  generated while installing the Visual C++. The contents of the vcvars32.bat on this installation are shown below:

 

VCVARS32.BAT File

 

@echo off
rem
rem Root of Visual Developer Studio installed files.
rem
set MSDevDir=C:\Program Files\DevStudio\SharedIDE

rem
rem Root of Visual C++ installed files.
rem
set MSVCDir=C:\Program Files\DevStudio\VC

rem
rem Root of Visual C++ files on cd-rom.
rem Remove "set vcsource=" if you don't want include cdrom in Visual C++ environment.
rem
set vcsource=F:\DEVSTUDIO

rem
rem VcOsDir is used to help create either a Windows 95 or Windows NT specific path.
rem
set VcOsDir=WIN95
if "%OS%" == "Windows_NT" set VcOsDir=WINNT

rem
echo Setting environment for using Microsoft Visual C++ tools.
rem
if "%vcsource%" == "" goto main
rem
rem Include cdrom files in environment.
rem
if "%OS%" == "Windows_NT" set PATH=%PATH%;%vcsource%\VC\BIN;%vcsource%\VC\BIN\%VcOsDir%
if "%OS%" == "" set PATH=%PATH%;"%vcsource%\VC\BIN";"%vcsource%\VC\BIN\%VcOsDir%"
set INCLUDE=%INCLUDE%;%vcsource%\VC\INCLUDE;%vcsource%\VC\MFC\INCLUDE;%vcsource%\VC\ATL\INCLUDE
set LIB=%LIB%;%vcsource%\VC\LIB;%vcsource%\VC\MFC\LIB
set vcsource=

:main
if "%OS%" == "Windows_NT" set PATH=%MSDevDir%\BIN;%MSVCDir%\BIN;%MSVCDir%\BIN\%VcOsDir%;%PATH%
if "%OS%" == "" set PATH="%MSDevDir%\BIN;%MSVCDir%\BIN";"%MSVCDir%\BIN\%VcOsDir%";%PATH%
set INCLUDE=%MSVCDir%\INCLUDE;%MSVCDir%\MFC\INCLUDE;%MSVCDir%\ATL\INCLUDE;%INCLUDE%
set LIB=%MSVCDir%\LIB;%MSVCDir%\MFC\LIB;%LIB%

set VcOsDir=

Building In Developer Studio

 

To rebuild the application in the Microsoft's Developer Studio (in Visual C++) make a new project named Evt, and select Evt.MAK for the make file. Copy the source file, the RC file and the make file (and of course the data files) in the Evt directory, and build the application.