obspy.imaging.source.plot_radiation_pattern

plot_radiation_pattern(mt, kind=['p_sphere', 'beachball'], coordinate_system='RTP', p_sphere_direction='inwards', fig=None, show=True)[source]

Plot the P/S farfield radiation pattern on a unit sphere grid.

The calculations are based on [Aki1980] eq. 4.29.

Parameters:
  • mt Focal mechanism NM x 6 (M11, M22, M33, M12, M13, M23 - the six independent components of the moment tensor, where the coordinate system is 1,2,3 = Up,South,East which equals r,theta,phi - Harvard/Global CMT convention). The relation to [Aki1980] x,y,z equals North,East,Down convention is as follows: Mrr=Mzz, Mtt=Mxx, Mpp=Myy, Mrt=Mxz, Mrp=-Myz, Mtp=-Mxy.
  • kind

    One of the following three options: * A list of strings or nested list of strings for a matplotlib plot

    • ‘mayavi’: uses the mayavi library (not yet available under Python 3 and problematic with anaconda)
    • ‘vtk’: This vtk option writes two vtk files to the current working directory. rpattern.vtk contains the p and s wave farfield vector field. beachlines.vtk contains the nodal lines of the radiation pattern. A vtk glyph filter should be applied to the vector field (e.g. in ParaView) to visualize it.
  • coordinate_system the only implemented option so far is ‘RTP’ (also called ‘USE’). Should be extended to support NED, DSE, NED in the future.
  • fig (matplotlib.figure.Figure) Figure instance to use.
  • show (bool) Whether to show the figure after plotting or not. Can be used to do further customization of the plot before showing it.
Returns:

Matplotlib figure or None (if kind is “mayavi” or “vtk”)