Define data postprocessing operations for PETGEM.

petgem.postprocessing.computeImpedance(fields, omega, mu)[source]

Compute apparent resistiviy, phase, tipper and impedance for MT mode.

  • fields (list) – list of numpy arrays with electromagnetic fields with dimensions = (number_polarizations, number_receivers, number_EM_components)

  • omega (float) – angular frequency

  • mu (float) – medium permeability.


apparent resistivity, phase, tipper and impedance.

Return type


petgem.postprocessing.fieldInterpolator(solution_vector, nodes, elemsN, elemsE, edgesN, elemsF, facesE, dof_connectivity, points, inputSetup)[source]

Interpolate electromagnetic field for a set of 3D points.

  • solution_vector (ndarray-petsc) – vector field to be interpolated

  • nodes (ndarray) – nodal coordinates

  • elemsN (ndarray) – elements-node connectivity with dimensions = (number_elements, 4)

  • elemsE (ndarray) – elements-edge connectivity with dimensions = (number_elements, 6)

  • edgesN (ndarray) – edge-node connectivity with dimensions = (number_edges, 2)

  • elemsF (ndarray) – element-faces connectivity with dimensions = (number_elements, 4)

  • facesE (ndarray) – face-edges connectivity with dimensions = (number_faces, 3)

  • dof_connectivity (ndarray) – local/global dofs list for elements, dofs index on edges, dofs index on faces, dofs index on volumes, total number of dofs

  • points (ndarray) – point coordinates

  • inputSetup (obj) – inputSetup object.


electromagnetic fields for a set of 3D points

Return type

ndarray and int


Unitary test for script.