postgkyl.diagnostics.mom.multispecies.energetics

postgkyl.diagnostics.mom.multispecies.energetics(elc, ion, field, *, gas_gamma=1.6666666666666667, num_moms=None, inplace=False, tag=None, label=None)

Decompose energy (kinetic, thermal, EM) for a two-species plasma.

Splits the plasma energy into its constituent parts for a two-species (electron/ion) plasma plus an EM field. The result carries the EM field’s grid and metadata and has seven components, in order:

  1. electron thermal energy

  2. electron kinetic energy

  3. ion thermal energy

  4. ion kinetic energy

  5. electric field energy (|E|^2 / 2)

  6. magnetic field energy (|B|^2 / 2)

  7. total energy (sum of the above)

Thermal energy is p/(gas_gamma-1) for five moments and half the pressure-tensor trace for ten moments, independent of gas_gamma.

Parameters:
  • elc – Electron fluid moments (used to compute internal and kinetic energy); must contain physical point values.

  • ion – Ion fluid moments (used to compute internal and kinetic energy); must contain physical point values.

  • field – EM field whose components 0:3 are the electric field and 3:6 are the magnetic field; its grid/metadata are carried to the output. Must contain physical point values.

  • gas_gamma – Adiabatic index, forwarded to the pressure/kinetic-energy calculation for both species.

  • num_moms – Number of moments (5 or 10) for both species; inferred from the component count when None.

  • inplace – mutate and return field instead of a new dataset.

  • tag – optional tag for the returned dataset.

  • label – optional label for the returned dataset.

Returns:

A seven-component dataset of the energy decomposition.

Raises:

ValueError – if any input contains unevaluated modal coefficients.

CLI: mom_multispecies_energetics