TARANG.lib.io.io_scalar#

Functions#

initial_scalar(para, U, T)

Initialize the hydrodynamic and scalar field based on the input parameters.

output_scalar(para, t, U, T, univ)

Output the scalar field and global quantities at a given time step.

output_field_scalar(para, t, U, T, univ)

Save the hydrodynamic and scalar field data to a file.

output_glob_scalar(para, t, U, T, univ)

Save global hydrodynamic and scalar quantities such as energy and dissipation to a file.

output_modes_scalar(para, t, U, T, univ)

Save specific modes of the hydrodynamic and scalar field to a file.

output_ekTk_scalar(para, t, U, T, univ)

Save the energy and transfer spectra of the hydrodynamic and scalar field to a file.

init_save_scalar(para, U, T)

Initialize files for saving energy and transfer spectra, global hydrodynamic quantities,

file_save_scalar(para, U, T, univ)

Save the energy and transfer spectra, global hydrodynamic quantities, field save times,

Module Contents#

TARANG.lib.io.io_scalar.initial_scalar(para, U, T)#

Initialize the hydrodynamic and scalar field based on the input parameters.

Parameters:
  • U (VectorField) – VectorField object representing the velocity field.

  • T (ScalarField) – ScalarField object representing the scalar field.

Return type:

None

TARANG.lib.io.io_scalar.output_scalar(para, t, U, T, univ)#

Output the scalar field and global quantities at a given time step.

Parameters:
  • t (float) – Current time.

  • U (VectorField) – VectorField object representing the velocity field.

  • T (ScalarField) – ScalarField object representing the scalar field.

  • univ (UniversalArrays) – UniversalArrays object for temporary storage and global quantities.

Return type:

None

TARANG.lib.io.io_scalar.output_field_scalar(para, t, U, T, univ)#

Save the hydrodynamic and scalar field data to a file.

Parameters:
  • t (float) – Current simulation time.

  • U (VectorField) – VectorField object representing the velocity field.

  • T (ScalarField) – ScalarField object representing the scalar field.

  • univ (UniversalArrays) – UniversalArrays object for temporary storage.

Return type:

None

TARANG.lib.io.io_scalar.output_glob_scalar(para, t, U, T, univ)#

Save global hydrodynamic and scalar quantities such as energy and dissipation to a file.

Parameters:
  • t (float) – Current simulation time.

  • U (VectorField) – VectorField object representing the velocity field.

  • T (ScalarField) – ScalarField object representing the scalar field.

  • univ (UniversalArrays) – UniversalArrays object for temporary storage and global quantities.

Return type:

None

TARANG.lib.io.io_scalar.output_modes_scalar(para, t, U, T, univ)#

Save specific modes of the hydrodynamic and scalar field to a file.

Parameters:
  • t (float) – Current simulation time.

  • U (VectorField) – VectorField object representing the velocity field.

  • T (ScalarField) – ScalarField object representing the scalar field.

  • univ (UniversalArrays) – UniversalArrays object for temporary storage.

Return type:

None

TARANG.lib.io.io_scalar.output_ekTk_scalar(para, t, U, T, univ)#

Save the energy and transfer spectra of the hydrodynamic and scalar field to a file.

Parameters:
  • t (float) – Current simulation time.

  • U (VectorField) – VectorField object representing the velocity field.

  • T (ScalarField) – ScalarField object representing the scalar field.

  • univ (UniversalArrays) – UniversalArrays object for temporary storage.

Return type:

None

TARANG.lib.io.io_scalar.init_save_scalar(para, U, T)#

Initialize files for saving energy and transfer spectra, global hydrodynamic quantities, field save times, time steps, and specific modes of the hydrodynamic field.

Parameters:
  • U (VectorField) – VectorField object representing the velocity field.

  • T (ScalarField) – ScalarField object representing the scalar field.

Return type:

None

TARANG.lib.io.io_scalar.file_save_scalar(para, U, T, univ)#

Save the energy and transfer spectra, global hydrodynamic quantities, field save times, time steps, and specific modes of the hydrodynamic field to their respective files.

Parameters:
  • U (VectorField) – VectorField object representing the velocity field.

  • T (ScalarField) – ScalarField object representing the scalar field.

  • univ (UniversalArrays) – UniversalArrays object for temporary storage and global quantities.

Return type:

None