Mondaic
This API reference is not for the latest stable Salvus version.

salvus.flow.simple_config.source.seismology

Sources in a seismological context.

Specifically this means:

  • Coordinates are specified in latitude, longitude, and burrial beneath the local subsurface.
  • Moment tensors and vector sources are specified in spherical r, theta, and phi coordinates. This corresponds to radial, colatitudinal, and longitudinal directions. This is also know has the Harvard convention for moment tensors.

For 2D the latitude will ignored and only the longitude will be assumed. This is the default polar coordinate system with:

  • x = r * cos(phi)
  • y = r * sin(phi)

phi is the longitude here.

Functions

parse()

def parse(
    filename_or_obj: Any,
    dimensions: int,
    side_set_name: str = "r1",
    source_time_function: Optional[salvus.flow.simple_config.stf._Base] = None,
    axes_a_b: Tuple[float, float] = (6378137.0, 6356752.314245),
) -> List[
    Union[
        salvus.flow.simple_config.source.seismology.SideSetMomentTensorPoint2D,
        salvus.flow.simple_config.source.seismology.SideSetMomentTensorPoint3D,
    ]
]:
    ...

Attempts to parse anything to a list of either :class:.SideSetMomentTensorPoint2D or :class:.SideSetMomentTensorPoint3D objects.

Supports pretty much everything ObsPy supports, ranging from QuakeML data, over CMTSOLUTION and ndk files to ObsPy’s custom objects from filenames, URLs, memory files, …

Coordinates, by default, are assumed to be defined on the WGS84 ellipsoid and will be converted to geocentric coordinates. This can be influenced with the axes_a_b parameter.

Parameters
  • filename_or_obj Any — Filename/URL/Python object
  • dimensions int — Determines if the function returns 2D or 3D moment tensor sources.
  • side_set_name str — Name of the side set the sources will be attached to. The default is likely good.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — A source in Salvus always requires a source time function and the information in the files is never enough to reconstruct it. It can already be specified here - if not it still must be set before a simulation is run.
  • axes_a_b Tuple[float, float] — Assumed ellipticity of the planet used for converting the latitude. Defaults to the values for the WGS84 ellipsoid.
Returns List[Union[salvus.flow.simple_config.source.seismology.SideSetMomentTensorPoint2D, salvus.flow.simple_config.source.seismology.SideSetMomentTensorPoint3D]] — A list of locatable side set sources.

Classes

MomentTensorPoint2D

class MomentTensorPoint2D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source._BaseSource,
):
    def __init__(
        self,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        mrr: float,
        mpp: float,
        mrp: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 2-D moment tensor source.

Parameters
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver.
  • radius_of_sphere_in_m float — This class assumes a perfect sphere to derive the cartesian coordinates of the receiver. This is the radius of that sphere.
  • mrr float — RR component of the moment in Nm.
  • mpp float — PP component of the moment in Nm.
  • mrp float — RP component of the moment in Nm.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
apply()
def apply(self, d: Union[Dict, _DeepSetter]) -> None:
    ...

Set the contents with a dictionary.

Parameters
  • d Union[Dict, _DeepSetter] — The dictionary to set.
Returns None
copy()
def copy(self) -> _DeepSetter:
    ...

Return a deep copy of the object.

Returns _DeepSetter
get_dictionary()
def get_dictionary(self) -> Dict:
    ...

Get the contents of this object as a dictionary.

Returns Dict
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict
validate()
def validate(self) -> None:
    ...

Validates the current state of the configuration against its schema.

Returns None

MomentTensorPoint3D

class MomentTensorPoint3D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source._BaseSource,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        mrr: float,
        mtt: float,
        mpp: float,
        mtp: float,
        mrp: float,
        mrt: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D moment tensor source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver.
  • radius_of_sphere_in_m float — This class assumes a perfect sphere to derive the cartesian coordinates of the receiver. This is the radius of that sphere.
  • mrr float — RR component of the moment in Nm.
  • mtt float — TT component of the moment in Nm.
  • mpp float — PP component of the moment in Nm.
  • mtp float — TP component of the moment in Nm.
  • mrp float — RP component of the moment in Nm.
  • mrt float — RT component of the moment in Nm.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
apply()
def apply(self, d: Union[Dict, _DeepSetter]) -> None:
    ...

Set the contents with a dictionary.

Parameters
  • d Union[Dict, _DeepSetter] — The dictionary to set.
Returns None
copy()
def copy(self) -> _DeepSetter:
    ...

Return a deep copy of the object.

Returns _DeepSetter
get_dictionary()
def get_dictionary(self) -> Dict:
    ...

Get the contents of this object as a dictionary.

Returns Dict
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict
validate()
def validate(self) -> None:
    ...

Validates the current state of the configuration against its schema.

Returns None

ScalarPoint2D

class ScalarPoint2D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source._BaseSource,
):
    def __init__(
        self,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        f: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological scalar 2-D source.

Parameters
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver.
  • radius_of_sphere_in_m float — This class assumes a perfect sphere to derive the cartesian coordinates of the receiver. This is the radius of that sphere.
  • f float — Force of the source in Nm.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
apply()
def apply(self, d: Union[Dict, _DeepSetter]) -> None:
    ...

Set the contents with a dictionary.

Parameters
  • d Union[Dict, _DeepSetter] — The dictionary to set.
Returns None
copy()
def copy(self) -> _DeepSetter:
    ...

Return a deep copy of the object.

Returns _DeepSetter
get_dictionary()
def get_dictionary(self) -> Dict:
    ...

Get the contents of this object as a dictionary.

Returns Dict
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict
validate()
def validate(self) -> None:
    ...

Validates the current state of the configuration against its schema.

Returns None

ScalarPoint3D

class ScalarPoint3D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source._BaseSource,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        f: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D scalar source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver.
  • radius_of_sphere_in_m float — This class assumes a perfect sphere to derive the cartesian coordinates of the receiver. This is the radius of that sphere.
  • f float — Force of the source in Nm.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
apply()
def apply(self, d: Union[Dict, _DeepSetter]) -> None:
    ...

Set the contents with a dictionary.

Parameters
  • d Union[Dict, _DeepSetter] — The dictionary to set.
Returns None
copy()
def copy(self) -> _DeepSetter:
    ...

Return a deep copy of the object.

Returns _DeepSetter
get_dictionary()
def get_dictionary(self) -> Dict:
    ...

Get the contents of this object as a dictionary.

Returns Dict
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict
validate()
def validate(self) -> None:
    ...

Validates the current state of the configuration against its schema.

Returns None

SideSetMomentTensorPoint2D

class SideSetMomentTensorPoint2D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source.cartesian.SideSetMomentTensorPoint2D,
):
    def __init__(
        self,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        mrr: float,
        mpp: float,
        mrp: float,
        side_set_name: str,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 2-D moment tensor side-set source.

Parameters
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver below the specified side set.
  • radius_of_sphere_in_m float — Planet radius used for the initial guess of the receiver. Can be a really rough estimate.
  • mrr float — RR component of the moment in Nm.
  • mpp float — PP component of the moment in Nm.
  • mrp float — RP component of the moment in Nm.
  • side_set_name str — Name of the side at which to place the receiver.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict

SideSetMomentTensorPoint3D

class SideSetMomentTensorPoint3D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source.cartesian.SideSetMomentTensorPoint3D,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        mrr: float,
        mtt: float,
        mpp: float,
        mtp: float,
        mrp: float,
        mrt: float,
        side_set_name: str,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D moment tensor side-set source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver below the specified side set.
  • radius_of_sphere_in_m float — Planet radius used for the initial guess of the receiver. Can be a really rough estimate.
  • mrr float — RR component of the moment in Nm.
  • mtt float — TT component of the moment in Nm.
  • mpp float — PP component of the moment in Nm.
  • mtp float — TP component of the moment in Nm.
  • mrp float — RP component of the moment in Nm.
  • mrt float — RT component of the moment in Nm.
  • side_set_name str — Name of the side at which to place the receiver.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict

SideSetScalarPoint2D

class SideSetScalarPoint2D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source.cartesian.SideSetScalarPoint2D,
):
    def __init__(
        self,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        side_set_name: str,
        f: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 2-D scalar side-set source.

Parameters
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver below the specified side set.
  • radius_of_sphere_in_m float — Planet radius used for the initial guess of the receiver. Can be a really rough estimate.
  • side_set_name str — Name of the side at which to place the receiver.
  • f float — Force of the source in Nm.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict

SideSetScalarPoint3D

class SideSetScalarPoint3D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source.cartesian.SideSetScalarPoint3D,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        side_set_name: str,
        f: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D scalar side-set source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver below the specified side set.
  • radius_of_sphere_in_m float — Planet radius used for the initial guess of the receiver. Can be a really rough estimate.
  • side_set_name str — Name of the side at which to place the receiver.
  • f float — Force of the source in Nm.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict

SideSetVectorGradientPoint2D

class SideSetVectorGradientPoint2D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source.cartesian.SideSetVectorGradientPoint2D,
):
    def __init__(
        self,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        grr: float,
        grp: float,
        gpr: float,
        gpp: float,
        side_set_name: str,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 2-D vector gradient side-set source.

Parameters
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver below the specified side set.
  • radius_of_sphere_in_m float — Planet radius used for the initial guess of the receiver. Can be a really rough estimate.
  • grr float — RR component of the gradient.
  • grp float — RP component of the gradient.
  • gpr float — PR component of the gradient.
  • gpp float — PP component of the gradient.
  • side_set_name str — Name of the side at which to place the receiver.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict

SideSetVectorGradientPoint3D

class SideSetVectorGradientPoint3D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source.cartesian.SideSetVectorGradientPoint3D,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        grr: float,
        grt: float,
        grp: float,
        gtr: float,
        gtt: float,
        gtp: float,
        gpr: float,
        gpt: float,
        gpp: float,
        side_set_name: str,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D vector gradient side-set source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver below the specified side set.
  • radius_of_sphere_in_m float — Planet radius used for the initial guess of the receiver. Can be a really rough estimate.
  • grr float — RR component of the gradient.
  • grt float — RT component of the gradient.
  • grp float — RP component of the gradient.
  • gtr float — TR component of the gradient.
  • gtt float — TT component of the gradient.
  • gtp float — TP component of the gradient.
  • gpr float — PR component of the gradient.
  • gpt float — PT component of the gradient.
  • gpp float — PP component of the gradient.
  • side_set_name str — Name of the side at which to place the receiver.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict

SideSetVectorPoint2D

class SideSetVectorPoint2D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source.cartesian.SideSetVectorPoint2D,
):
    def __init__(
        self,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        fr: float,
        fp: float,
        side_set_name: str,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 2-D vector side-set source.

Parameters
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver below the specified side set.
  • radius_of_sphere_in_m float — Planet radius used for the initial guess of the receiver. Can be a really rough estimate.
  • fr float — R component of the force in N.
  • fp float — P component of the force in N.
  • side_set_name str — Name of the side at which to place the receiver.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict

SideSetVectorPoint3D

class SideSetVectorPoint3D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source.cartesian.SideSetVectorPoint3D,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        fr: float,
        ft: float,
        fp: float,
        side_set_name: str,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D vector side-set source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver below the specified side set.
  • radius_of_sphere_in_m float — Planet radius used for the initial guess of the receiver. Can be a really rough estimate.
  • fr float — R component of the force in N.
  • ft float — T component of the force in N.
  • fp float — P component of the force in N.
  • side_set_name str — Name of the side at which to place the receiver.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict

SideSetVectorPoint3DZNE

class SideSetVectorPoint3DZNE(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source.cartesian.SideSetVectorPoint3D,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        fz: float,
        fn: float,
        fe: float,
        side_set_name: str,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D vector side-set source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver below the specified side set.
  • radius_of_sphere_in_m float — Planet radius used for the initial guess of the receiver. Can be a really rough estimate.
  • fz float — Z component of the force in N.
  • fn float — N component of the force in N.
  • fe float — E component of the force in N.
  • side_set_name str — Name of the side at which to place the receiver.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict

VectorGradientPoint2D

class VectorGradientPoint2D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source._BaseSource,
):
    def __init__(
        self,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        grr: float,
        grp: float,
        gpr: float,
        gpp: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 2-D vector gradient source.

Parameters
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver.
  • radius_of_sphere_in_m float — This class assumes a perfect sphere to derive the cartesian coordinates of the receiver. This is the radius of that sphere.
  • grr float — RR component of the gradient.
  • grp float — RP component of the gradient.
  • gpr float — PR component of the gradient.
  • gpp float — PP component of the gradient.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
apply()
def apply(self, d: Union[Dict, _DeepSetter]) -> None:
    ...

Set the contents with a dictionary.

Parameters
  • d Union[Dict, _DeepSetter] — The dictionary to set.
Returns None
copy()
def copy(self) -> _DeepSetter:
    ...

Return a deep copy of the object.

Returns _DeepSetter
get_dictionary()
def get_dictionary(self) -> Dict:
    ...

Get the contents of this object as a dictionary.

Returns Dict
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict
validate()
def validate(self) -> None:
    ...

Validates the current state of the configuration against its schema.

Returns None

VectorGradientPoint3D

class VectorGradientPoint3D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source._BaseSource,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        grr: float,
        grt: float,
        grp: float,
        gtr: float,
        gtt: float,
        gtp: float,
        gpr: float,
        gpt: float,
        gpp: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D vector gradient source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver.
  • radius_of_sphere_in_m float — This class assumes a perfect sphere to derive the cartesian coordinates of the receiver. This is the radius of that sphere.
  • grr float — RR component of the gradient.
  • grt float — RT component of the gradient.
  • grp float — RP component of the gradient.
  • gtr float — TR component of the gradient.
  • gtt float — TT component of the gradient.
  • gtp float — TP component of the gradient.
  • gpr float — PR component of the gradient.
  • gpt float — PT component of the gradient.
  • gpp float — PP component of the gradient.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
apply()
def apply(self, d: Union[Dict, _DeepSetter]) -> None:
    ...

Set the contents with a dictionary.

Parameters
  • d Union[Dict, _DeepSetter] — The dictionary to set.
Returns None
copy()
def copy(self) -> _DeepSetter:
    ...

Return a deep copy of the object.

Returns _DeepSetter
get_dictionary()
def get_dictionary(self) -> Dict:
    ...

Get the contents of this object as a dictionary.

Returns Dict
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict
validate()
def validate(self) -> None:
    ...

Validates the current state of the configuration against its schema.

Returns None

VectorPoint2D

class VectorPoint2D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source._BaseSource,
):
    def __init__(
        self,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        fr: float,
        fp: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 2-D vector source.

Parameters
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver.
  • radius_of_sphere_in_m float — This class assumes a perfect sphere to derive the cartesian coordinates of the receiver. This is the radius of that sphere.
  • fr float — R component of the force in N.
  • fp float — P component of the force in N.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
apply()
def apply(self, d: Union[Dict, _DeepSetter]) -> None:
    ...

Set the contents with a dictionary.

Parameters
  • d Union[Dict, _DeepSetter] — The dictionary to set.
Returns None
copy()
def copy(self) -> _DeepSetter:
    ...

Return a deep copy of the object.

Returns _DeepSetter
get_dictionary()
def get_dictionary(self) -> Dict:
    ...

Get the contents of this object as a dictionary.

Returns Dict
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict
validate()
def validate(self) -> None:
    ...

Validates the current state of the configuration against its schema.

Returns None

VectorPoint3D

class VectorPoint3D(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source._BaseSource,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        fr: float,
        ft: float,
        fp: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D vector source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver.
  • radius_of_sphere_in_m float — This class assumes a perfect sphere to derive the cartesian coordinates of the receiver. This is the radius of that sphere.
  • fr float — R component of the force in N.
  • ft float — T component of the force in N.
  • fp float — P component of the force in N.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
apply()
def apply(self, d: Union[Dict, _DeepSetter]) -> None:
    ...

Set the contents with a dictionary.

Parameters
  • d Union[Dict, _DeepSetter] — The dictionary to set.
Returns None
copy()
def copy(self) -> _DeepSetter:
    ...

Return a deep copy of the object.

Returns _DeepSetter
get_dictionary()
def get_dictionary(self) -> Dict:
    ...

Get the contents of this object as a dictionary.

Returns Dict
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict
validate()
def validate(self) -> None:
    ...

Validates the current state of the configuration against its schema.

Returns None

VectorPoint3DZNE

class VectorPoint3DZNE(
    salvus.flow.simple_config.coordinate_system_utils._SeismologyBase,
    salvus.flow.simple_config.source._BaseSource,
):
    def __init__(
        self,
        latitude: float,
        longitude: float,
        depth_in_m: float = 0.0,
        radius_of_sphere_in_m: float = 6371000.0,
        fz: float,
        fn: float,
        fe: float,
        source_time_function: Optional[
            salvus.flow.simple_config.stf._Base
        ] = None,
        rotation_on_input: Optional[Dict] = None,
        reference_time_utc_string: Optional[str] = None,
    ):
        ...

Seismological 3-D vector source.

Parameters
  • latitude float — The latitude in degree.
  • longitude float — The longitude in degree.
  • depth_in_m float — The depth in meters of the receiver.
  • radius_of_sphere_in_m float — This class assumes a perfect sphere to derive the cartesian coordinates of the receiver. This is the radius of that sphere.
  • fz float — R component of the force in N.
  • fn float — T component of the force in N.
  • fe float — P component of the force in N.
  • source_time_function Optional[salvus.flow.simple_config.stf._Base] — Source time function.
  • rotation_on_input Optional[Dict] — Transform the input STF according to this matrix.
  • reference_time_utc_string Optional[str] — Reference time for the source. Usually equal to the origin time. If it is set, the reference time for whole simulation will be set to this time.
Methods
from_json()
def from_json(d: Dict) -> Any:
    ...

Recreate the object from a dictionary serialization of its initialization parameters.

Parameters
  • d Dict — Dictionary containing its init parameters and a few other things.
Returns Any
apply()
def apply(self, d: Union[Dict, _DeepSetter]) -> None:
    ...

Set the contents with a dictionary.

Parameters
  • d Union[Dict, _DeepSetter] — The dictionary to set.
Returns None
copy()
def copy(self) -> _DeepSetter:
    ...

Return a deep copy of the object.

Returns _DeepSetter
get_dictionary()
def get_dictionary(self) -> Dict:
    ...

Get the contents of this object as a dictionary.

Returns Dict
to_json()
def to_json(self, external_file_hash: Optional[str] = None) -> Dict:
    ...

Serialize the object to dictionary that can be written to JSON.

Parameters
  • external_file_hash Optional[str] — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.
Returns Dict
validate()
def validate(self) -> None:
    ...

Validates the current state of the configuration against its schema.

Returns None

Exceptions

SalvusFlowSourceParseError

Raised if a source file could not be parsed.