get_h_field

emg3d.fields.get_h_field(grid, model, field)[source]

Return magnetic field corresponding to provided electric field.

Retrieve the magnetic field \(\mathbf{H}\) from the electric field \(\mathbf{E}\) using Farady’s law, given by

\[\nabla \times \mathbf{E} = \rm{i}\omega\mu\mathbf{H} .\]

Note that the magnetic field in x-direction is defined in the center of the face defined by the electric field in y- and z-directions, and similar for the other field directions. This means that the provided electric field and the returned magnetic field have different dimensions:

E-field:  x: [grid.vectorCCx,  grid.vectorNy,  grid.vectorNz]
          y: [ grid.vectorNx, grid.vectorCCy,  grid.vectorNz]
          z: [ grid.vectorNx,  grid.vectorNy, grid.vectorCCz]

H-field:  x: [ grid.vectorNx, grid.vectorCCy, grid.vectorCCz]
          y: [grid.vectorCCx,  grid.vectorNy, grid.vectorCCz]
          z: [grid.vectorCCx, grid.vectorCCy,  grid.vectorNz]
Parameters:
grid : TensorMesh

Model grid; TensorMesh instance.

model : Model

Model; Model instance.

field : Field

Electric field; Field instance.

Returns:
hfield : Field

Magnetic field; Field instance.