simpeg.electromagnetics.frequency_domain.Fields3DCurrentDensity#

class simpeg.electromagnetics.frequency_domain.Fields3DCurrentDensity(simulation)[source]#

Bases: FieldsFDEM

Fields class for storing 3D current density solutions.

This class stores the total current density solution computed using a frequency_domain.Simulation3DCurrentDensity simulation object. This class can be used to extract the following quantities:

  • 'j', 'jPrimary', 'jSecondary' and 'e' on mesh faces.

  • 'h', 'hPrimary', 'hSecondary' and 'b' on mesh edges.

  • 'charge' and 'charge_density' at cell centers.

See the example below to learn how fields can be extracted from a Fields3DCurrentDensity object.

Parameters:
simulationfrequency_domain.Simulation3DCurrentDensity

The FDEM simulation object associated with the fields.

Attributes

aliasFields

The aliased fields of the object.

approxSize

Approximate cost of storing all of the known fields in MB.

dtype

Python data type(s) used to store the fields.

knownFields

The field solutions and where they are discretized on the mesh.

mesh

Mesh used by the simulation.

simulation

The simulation object used to compute the field solution.

survey

Survey used by the simulation.

Methods

startup()

Run startup to connect the simulation's discrete attributes to the fields object.

Examples

The Fields3DCurrentDensity object stores the total current density solution on mesh faces. To extract the discrete current density and magnetic field:

f = simulation.fields(m)
j = f[:, 'j']
h = f[:, 'h']

The array j returned will have shape (n_faces, n_sources). And the array h returned will have shape (n_edges, n_sources). We can also extract the fields for a subset of the source list used for the simulation as follows:

f = simulation.fields(m)
j = f[source_list, 'j']
h = f[source_list, 'h']