Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

taup: Add tutorial for taup_time #62

Merged
merged 27 commits into from
Jan 2, 2021
Merged
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
5abd1e6
taup: Add tutorial for taup_time
seisman Jan 1, 2021
3df3f2c
Add to toc
seisman Jan 1, 2021
9d1f7ec
Updates
seisman Jan 2, 2021
d989102
Update
seisman Jan 2, 2021
7564861
Merge branch 'main' into taup_time
seisman Jan 2, 2021
5eb1455
fixes
seisman Jan 2, 2021
302e4c2
Tiny fix
seisman Jan 2, 2021
f54dbe0
Merge branch 'main' into taup_time
seisman Jan 2, 2021
20e5043
Merge branch 'main' into taup_time
seisman Jan 2, 2021
6a7cbb7
Apply suggestions from code review
seisman Jan 2, 2021
51366c9
Update source/taup/taup_time.rst
seisman Jan 2, 2021
ceb9a75
Update source/taup/taup_time.rst
seisman Jan 2, 2021
0d2b32e
Update source/taup/taup_time.rst
seisman Jan 2, 2021
61c5cbd
Update source/taup/taup_time.rst
seisman Jan 2, 2021
2623e1a
Apply suggestions from code review
seisman Jan 2, 2021
a4cee85
Update source/taup/taup_time.rst
seisman Jan 2, 2021
c8a58dc
Update source/taup/taup_time.rst
seisman Jan 2, 2021
5ab8119
Update source/taup/taup_time.rst
seisman Jan 2, 2021
5f9f21d
Update source/taup/taup_time.rst
seisman Jan 2, 2021
77cb7d4
Update source/taup/taup_time.rst
seisman Jan 2, 2021
76c9ea3
Update source/taup/taup_time.rst
seisman Jan 2, 2021
0e7a255
Update source/taup/taup_time.rst
seisman Jan 2, 2021
26f022f
Update source/taup/taup_time.rst
seisman Jan 2, 2021
c58132c
Update source/taup/taup_time.rst
seisman Jan 2, 2021
302b982
Update source/taup/taup_time.rst
seisman Jan 2, 2021
862e657
Apply suggestions from code review
seisman Jan 2, 2021
325889c
Update source/taup/taup_time.rst
seisman Jan 2, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions source/taup/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,4 @@ TauP

introduction
install
taup_time
2 changes: 1 addition & 1 deletion source/taup/introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ TauP 提供了多个工具:
- 图形界面: ``taup``
- 命令行工具:

- ``taup_time`` :计算震相的走时、射线参数、出射角、入射角等
- :doc:`taup_time` :计算震相的走时、射线参数、出射角、入射角等
- ``taup_pierce`` :计算震相在波速不连续面和指定深度的反射点和穿透点
- ``taup_path`` :计算射线路径
- ``taup_wavefront`` :计算波前面
Expand Down
159 changes: 159 additions & 0 deletions source/taup/taup_time.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
taup_time
=========

TauP 提供的 ``taup_time`` 命令可用于计算震相走时、射线参数、出射角、
入射角等信息。

基本用法
--------

使用 ``taup_time -help`` 可查询该命令的完整用法和选项,此处仅介绍常用用法。

计算震源深度为 300 km,震中距 60° 处,P、S、PcP、ScS、PKiKP 震相的走时信息::

$ taup_time -h 300 -deg 60 -ph P,S,PcP,ScS,PKiKP

- ``-h``:震源深度(单位 km)
seisman marked this conversation as resolved.
Show resolved Hide resolved
- ``-deg``:震中距(单位 °)
- ``-ph``:以逗号分隔的震相名

TauP 默认使用 iasp91 模型,可以使用 ``-mod`` 选项设置其他 TauP 预定义速度模型::

$ taup_time -mod prem -h 300 -deg 60 -ph P,S,PcP,ScS,PKiKP
seisman marked this conversation as resolved.
Show resolved Hide resolved

TauP 默认台站位于地表,可使用 ``--stadepth`` 选项设置台站深度(单位为 km)::

$ taup_time -h 300 -deg 60 --stadepth 0.5 -ph P,S,PcP,ScS,PKiKP

若已知震源和台站位置,也可以使用 ``-evt`` 和 ``-sta`` 选项分别指定震源和台站的
纬度和经度。例如,震源位于 (80 °N,150 °E),台站位于 (20 °N,130 °E)::

$ taup_time -mod prem -h 300 -evt 80 150 -sta 20 130 -ph P,S,PcP,ScS,PKiKP
seisman marked this conversation as resolved.
Show resolved Hide resolved

在震中距比较小的情况下,可以使用 ``-km`` 选项指定震中距(单位为 km)。
比如计算震源深度为 5 km,震中距 100 km 处,P,S,PcP,ScS,PKiKP 震相的走时信息::

$ taup_time -h 5 -km 100 -ph P,S,PcP,ScS,PKiKP

输出格式
--------

下面的命令计算了 PREM 模型下,震源深度 100 km,震中距 60° 处,P 和 pP 震相的走时信息。
其输出为::

$ taup_time -mod prem -h 100 -deg 60 -ph pP,P
seisman marked this conversation as resolved.
Show resolved Hide resolved

Model: prem
Distance Depth Phase Travel Ray Param Takeoff Incident Purist Purist
(deg) (km) Name Time (s) p (s/deg) (deg) (deg) Distance Name
-----------------------------------------------------------------------------------
60.00 100.0 P 595.40 6.815 30.14 20.82 60.00 = P
60.00 100.0 pP 618.89 6.890 149.49 21.06 60.00 = pP

输出共 9 列,从左到右分别为:

1. 震中距(度):地震震中与台站的大圆弧路径长度
2. 震源深度(km)
3. 震相名
4. 震相走时(秒)
5. 射线参数(秒/度)

.. note::

射线参数有三种常用单位:秒/度(s/deg )、秒/弧度(s/radian)、秒/千米(s/km)。
三者之间的关系为(:math:`R_0` 为地球半径):

.. math::

1 s/deg = \frac{1}{\pi*R_0/180} s/km = 1/111.2 s/km
seisman marked this conversation as resolved.
Show resolved Hide resolved

.. math::

1 s/deg = \frac{1}{\pi / 180} s/radian = 57.3 s/radian
seisman marked this conversation as resolved.
Show resolved Hide resolved

6. 出射角(度):即射线从震源出射时与\ **垂直向下**\ 方向的夹角,取值范围为0到180°。

- 出射角 0° 到 90° 内表示射线向下出射(例如P震相)
- 出射角 90° 到 180° 内表示射线向上出射(例如pP震相)
seisman marked this conversation as resolved.
Show resolved Hide resolved

.. note::

不同文章对出射角的定义不同,使用时应格外注意。

老版本的TauP对出射角的定义不同,可视为BUG,应避免使用老版本TauP。
seisman marked this conversation as resolved.
Show resolved Hide resolved

7. 入射角(度):射线在台站处入射时与\ **垂直向上**\ 方向的夹角。
seisman marked this conversation as resolved.
Show resolved Hide resolved
8. Purist 距离:地震波实际走过的圆弧距离。

该值可能与震中距不同,例如 50° 震中距处记录到的 PKKKP 震相,实际走过的
圆弧距离为 410°::

$ taup_time -ph PKKKP -deg 50
seisman marked this conversation as resolved.
Show resolved Hide resolved

Model: iasp91
Distance Depth Phase Travel Ray Param Takeoff Incident Purist Purist
(deg) (km) Name Time (s) p (s/deg) (deg) (deg) Distance Name
-----------------------------------------------------------------------------------
50.00 0.0 PKKKP 2519.56 2.242 6.72 6.72 410.00 = PKKKP

9. Purist 震相名:地震波的“真实”震相名。

例如,若想要计算 SS 震相在 660 km 不连续面的下表面的反射波走时,可指定其震相名为
``S^660S``。由于 PREM 模型中 660 km 不连续面的“真实”深度为670 km,此时
TauP 实际返回的时从 670 km 处反射回的震相,此时 Purist 震相名会显示为 ``S^670S``::

$ taup_time -mod prem -ph S^660S -deg 120
seisman marked this conversation as resolved.
Show resolved Hide resolved

Model: prem
Distance Depth Phase Travel Ray Param Takeoff Incident Purist Purist
(deg) (km) Name Time (s) p (s/deg) (deg) (deg) Distance Name
------------------------------------------------------------------------------------
120.00 0.0 S^660S 1975.75 12.336 20.79 20.79 120.00 * S^670S

当使用 ``--rel`` 选项时,``taup_time`` 可输出相对于某个指定震相的走时差。例如,
下面的命令中,最后一列输出了所有震相相对于 PcP 震相的走时差::

$ taup_time -ph P,S,PcP,ScS,PKiKP -deg 60 -h 300 -mod prem --rel PcP
seisman marked this conversation as resolved.
Show resolved Hide resolved

Model: prem
Distance Depth Phase Travel Ray Param Takeoff Incident Purist Purist Relative to
(deg) (km) Name Time (s) p (s/deg) (deg) (deg) Distance Name PcP
-----------------------------------------------------------------------------------------------
60.00 300.0 P 574.72 6.739 33.65 20.58 60.00 = P -42.32
60.00 300.0 PcP 617.05 4.016 19.28 12.09 60.00 = PcP 0.00
60.00 300.0 PKiKP 993.45 1.245 5.88 3.72 60.00 = PKiKP 376.41
60.00 300.0 S 1043.98 12.659 34.16 21.37 60.00 = S 426.93
60.00 300.0 ScS 1134.89 7.480 19.38 12.43 60.00 = ScS 517.85

信息提取
--------

上面介绍的输出中包含了很多信息,想要在脚本中提取出想要的信息有些麻烦。所以
``taup_time`` 提供了一些选项,使得在脚本中计算走时什么的更加方便。
seisman marked this conversation as resolved.
Show resolved Hide resolved

走时
~~~~
core-man marked this conversation as resolved.
Show resolved Hide resolved
seisman marked this conversation as resolved.
Show resolved Hide resolved

``--time`` 选项使得输出中只包含走时信息::

$ taup_time -mod prem -ph P,S,PcP -deg 60 -h 100 --time
595.3896 640.09875 1081.2472
seisman marked this conversation as resolved.
Show resolved Hide resolved

需要注意的是,输出中走时不是按照 ``-ph`` 选项中震相的顺序进行排序的,
seisman marked this conversation as resolved.
Show resolved Hide resolved
而是按照走时递增的顺序排序。比如这里,S 震相放在震相列表的第二位,
而 S 震相的走时 1081.2472 却放在第三位。
seisman marked this conversation as resolved.
Show resolved Hide resolved

射线参数
~~~~~~~~
seisman marked this conversation as resolved.
Show resolved Hide resolved

``--rayp`` 选项使得输出中只包含射线参数信息::

$ taup_time -mod prem -ph P,S,PcP -deg 60 -h 100 --rayp
6.8185554 3.9990747 12.785722

此时,射线参数的输出是按照震相进行排序的。
seisman marked this conversation as resolved.
Show resolved Hide resolved

.. note::

``--rayp`` 和 ``--time`` 选项不能一起使用。
当两个选项同时使用时,会以后出现的选项为准。