simpeg.maps.ParametricLayer#

class simpeg.maps.ParametricLayer(mesh, **kwargs)[source]#

Bases: BaseParametric

Mapping for a horizontal layer within a wholespace.

This mapping is used when the cells lying below the Earth’s surface can be parameterized by horizontal layer within a homogeneous medium. The model is defined by the physical property value for the background (\(\sigma_0\)), the physical property value for the layer (\(\sigma_1\)), the elevation for the middle of the layer (\(z_L\)) and the thickness of the layer \(h\).

For this mapping, the set of input model parameters are organized:

\[\mathbf{m} = [\sigma_0, \;\sigma_1,\; z_L , \; h]\]

The mapping \(\mathbf{u}(\mathbf{m})\) from the model to the mesh is given by:

\[\mathbf{u}(\mathbf{m}) = \sigma_0 + \frac{(\sigma_1 - \sigma_0)}{\pi} \Bigg [ \arctan \Bigg ( a \bigg ( \mathbf{z_c} - z_L + \frac{h}{2} \bigg ) \Bigg ) - \arctan \Bigg ( a \bigg ( \mathbf{z_c} - z_L - \frac{h}{2} \bigg ) \Bigg ) \Bigg ]\]

where \(\mathbf{z_c}\) is a vectors containing the vertical cell center locations for all active cells in the mesh, and \(a\) is a parameter which defines the sharpness of the boundaries between the layer and the background.

Parameters:
meshdiscretize.BaseMesh

A discretize mesh

active_cellsnumpy.ndarray, optional

Active cells array. Can be a boolean numpy.ndarray of length mesh.nC or a numpy.ndarray of int containing the indices of the active cells.

slopefloat

Directly define the constant a in the mapping function which defines the sharpness of the boundaries.

slopeFactfloat

Scaling factor for the sharpness of the boundaries based on cell size. Using this option, we set a = slopeFact / dh.

indActivenumpy.ndarray

Deprecated since version 0.23.0: Argument indActive is deprecated in favor of active_cells and will be removed in SimPEG v0.24.0.

Attributes

indActive

active_cells.indActive has been deprecated.

is_linear

Determine whether or not this mapping is a linear operation.

mesh

The mesh used for the mapping

nP

Number of model parameters the mapping acts on; i.e 4

shape

Dimensions of the mapping

slope

Defines the sharpness of the boundaries.

slopeFact

Defines the slope scaled by the mesh.

x

X cell center locations (active) for the output of the mapping.

y

Y cell center locations (active) for the output of the mapping.

z

Z cell center locations (active) for the output of the mapping.

active_cells

Methods

deriv(m)

Derivative of the mapping with respect to the input parameters.

dot(map1)

Multiply two mappings to create a simpeg.maps.ComboMap.

inverse(D)

The transform inverse is not implemented.

mDict(m)

Return model parameters as a dictionary.

test([m, num, random_seed])

Derivative test for the mapping.

layer_cont

Examples

In this example, we define a layer in a wholespace whose interface is sharp. We construct the mapping from the model to the set of active cells (i.e. below the surface), We then use an active cells mapping to map from the set of active cells to all cells in the mesh.

>>> from simpeg.maps import ParametricLayer, InjectActiveCells
>>> from discretize import TensorMesh
>>> import numpy as np
>>> import matplotlib.pyplot as plt
>>> dh = 0.25*np.ones(40)
>>> mesh = TensorMesh([dh, dh])
>>> ind_active = mesh.cell_centers[:, 1] < 8
>>> sig0, sig1, zL, h = 5., 10., 4., 2
>>> model = np.r_[sig0, sig1, zL, h]
>>> layer_map = ParametricLayer(
>>>     mesh, active_cells=ind_active, slope=4
>>> )
>>> act_map = InjectActiveCells(mesh, ind_active, 0.)
>>> fig = plt.figure(figsize=(5, 5))
>>> ax = fig.add_subplot(111)
>>> mesh.plot_image(act_map * layer_map * model, ax=ax)

(Source code, png, pdf)

../../../_images/simpeg-maps-ParametricLayer-1.png

Galleries and Tutorials using simpeg.maps.ParametricLayer#

Maps: Parametric Block in a Layer

Maps: Parametric Block in a Layer

Maps: Parametrized Layer

Maps: Parametrized Layer

Heagy et al., 2017 Casing Example

Heagy et al., 2017 Casing Example