json_output_data_t Derived Type

type, public :: json_output_data_t

Unified container for all JSON output data

This type consolidates all data needed to write JSON output for any calculation type (unfragmented, MBE, GMBE PIE). The output_mode field determines which format to use when writing JSON.


Inherits

type~~json_output_data_t~~InheritsGraph type~json_output_data_t json_output_data_t type~thermochemistry_result_t thermochemistry_result_t type~json_output_data_t->type~thermochemistry_result_t thermo

Components

Type Visibility Attributes Name Initial
real(kind=dp), public, allocatable :: delta_energies(:)

MBE delta corrections

real(kind=dp), public, allocatable :: dipole(:)

(3)

real(kind=dp), public, allocatable :: force_constants(:)

mdyne/Angstrom

integer(kind=int64), public :: fragment_count = 0
real(kind=dp), public, allocatable :: fragment_distances(:)

Per-fragment min distances (Angstrom)

real(kind=dp), public, allocatable :: fragment_energies(:)

Per-fragment total energies

real(kind=dp), public, allocatable :: frequencies(:)

cm^-1

real(kind=dp), public, allocatable :: gradient(:,:)

(3, natoms)

logical, public :: has_dipole = .false.
logical, public :: has_energy = .false.
logical, public :: has_gradient = .false.
logical, public :: has_hessian = .false.
logical, public :: has_ir_intensities = .false.
logical, public :: has_vibrational = .false.
real(kind=dp), public, allocatable :: hessian(:,:)

(3natoms, 3natoms)

real(kind=dp), public, allocatable :: ir_intensities(:)

km/mol

integer, public :: max_level = 0
integer(kind=int64), public :: n_pie_terms = 0
integer, public :: output_mode = OUTPUT_MODE_NONE

OUTPUT_MODE_* constant

integer, public, allocatable :: pie_atom_sets(:,:)

Unique atom sets (max_atoms, n_terms)

integer, public, allocatable :: pie_coefficients(:)

PIE coefficients

real(kind=dp), public, allocatable :: pie_energies(:)

Per-term energies

integer, public, allocatable :: polymers(:,:)

Fragment composition (n_fragments, max_level)

real(kind=dp), public, allocatable :: reduced_masses(:)

amu

real(kind=dp), public, allocatable :: sum_by_level(:)

Energy sum per level

type(thermochemistry_result_t), public :: thermo
real(kind=dp), public :: total_energy = 0.0_dp

Type-Bound Procedures

procedure, public :: destroy => json_output_data_destroy

procedure, public :: reset => json_output_data_reset

Source Code

   type :: json_output_data_t
      !! Unified container for all JSON output data
      !!
      !! This type consolidates all data needed to write JSON output for any
      !! calculation type (unfragmented, MBE, GMBE PIE). The output_mode field
      !! determines which format to use when writing JSON.

      integer :: output_mode = OUTPUT_MODE_NONE  !! OUTPUT_MODE_* constant

      !----- Common data -----
      real(dp) :: total_energy = 0.0_dp
      real(dp), allocatable :: gradient(:, :)     !! (3, natoms)
      real(dp), allocatable :: hessian(:, :)      !! (3*natoms, 3*natoms)
      real(dp), allocatable :: dipole(:)          !! (3)
      logical :: has_energy = .false.
      logical :: has_gradient = .false.
      logical :: has_hessian = .false.
      logical :: has_dipole = .false.

      !----- Vibrational data (optional) -----
      real(dp), allocatable :: frequencies(:)        !! cm^-1
      real(dp), allocatable :: reduced_masses(:)     !! amu
      real(dp), allocatable :: force_constants(:)    !! mdyne/Angstrom
      real(dp), allocatable :: ir_intensities(:)     !! km/mol
      type(thermochemistry_result_t) :: thermo
      logical :: has_vibrational = .false.
      logical :: has_ir_intensities = .false.

      !----- MBE-specific data (store ALL fragments for detailed output) -----
      integer, allocatable :: polymers(:, :)          !! Fragment composition (n_fragments, max_level)
      real(dp), allocatable :: fragment_energies(:)   !! Per-fragment total energies
      real(dp), allocatable :: delta_energies(:)      !! MBE delta corrections
      real(dp), allocatable :: sum_by_level(:)        !! Energy sum per level
      real(dp), allocatable :: fragment_distances(:)  !! Per-fragment min distances (Angstrom)
      integer(int64) :: fragment_count = 0
      integer :: max_level = 0

      !----- GMBE PIE-specific data -----
      integer, allocatable :: pie_atom_sets(:, :)     !! Unique atom sets (max_atoms, n_terms)
      integer, allocatable :: pie_coefficients(:)     !! PIE coefficients
      real(dp), allocatable :: pie_energies(:)        !! Per-term energies
      integer(int64) :: n_pie_terms = 0

   contains
      procedure :: destroy => json_output_data_destroy
      procedure :: reset => json_output_data_reset
   end type json_output_data_t