openquake.hazardlib.source package¶
Seismic sources and ruptures¶
area¶
Module openquake.hazardlib.source.area
defines AreaSource
.
-
class
openquake.hazardlib.source.area.
AreaSource
(source_id, name, tectonic_region_type, mfd, rupture_mesh_spacing, magnitude_scaling_relationship, rupture_aspect_ratio, temporal_occurrence_model, upper_seismogenic_depth, lower_seismogenic_depth, nodal_plane_distribution, hypocenter_distribution, polygon, area_discretization)[source]¶ Bases:
openquake.hazardlib.source.point.PointSource
Area source represents uniform seismicity occurring over a geographical region.
Parameters: - polygon – An instance of
openquake.hazardlib.geo.polygon.Polygon
that defines source’s area. - area_discretization – Float number, polygon area discretization spacing in kilometers.
See
openquake.hazardlib.source.area.AreaSource.iter_ruptures()
.
Other parameters (except
location
) are the same as forPointSource
.-
MODIFICATIONS
= set([])¶
-
RUPTURE_WEIGHT
= 0.1¶
-
assert_equal
(other)¶
-
count_ruptures
()[source]¶ See
openquake.hazardlib.source.base.BaseSeismicSource.count_ruptures()
for description of parameters and return value.
-
filter_sites_by_distance_to_source
(integration_distance, sites)[source]¶ Overrides
implementation
of the point source class just to call thebase class one
.
-
get_rupture_enclosing_polygon
(dilation=0)[source]¶ Extends the area source polygon by
dilation
plus_get_max_rupture_projection_radius()
.See
superclass method
for parameter and return value definition.
-
iter_ruptures
()[source]¶ See
openquake.hazardlib.source.base.BaseSeismicSource.iter_ruptures()
for description of parameters and return value.Area sources are treated as a collection of point sources (see
openquake.hazardlib.source.point
) with uniform parameters. Ruptures of area source are just a union of ruptures of those point sources. The actual positions of the implied point sources form a uniformly spaced mesh on the polygon. Polygon’s method :meth: ~openquake.hazardlib.geo.polygon.Polygon.discretize is used for creating a mesh of points on the source’s area. Constructor’s parameterarea_discretization
is used as polygon’s discretization spacing (not to be confused with rupture surface’s mesh spacing which is as well provided to the constructor).The ruptures’ occurrence rates are rescaled with respect to number of points the polygon discretizes to.
- polygon – An instance of
base¶
Module openquake.hazardlib.source.base
defines a base class for
seismic sources.
-
class
openquake.hazardlib.source.base.
BaseSeismicSource
(source_id, name, tectonic_region_type)[source]¶ Bases:
object
Base class representing a seismic source, that is a structure generating earthquake ruptures.
Parameters: - source_id – Some (numeric or literal) source identifier. Supposed to be unique within the source model.
- name – String, a human-readable name of the source.
- tectonic_region_type – Source’s tectonic regime. See
openquake.hazardlib.const.TRT
.
-
MODIFICATIONS
¶
-
RUPTURE_WEIGHT
= 1.0¶
-
assert_equal
(other)¶
-
filter_sites_by_distance_to_source
(integration_distance, sites)[source]¶ Filter out sites from the collection that are further from the source than some arbitrary threshold.
Parameters: - integration_distance – Distance in km representing a threshold: sites that are further than that distance from the closest rupture produced by the source should be excluded.
- sites – Instance of
openquake.hazardlib.site.SiteCollection
to filter.
Returns: Filtered
SiteCollection
.Method can be overridden by subclasses in order to achieve higher performance for a specific typology. Base class method calls
get_rupture_enclosing_polygon()
withintegration_distance
as a dilation value and then filters site collection by checking :meth: containment <openquake.hazardlib.geo.polygon.Polygon.intersects> of site locations.The main criteria for this method to decide whether a site should be filtered out or not is the minimum distance between the site and all the ruptures produced by the source. If at least one rupture is closer (in terms of great circle distance between surface projections) than integration distance to a site, it should not be filtered out. However, it is important not to make this method too computationally intensive. If short-circuits are taken, false positives are generally better than false negatives (it’s better not to filter a site out if there is some uncertainty about its distance).
-
get_bounding_box
(dilation=0)[source]¶ Returns the bounding box of all the ruptures generated by the source, enlarged by the integration distance (dilation).
-
get_min_max_mag
()[source]¶ Return minimum and maximum magnitudes of the ruptures generated by the source.
-
get_rupture_enclosing_polygon
(dilation=0)[source]¶ Get a polygon which encloses all the ruptures generated by the source.
The rupture enclosing polygon is meant to be used in all hazard calculators to filter out sources whose ruptures the user wants to be neglected because they are too far from the locations of interest.
For performance reasons, the
get_rupture_enclosing_polygon()
should compute the polygon, without creating all the ruptures. The rupture enclosing polygon may not be necessarily the minimum enclosing polygon, but must guarantee that all ruptures are within the polygon.This method must be implemented by subclasses.
Parameters: dilation – A buffer distance in km to extend the polygon borders to. Returns: Instance of openquake.hazardlib.geo.polygon.Polygon
.
-
iter_ruptures
()[source]¶ Get a generator object that yields probabilistic ruptures the source consists of.
Returns: Generator of instances of sublclass of :class: ~openquake.hazardlib.source.rupture.BaseProbabilisticRupture.
-
modify
(modification, parameters)[source]¶ Apply a single modificaton to the source parameters Reflects the modification method and calls it passing
parameters
as keyword arguments.Modifications can be applied one on top of another. The logic of stacking modifications is up to a specific source implementation.
Parameters: - modification – String name representing the type of modification.
- parameters – Dictionary of parameters needed for modification.
Raises: ValueError – If
modification
is missing from the attribute MODIFICATIONS.
-
weight
¶ Determine the source weight from the number of ruptures, by multiplying with the scale factor RUPTURE_WEIGHT
-
class
openquake.hazardlib.source.base.
ParametricSeismicSource
(source_id, name, tectonic_region_type, mfd, rupture_mesh_spacing, magnitude_scaling_relationship, rupture_aspect_ratio, temporal_occurrence_model)[source]¶ Bases:
openquake.hazardlib.source.base.BaseSeismicSource
Parametric Seismic Source generates earthquake ruptures from source parameters, and associated probabilities of occurrence are defined through a magnitude frequency distribution and a temporal occurrence model.
Parameters: - mfd – Magnitude-Frequency distribution for the source.
See
openquake.hazardlib.mfd
. - rupture_mesh_spacing – The desired distance between two adjacent points in source’s
ruptures’ mesh, in km. Mainly this parameter allows to balance
the trade-off between time needed to compute the
distance
between the rupture surface and a site and the precision of that computation. - magnitude_scaling_relationship – Instance of subclass of
openquake.hazardlib.scalerel.base.BaseMSR
to describe how does the area of the rupture depend on magnitude and rake. - rupture_aspect_ratio – Float number representing how much source’s ruptures are more wide than tall. Aspect ratio of 1 means ruptures have square shape, value below 1 means ruptures stretch vertically more than horizontally and vice versa.
- temporal_occurrence_model – Instance of
openquake.hazardlib.tom.PoissonTOM
defining temporal occurrence model for calculating rupture occurrence probabilities
Raises: ValueError – If either rupture aspect ratio or rupture mesh spacing is not positive (if not None).
-
assert_equal
(other)¶
-
get_annual_occurrence_rates
(min_rate=0)[source]¶ Get a list of pairs “magnitude – annual occurrence rate”.
The list is taken from assigned MFD object (see
openquake.hazardlib.mfd.base.BaseMFD.get_annual_occurrence_rates()
) with simple filtering by rate applied.Parameters: min_rate – A non-negative value to filter magnitudes by minimum annual occurrence rate. Only magnitudes with rates greater than that are included in the result list. Returns: A list of two-item tuples – magnitudes and occurrence rates.
- mfd – Magnitude-Frequency distribution for the source.
See
characteristic¶
Module openquake.hazardlib.source.characteristic
defines
CharacteristicFaultSource
.
-
class
openquake.hazardlib.source.characteristic.
CharacteristicFaultSource
(source_id, name, tectonic_region_type, mfd, temporal_occurrence_model, surface, rake, surface_node=None)[source]¶ Bases:
openquake.hazardlib.source.base.ParametricSeismicSource
Characteristic source typology represents seismicity occuring on a generic fault surface with seismic events rupturing the entire fault surface independently of their magnitude values.
Characteristic source typology can be used to model individual faults or fault segments that tend to produce essentialy same size earthquakes (see for instance: Schwartz, D. P., K. J. Coppersmith, Fault behavior and characteristic earthquakes: Examples from the Wasatch and San Andreas fault zones, J. Geophys. Res., 89, 5681-5698, 1984)
Parameters: - surface – Fault surface, see
openquake.hazardlib.geo.surface
. - rake – Angle describing rupture propagation direction in decimal degrees.
See also
openquake.hazardlib.source.base.ParametricSeismicSource
for description of other parameters.Note that a
CharacteristicFaultSource
does not need any mesh spacing, magnitude scaling relationship, and aspect ratio, therefore the constructor sets these parameters toNone
.NB: if you want to convert a characteristic source into XML, you must set its attribute surface_node to an explicit representation of the surface as a LiteralNode object.
-
MODIFICATIONS
= set(['set_geometry'])¶
-
assert_equal
(other)¶
-
count_ruptures
()[source]¶ See :meth: openquake.hazardlib.source.base.BaseSeismicSource.count_ruptures.
-
get_rupture_enclosing_polygon
(dilation=0)[source]¶ Uses :meth: openquake.hazardlib.geo.surface.base.BaseSurface.get_bounding_box() and from bounding box coordinates create
openquake.hazardlib.geo.mesh.RectangularMesh
and then callsopenquake.hazardlib.geo.mesh.Mesh.get_convex_hull()
to get a polygon representation of the bounding box. Note that this is needed to cope with the situation of a vertical rupture for which the bounding box collapses to a line. In this case the methodget_convex_hull()
returns a valid polygon obtained by expanding the line by a small distance. Finally, a polygon is returned by callingdilate()
passing in thedilation
parameter.See
superclass method
for parameter and return value definition.
-
iter_ruptures
()[source]¶ See :meth: openquake.hazardlib.source.base.BaseSeismicSource.iter_ruptures.
For each magnitude value in the given MFD, return an earthquake rupture with a surface always equal to the given surface.
-
modify_set_geometry
(surface, surface_node=None)[source]¶ Modifies the current fault geometry
Parameters: - surface – Fault surface, see
openquake.hazardlib.geo.surface
. - surface_node – If needed for export, provide the surface as a LiteralNode object
- surface – Fault surface, see
- surface – Fault surface, see
complex_fault¶
Module openquake.hazardlib.source.complex_fault
defines ComplexFaultSource
.
-
class
openquake.hazardlib.source.complex_fault.
ComplexFaultSource
(source_id, name, tectonic_region_type, mfd, rupture_mesh_spacing, magnitude_scaling_relationship, rupture_aspect_ratio, temporal_occurrence_model, edges, rake)[source]¶ Bases:
openquake.hazardlib.source.base.ParametricSeismicSource
Complex fault source typology represents seismicity occurring on a fault surface with an arbitrarily complex geometry.
Parameters: - edges – A list of
Line
objects, representing fault source geometry. Seeopenquake.hazardlib.geo.surface.complex_fault.ComplexFaultSurface.from_fault_data()
. - rake – Angle describing rupture propagation direction in decimal degrees.
See also
openquake.hazardlib.source.base.ParametricSeismicSource
for description of other parameters.Raises: ValueError – If check_fault_data()
fails or if rake value is invalid.-
MODIFICATIONS
= set(['set_geometry'])¶
-
RUPTURE_WEIGHT
= 4.0¶
-
assert_equal
(other)¶
-
count_ruptures
()[source]¶ See :meth: openquake.hazardlib.source.base.BaseSeismicSource.count_ruptures.
-
get_rupture_enclosing_polygon
(dilation=0)[source]¶ Uses
openquake.hazardlib.geo.surface.complex_fault.ComplexFaultSurface.surface_projection_from_fault_data()
for getting the fault’s surface projection and then calls itsdilate()
method passing indilation
parameter.See
superclass method
for parameter and return value definition.
-
iter_ruptures
()[source]¶ See :meth: openquake.hazardlib.source.base.BaseSeismicSource.iter_ruptures.
Uses
_float_ruptures()
for finding possible rupture locations on the whole fault surface.
-
start
= None¶
-
stop
= None¶
- edges – A list of
non_parametric¶
Module openquake.hazardlib.source.non_parametric
defines
NonParametricSeismicSource
-
class
openquake.hazardlib.source.non_parametric.
NonParametricSeismicSource
(source_id, name, tectonic_region_type, data)[source]¶ Bases:
openquake.hazardlib.source.base.BaseSeismicSource
Non Parametric Seismic Source explicitly defines earthquake ruptures in the constructor. That is earthquake ruptures are not generated algorithmically from a set of source parameters.
Ruptures’ rectonic region types are overwritten by source tectonic region type.
Parameters: data – List of tuples. Each tuple must contain two items. The first item must be an instance of openquake.hazardlib.source.rupture.Rupture
. The second item must be an instance ofopenquake.hazardlib.pmf.PMF
describing the probability of the rupture to occur N times (the PMF must be defined from a minimum number of occurrences equal to 0)-
MODIFICATIONS
= set([])¶
-
assert_equal
(other)¶
-
count_ruptures
()[source]¶ See :meth: openquake.hazardlib.source.base.BaseSeismicSource.count_ruptures.
-
get_min_max_mag
()[source]¶ Return the minimum and maximum magnitudes of the ruptures generated by the source
-
get_rupture_enclosing_polygon
(dilation=0)[source]¶ Create instance of
openquake.hazardlib.geo.surface.multi.MultiSurface
from all ruptures’ surfaces and compute its bounding box. Calculate convex hull of bounding box, and return it dilated bydilation
.Parameters: dilation – A buffer distance in km to extend the polygon borders to. Returns: Instance of openquake.hazardlib.geo.polygon.Polygon
.
-
point¶
Module openquake.hazardlib.source.point
defines PointSource
.
-
class
openquake.hazardlib.source.point.
PointSource
(source_id, name, tectonic_region_type, mfd, rupture_mesh_spacing, magnitude_scaling_relationship, rupture_aspect_ratio, temporal_occurrence_model, upper_seismogenic_depth, lower_seismogenic_depth, location, nodal_plane_distribution, hypocenter_distribution)[source]¶ Bases:
openquake.hazardlib.source.base.ParametricSeismicSource
Point source typology represents seismicity on a single geographical location.
Parameters: - upper_seismogenic_depth – Minimum depth an earthquake rupture can reach, in km.
- lower_seismogenic_depth – Maximum depth an earthquake rupture can reach, in km.
- location –
Point
object representing the location of the seismic source. - nodal_plane_distribution –
PMF
object with values that are instances ofopenquake.hazardlib.geo.nodalplane.NodalPlane
. Shows the distribution of probability for rupture to have the certain nodal plane. - hypocenter_distribution –
PMF
with values being float numbers in km representing the depth of the hypocenter. Latitude and longitude of the hypocenter is always set to ones oflocation
.
See also
openquake.hazardlib.source.base.ParametricSeismicSource
for description of other parameters.Raises: ValueError – If upper seismogenic depth is below lower seismogenic depth, if one or more of hypocenter depth values is shallower than upper seismogenic depth or deeper than lower seismogenic depth. -
MODIFICATIONS
= set([])¶
-
RUPTURE_WEIGHT
= 0.1¶
-
assert_equal
(other)¶
-
count_ruptures
()[source]¶ See :meth: openquake.hazardlib.source.base.BaseSeismicSource.count_ruptures.
-
filter_sites_by_distance_to_source
(integration_distance, sites)[source]¶ Filter sites that are closer than maximum rupture projection radius plus integration distance along the great circle arc from source’s epicenter location. Overrides
base class' method
in order to avoid using polygon.
-
get_rupture_enclosing_polygon
(dilation=0)[source]¶ Returns a circle-shaped polygon with radius equal to
dilation
plus_get_max_rupture_projection_radius()
.See
superclass method
for parameter and return value definition.
rupture¶
Module openquake.hazardlib.source.rupture
defines classes
BaseRupture
and its subclasses
NonParametricProbabilisticRupture
and
ParametricProbabilisticRupture
-
class
openquake.hazardlib.source.rupture.
BaseRupture
(mag, rake, tectonic_region_type, hypocenter, surface, source_typology, rupture_slip_direction=None)[source]¶ Bases:
object
Rupture object represents a single earthquake rupture.
Parameters: - mag – Magnitude of the rupture.
- rake – Rake value of the rupture.
See
NodalPlane
. - tectonic_region_type – Rupture’s tectonic regime. One of constants
in
openquake.hazardlib.const.TRT
. - hypocenter – A
Point
, rupture’s hypocenter. - surface – An instance of subclass of
BaseSurface
. Object representing the rupture surface geometry. - source_typology – Subclass of
BaseSeismicSource
(class object, not an instance) referencing the typology of the source that produced this rupture. - rupture_slip_direction – Angle describing rupture propagation direction in decimal degrees.
Raises: ValueError – If magnitude value is not positive, or tectonic region type is unknown.
NB: if you want to convert the rupture into XML, you should set the attribute surface_nodes to an appropriate value.
-
assert_equal
(other)¶
-
code
¶ Returns the code (integer in the range 0 .. 255) of the rupture
-
get_probability_no_exceedance
(poes)[source]¶ Compute and return the probability that in the time span for which the rupture is defined, the rupture itself never generates a ground motion value higher than a given level at a given site.
Such calculation is performed starting from the conditional probability that an occurrence of the current rupture is producing a ground motion value higher than the level of interest at the site of interest. The actual formula used for such calculation depends on the temporal occurrence model the rupture is associated with. The calculation can be performed for multiple intensity measure levels and multiple sites in a vectorized fashion.
Parameters: poes – 2D numpy array containing conditional probabilities the the a rupture occurrence causes a ground shaking value exceeding a ground motion level at a site. First dimension represent sites, second dimension intensity measure levels. poes
can be obtained calling themethod
.
-
classmethod
init
()[source]¶ Initialize the class dictionaries ._code and .`types` encoding the bidirectional correspondence between an integer in the range 0..255 (the code) and a triplet of classes (rupture_class, surface_class, source_class). This is useful when serializing the rupture to and from HDF5.
-
sample_number_of_occurrences
()[source]¶ Randomly sample number of occurrences from temporal occurrence model probability distribution.
Note
This method is using random numbers. In order to reproduce the same results numpy random numbers generator needs to be seeded, see http://docs.scipy.org/doc/numpy/reference/generated/numpy.random.seed.html
Returns: int, Number of rupture occurrences
-
class
openquake.hazardlib.source.rupture.
EBRupture
(rupture, sids, events, grp_id, serial)[source]¶ Bases:
object
An event based rupture. It is a wrapper over a hazardlib rupture object, containing an array of site indices affected by the rupture, as well as the IDs of the corresponding seismic events.
-
eids
¶ An array with the underlying event IDs
-
export
(mesh, sm_by_grp)[source]¶ Yield
Rupture
objects, with all the attributes set, suitable for export in XML format.
-
multiplicity
¶ How many times the underlying rupture occurs.
-
weight
¶ Weight of the EBRupture
-
-
class
openquake.hazardlib.source.rupture.
ExportedRupture
(rupid, events_by_ses, indices=None)[source]¶ Bases:
object
Simplified Rupture class with attributes rupid, events_by_ses, indices and others, used in export.
Parameters: - rupid – rupture serial ID
- events_by_ses – dictionary ses_idx -> event records
- indices – site indices
-
class
openquake.hazardlib.source.rupture.
NonParametricProbabilisticRupture
(mag, rake, tectonic_region_type, hypocenter, surface, source_typology, pmf, rupture_slip_direction=None)[source]¶ Bases:
openquake.hazardlib.source.rupture.BaseRupture
Probabilistic rupture for which the probability distribution for rupture occurrence is described through a generic probability mass function.
Parameters: pmf – Instance of
openquake.hazardlib.pmf.PMF
. Values in the abscissae represent number of rupture occurrences (in increasing order, staring from 0) and values in the ordinates represent associated probabilities. Example: if, for a given time span, a rupture has probability0.8
to not occurr,0.15
to occur once, and0.05
to occur twice, thepmf
can be defined aspmf = PMF([(Decimal('0.8'), 0), (Decimal('0.15'), 1), Decimal('0.05', 2)])
Raises: ValueError – If number of ruptures in pmf
do not start from 0, are not defined in increasing order, and if they are not defined with unit step-
get_probability_no_exceedance
(poes)[source]¶ See
superclass method
for spec of input and result values.Uses the formula
∑ p(k|T) * p(X<x|rup)^k
where
p(k|T)
is the probability that the rupture occurs k times in the time spanT
,p(X<x|rup)
is the probability that a rupture occurrence does not cause a ground motion exceedance, and the summation∑
is done over the number of occurrencesk
.p(k|T)
is given by the constructor’s parameterpmf
, andp(X<x|rup)
is computed as1 - poes
.
-
sample_number_of_occurrences
()[source]¶ See
superclass method
for spec of input and result values.Uses ‘Inverse Transform Sampling’ method.
-
-
class
openquake.hazardlib.source.rupture.
ParametricProbabilisticRupture
(mag, rake, tectonic_region_type, hypocenter, surface, source_typology, occurrence_rate, temporal_occurrence_model, rupture_slip_direction=None)[source]¶ Bases:
openquake.hazardlib.source.rupture.BaseRupture
Rupture
associated with an occurrence rate and a temporal occurrence model.Parameters: - occurrence_rate – Number of times rupture happens per year.
- temporal_occurrence_model – Temporal occurrence model assigned for this rupture. Should
be an instance of
openquake.hazardlib.tom.PoissonTOM
.
Raises: ValueError – If occurrence rate is not positive.
-
assert_equal
(other)¶
-
get_cdppvalue
(target, buf=1.0, delta=0.01, space=2.0)[source]¶ Get the directivity prediction value, centred DPP(cdpp) at a given site as described in Spudich et al. (2013), and this cdpp is used in Chiou and Young(2014) GMPE for near-fault directivity term prediction.
Parameters: - target_site – A mesh object representing the location of the target sites.
- buf – A float vaule presents the buffer distance in km to extend the mesh borders to.
- delta – A float vaule presents the desired distance between two adjacent points in mesh
- space – A float vaule presents the tolerance for the same distance of the sites (default 2 km)
Returns: A float value presents the centreed directivity predication value which used in Chioud and Young(2014) GMPE for directivity term
-
get_dppvalue
(site)[source]¶ Get the directivity prediction value, DPP at a given site as described in Spudich et al. (2013).
Parameters: site – Point
object representing the location of the target siteReturns: A float number, directivity prediction value (DPP).
-
get_probability_no_exceedance
(poes)[source]¶ See
superclass method
for spec of input and result values.Uses
openquake.hazardlib.tom.PoissonTOM.get_probability_no_exceedance()
-
get_probability_one_occurrence
()[source]¶ Return the probability of this rupture to occur exactly one time.
Uses :meth: openquake.hazardlib.tom.PoissonTOM.get_probability_one_occurrence of an assigned temporal occurrence model.
-
get_probability_one_or_more_occurrences
()[source]¶ Return the probability of this rupture to occur one or more times.
Uses
get_probability_one_or_more_occurrences()
of an assigned temporal occurrence model.
-
openquake.hazardlib.source.rupture.
get_geom
(surface, is_from_fault_source, is_multi_surface)[source]¶ The following fields can be interpreted different ways, depending on the value of is_from_fault_source. If is_from_fault_source is True, each of these fields should contain a 2D numpy array (all of the same shape). Each triple of (lon, lat, depth) for a given index represents the node of a rectangular mesh. If is_from_fault_source is False, each of these fields should contain a sequence (tuple, list, or numpy array, for example) of 4 values. In order, the triples of (lon, lat, depth) represent top left, top right, bottom left, and bottom right corners of the the rupture’s planar surface. Update: There is now a third case. If the rupture originated from a characteristic fault source with a multi-planar-surface geometry, lons, lats, and depths will contain one or more sets of 4 points, similar to how planar surface geometry is stored (see above).
Parameters: - surface – a Surface instance
- is_from_fault_source – a boolean
- is_multi_surface – a boolean
simple_fault¶
Module openquake.hazardlib.source.simple_fault
defines
SimpleFaultSource
.
-
class
openquake.hazardlib.source.simple_fault.
SimpleFaultSource
(source_id, name, tectonic_region_type, mfd, rupture_mesh_spacing, magnitude_scaling_relationship, rupture_aspect_ratio, temporal_occurrence_model, upper_seismogenic_depth, lower_seismogenic_depth, fault_trace, dip, rake, hypo_list=(), slip_list=())[source]¶ Bases:
openquake.hazardlib.source.base.ParametricSeismicSource
Simple fault source typology represents seismicity occurring on a fault surface with simple geometry.
Parameters: - upper_seismogenic_depth – Minimum depth an earthquake rupture can reach, in km.
- lower_seismogenic_depth – Maximum depth an earthquake rupture can reach, in km.
- fault_trace – A
Line
representing the line of intersection between the fault plane and the Earth’s surface. - dip – Angle between earth surface and fault plane in decimal degrees.
- rake – the direction of hanging wall relative to the foot wall.
- rupture_slip_direction – Angle describing rupture propagation direction in decimal degrees.
- hypo_list – Array describing the relative position of the hypocentre on the rupture surface. Each line represents a hypocentral position defined in terms of the relative distance along strike and dip (from the upper, left corner of the fault surface i.e. the corner which results from the projection at depth of the first vertex of the fault trace) and the corresponding weight. Example 1: one single hypocentral position at the center of the rupture will be described by the following array[(0.5, 0.5, 1.0)]. Example 2: two possible hypocenters are admitted for a rupture. One hypocentre is located along the strike at 1/4 of the fault length and at 1/4 of the fault width along the dip and occurs with a weight of 0.3, the other one is at 3/4 of fault length along strike and at 3/4 of fault width along strike with a weight of 0.7. The numpy array would be entered as numpy.array([[0.25, 0.25, 0.3], [0.75, 0.75, 0.7]]).
- slip_list – Array describing the rupture slip direction, which desribes the rupture propagation direction on the rupture surface. Each line represents a rupture slip direction and the corresponding weight. Example 1: one single rupture slip direction with angle 90 degree will be described by the following array[(90, 1.0)]. Example 2: two possible rupture slip directions are admitted for a rupture. One slip direction is at 90 degree with a weight of 0.7, the other one is at 135 degree with a weight of 0.3. The numpy array would be entered as numpy.array( [[90, 0.7], [135, 0.3]]).
See also
openquake.hazardlib.source.base.ParametricSeismicSource
for description of other parameters.Raises: ValueError – If check_fault_data()
fails, if rake value is invalid and if rupture mesh spacing is too high for the lowest magnitude value.-
MODIFICATIONS
= set(['set_dip', 'adjust_dip', 'set_geometry'])¶
-
assert_equal
(other)¶
-
count_ruptures
()[source]¶ See :meth: openquake.hazardlib.source.base.BaseSeismicSource.count_ruptures.
-
get_rupture_enclosing_polygon
(dilation=0)[source]¶ Uses
openquake.hazardlib.geo.surface.simple_fault.SimpleFaultSurface.surface_projection_from_fault_data()
for getting the fault’s surface projection and then calls itsdilate()
method passing indilation
parameter.See
superclass method
for parameter and return value definition.
-
iter_ruptures
()[source]¶ See :meth: openquake.hazardlib.source.base.BaseSeismicSource.iter_ruptures.
Generates a ruptures using the “floating” algorithm: for all the magnitude values of assigned MFD calculates the rupture size with respect to MSR and aspect ratio and then places ruptures of that size on the surface of the whole fault source. The occurrence rate of each of those ruptures is the magnitude occurrence rate divided by the number of ruptures that can be placed in a fault.
-
modify_adjust_dip
(increment)[source]¶ Modifies the dip by an incremental value
Parameters: increment (float) – Value by which to increase or decrease the dip (the resulting dip must still be within 0.0 to 90.0 degrees)