mttime.core.utils.RGF_from_SW4

RGF_from_SW4(path_to_green='.', t0=0, file_name=None, origin_time=None, event_lat=None, event_lon=None, depth=None, station_name=None, station_lat=None, station_lon=None, output_directory='sw4out')[source]

Function to convert reciprocal Green’s functions from SW4 to tensor format

Reads the reciprocal Green’s functions (displacement/unit force) from SW4 and performs the summation to get the Green’s function tensor. RGFs from SW4 are oriented north, east and positive down by setting az=0.

Assumes the following file structure: f[x,y,z]/station_name/event_name.[x,y,z]

Parameters
  • path_to_green (str) – path to RGFs.

  • t0 (float) – offset in time (>=0).

  • file_name (str) – name of RGF sac files from SW4 (event name).

  • origin_time – event origin time.

  • event_lat (float) – event latitude.

  • event_lon (float) – event longitude

  • depth (float) – source depth

  • station_name (list of strings.) – station names.

  • station_lat (list of floats) – station latitudes.

  • station_lon (list of floats) – station longitudes.

  • output_directory (str) – output direcotry.