Skip to content

Basin Query

Philip Maechling edited this page Sep 1, 2022 · 2 revisions

UCVM provides utility programs that will search for depth to a specific Vs value for one or more points in a velocity model, and return the depth found as "basin depth" for that point.

Based on user feedback, the basin query method was modified to return information about velocity inversions. That is, the basin depth returned includes the first occurance of the specific Vs, but if the specified value is found deeper, that depth (known as a second crossing) is also returned.

An example is shown below:

The algorithm implemented in the basin_query code is shown below (as psuedo code):

A crossing is defined when Vs crosses the threshold of value given on commane line (e.g. 2500m/s) from low to high

the output format:
 lon lat first-crossing, 
           if none, then return 0
         second-crossing, 
           if none, then return first-crossing, if none, then return 0
         last-crossing,  
           if none, then return scecond-crossing, 
             if none, then return first crossing, if none, then return 0 

An example showing how the UCVM basin_query program is called:

basin_query -f $UCVM_INSTALL_PATH/conf/ucvm.conf -m cvmsi -v 2500 < $UCVM_INSTALL_PATH/tests/inputs/test_latlonsonly.txt

This query returns
 -118.0000    34.0000   1940.000   4660.000   4660.000
 -118.5000    34.5000    320.000    320.000    320.000k

Another example showing the contents of the input file:

%more in.txt
-119.537 35.55
-118.67 34.50

%basin_query -f $UCVM_INSTALL_PATH/conf/ucvm.conf -m cvmsh -v 2500 < in.txt

This query returns
-119.5370    35.5500      0.000      0.000      0.000
-118.6700    34.5000   2300.000   2300.000   2300.000


%basin_query -f $UCVM_INSTALL_PATH/conf/ucvm.conf -m cvmsi -v 2500 < in.txt

This query returns
-119.5370    35.5500   7400.000   7400.000   7400.000
-118.6700    34.5000    320.000   4780.000   4780.000
Clone this wiki locally