![]() 図1. 3点法の手順。 後述の例題において\(k=9.0\) km/sとした場合の結果を示す。 Fig. 1. Procedures of the 3-point method, from the example below with \(k=9.0\) km/s. |
| 引数 Argument |
与える値 Quantity to be given | ||||||||||||||
| 第1引数 1st argument |
入力データファイル名(テキストファイルであり拡張子は自由)。 The name of an input data file (a text file with an arbitrary extension). このファイルには使用する3観測点の座標とP波・S波到着時刻の読み取り値を 以下の書式で与える。 列の区切りにはタブを使用する。 空行と各行の「#」から後の部分はコメントとして無視されるので自由に挿入できる。 In this file, write the coordinates of three stations and the picked P- and S-wave arrival times at these stations with the following format. Use tabs to separate the columns. Empty lines and parts after # in each line can be inserted freely because they are ignored as comments.
| ||||||||||||||
| 第2引数 2nd argument |
出力ディレクトリ名。 The output directory name. |
| パラメータ名 Parameter name |
意味 Meaning |
可能なパラメータ値 Allowed parameter values |
デフォルト値 Default value |
| k | 仮定する\(k\)の値(km/s)。 The assumed \(k\) value (km/s). |
正の実数。 A positive real number. |
8.0 |
| refN | 直交座標系への変換の基準点の緯度(度単位または度:分:秒表記)。 The latitude (in degrees or degree:minute:second format) of the reference point for a conversion to a cartesian coordinate system. |
-90.0以上+90.0以下の実数またはその度:分:秒表記。 A real number greater than or equal to -90.0 and less than or equal to +90.0, or its degree:minute:second representation. |
3観測点の緯度の平均値。 The average of the latitudes of the three stations. |
| refE | 直交座標系への変換の基準点の経度(度単位または度:分:秒表記)。 The longitude (in degrees or degree:minute:second format) of the reference point for a conversion to a cartesian coordinate system. |
-180.0以上+180.0以下の実数またはその度:分:秒表記。 A real number greater than or equal to -180.0 and less than or equal to +180.0, or its degree:minute:second representation. |
3観測点の経度の平均値。 The average of the longitudes of the three stations. |
![]() 図2. 震源が求まらないケース。 後述の例題において\(k=7.0\) km/sとした場合の結果を示す。 Fig. 2. A case where the hypocenter is not determined, from the example below with \(k=7.0\) km/s. |
|
NU.STN_A[TAB]35.12345[TAB]136.78901[TAB]0.0[TAB]23.45[TAB]30.03 NU.STN_B[TAB]34.98765[TAB]137.53197[TAB]0.0[TAB]24.68[TAB]32.10 NU.STN_C[TAB]34.34343[TAB]136.54321[TAB]0.0[TAB]25.52[TAB]33.33 |
|
for((k10=70;k10<=90;k10++)) do k=`echo $k10 | awk '{ printf("%.1f",$1/10.0) }'` simulate_hypo_3points sample_data.dat result_k$k --k=$k done |
|
latitude=34.736355 longitude=136.997982 depth=36.037779 |
|
137.438760[TAB]35.122597 137.438716[TAB]35.131914 137.438474[TAB]35.141229 137.438035[TAB]35.150538 137.437397[TAB]35.159841 … |
|
138.263337[TAB]34.981970 138.263392[TAB]34.992475 138.263225[TAB]35.002979 138.262836[TAB]35.013479 138.262223[TAB]35.023972 … |
|
137.307213[TAB]34.343614 137.307143[TAB]34.354674 137.306840[TAB]34.365731 137.306304[TAB]34.376783 137.305536[TAB]34.387824 … |
|
137.212010[TAB]35.529398 137.202174[TAB]35.531116 137.192302[TAB]35.532693 137.182398[TAB]35.534128 137.172465[TAB]35.535420 … |
|
136.964132[TAB]34.609468 137.212010[TAB]35.529398 > 136.195281[TAB]34.908062 137.178678[TAB]34.696871 > 136.803027[TAB]34.939616 137.302481[TAB]34.416241 > 136.997982[TAB]34.736355 136.613347[TAB]34.805726 |
|
hypocenter not determined |
|
137.294374[TAB]35.123087 137.294328[TAB]35.130334 137.294127[TAB]35.137579 137.293772[TAB]35.144819 137.293263[TAB]35.152054 … |
|
138.100830[TAB]34.983613 138.100857[TAB]34.991784 138.100711[TAB]34.999953 138.100392[TAB]35.008120 138.099899[TAB]35.016281 … |
|
137.137435[TAB]34.343985 137.137363[TAB]34.352587 137.137110[TAB]34.361187 137.136676[TAB]34.369782 137.136062[TAB]34.378369 … |
|
for((k10=70;k10<=90;k10++)) do k=`echo $k10 | awk '{ printf("%.1f",$1/10.0) }'` depth=`grep depth result_k$k/hypo.dat | cut -f2 --delimiter='='` if [ "$depth" != '' ] then echo $k $depth fi done |
|
7.7 8.917243 7.8 12.927324 7.9 15.992432 8.0 18.586027 8.1 20.884441 8.2 22.976356 8.3 24.913773 8.4 26.730242 8.5 28.448878 8.6 30.086391 8.7 31.655316 8.8 33.165333 8.9 34.624097 9.0 36.037779 |
|
#! /bin/bash -u # 1つの観測点について観測点位置と観測点を中心とする円をプロットする関数 # A function to plot the location of a station and a circle centered on the station function TF_plot_for_station () { # 観測点位置をプロット # Plot a station location sed -n ${line_currentStation}p $data_file | awk '{ printf("%f\t%f\n",$3,$2) }' | gmt plot $GMT_R $GMT_J $GMT_XY -St0.5 -G${color_currentStation} # 観測点コードをプロット # Plot a station code sed -n ${line_currentStation}p $data_file | awk '{ printf("%f\t%f\t%s\n",$3,$2-0.04,$1) }' | gmt text $GMT_R $GMT_J $GMT_XY -F+f10p,,${color_currentStation}+jCT # 円の座標データのファイル名を取得 # Survey a file name for the coordinates of a circle station=`sed -n ${line_currentStation}p $data_file | awk '{ print $1 }'` inputfile=circle${line_currentStation}_${station}.dat # 円をプロット # Plot a circle gmt plot $inputfile $GMT_R $GMT_J $GMT_XY -W0.4,${color_currentStation} } # プロットする経度範囲と座標目盛間隔の設定 # Set the coordinate range and tick interval of the longitude axis Emin=135.5 Emax=138.5 Etics=1.0 # プロットする緯度範囲と座標目盛間隔の設定 # Set the coordinate range and tick interval of the latitude axis Nmin=33.5 Nmax=36.0 Ntics=1.0 # 紙面上での図の左下の位置(紙の左下端から、cm) # Location of the bottom left corner of the map on a paper (measured from the bottom left corner of the paper, cm) x0=2.0 y0=2.0 # 各観測点に対して使用する色 # The color used for each station color_station1='255/0/0' color_station2='0/160/0' color_station3='0/0/255' # 震源の深さを求めるための半円と線に対して使用する色 # The color used for a half circle and a line to determine hypocenter depth color_depth='160/0/160' # 共通オプション # Common options GMT_R="-R${Emin}/${Emax}/${Nmin}/${Nmax}" GMT_J=`echo $Emin $Emax $Nmin $Nmax | awk '{ printf("-Jb%f/%f/%f/%f/1:2000000", ($1+$2)/2.0,($3+$4)/2.0,$3,$4) }'` GMT_XY="-Xa${x0} -Ya${y0}" # 仮定した各kについて地図をプロット # Plot a map for each assumed k for result_dir in result_k* do # 計算結果のディレクトリに移動 # Move into the result directory cd $result_dir # 入出力ファイル名を設定 # Set input and output file names data_file=../sample_data.dat outputfile_noExt=map # プロットの開始 # Start plotting gmt begin $outputfile_noExt ps # 座標軸に用いるフォントサイズの設定 # Set font size for coordinate axis gmt set FONT_ANNOT_PRIMARY 10p # 海岸線のプロット # Plot the coast line gmt coast $GMT_R $GMT_J $GMT_XY -Bxa${Etics} -Bya${Ntics} -BWSen -S191/223/255 -G180/220/180 -W0.4,180/180/180 -Df # 1つ目の観測点と円のプロット # Plot the 1st station and circle line_currentStation=1 color_currentStation=$color_station1 TF_plot_for_station # 2つ目の観測点と円のプロット # Plot the 2nd station and circle line_currentStation=2 color_currentStation=$color_station2 TF_plot_for_station # 3つ目の観測点と円のプロット # Plot the 3rd station and circle line_currentStation=3 color_currentStation=$color_station3 TF_plot_for_station # 共通弦のプロット # Plot chords inputfile=lines.dat if [ -e $inputfile ] then sed -n '1,8p' $inputfile | gmt plot $GMT_R $GMT_J $GMT_XY -W0.4,0/0/0 fi # 震源の深さを求めるための半円のプロット # Plot a half circle to determine hypocenter depth inputfile=circle_depth.dat if [ -e $inputfile ] then gmt plot $inputfile $GMT_R $GMT_J $GMT_XY -W0.4,${color_depth} fi # 震源の深さを求めるための垂線のプロット # Plot a line perpendicular to a chord to determine hypocenter depth inputfile=lines.dat if [ -e $inputfile ] then sed -n '10,11p' $inputfile | gmt plot $GMT_R $GMT_J $GMT_XY -W0.4,${color_depth} fi # プロットの終了 # End plotting gmt end # png形式の画像ファイルに変換 # Convert to png format convert -trim -density 150 $outputfile_noExt.ps $outputfile_noExt.png # 次のkに対する結果のプロットのため元の作業ディレクトリに戻る # Return back to the original working directory for the next k cd .. done |