Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

subroutine deallocate_data_set (quantity)

Arrange a special subset for storing 2d averages.  The subset gets the name 'average'Deallocate all components of the structure.

Argument

Type

Intent

Description

quantity

type(eirene_data)

inout

Structure to be deallocated

...

subroutine read_quantity_from_file (file_name, quantity, report, io_unit)

Arrange a special subset for storing 2d averages.  The subset gets the name 'average'Read a physical quantity from a file with the format of EIRENE input tallies.

Argument

Type

Intent

Description

file_namecharacter(len=*)inFile name

quantity

type(eirene_data)

out

Structure to be filled with data from the file

reportlogical, optional (=false)inTurns on info about each step
io_unitinteger, optional (=69)inI/O unit to be used

...

subroutine write_quantity_to_file (file_name, quantity, report, io_unit)

Arrange a special subset for storing 2d averages.  The subset gets the name 'average'Write a physical quantity to a file with the format of EIRENE input tallies.

Argument

Type

Intent

Description

file_namecharacter(len=*)inFile name

quantity

type(eirene_data)

in

Structure holding data to be saved

reportlogical, optional (=false)inTurns on info about each step
io_unitinteger, optional (=69)inI/O unit to be used

...

Module imas_data_io

The module contains ??

Module constants

methods used for writing an EIRENE tally (given as a type(eirene_data)-structure) to IMAS IDS and, vice versa, reading it from IDS. The 'main_part' component is associated with the grid subset of all triangles (the subset identifier name 'pol3'); the 'average' component, with the subset having the name 'average'. 

It is a difficult choice to decide whether the methods should look for the subsets in the 'subset' AoS by their identifier names or by their dictionary indices (the idea to assign fixed places in the AoS to the subsets seems very bad because it can result in numerous bugs and confusions if it happens that the AoS requires changes). Now the subsets are found by their names. The main reason for this choice is that we have many subsets that have no standard dictionary indices (subsets of edges with given MPs, subset for averages). It is possible to introducing custom indices for them, but it seems a way to great confusion.

Module constants

 ! Name of the subset to which the values at all triangles are attached
character( ! Name of the subset to which the values at all triangles are attached
character(len=ids_string_length), parameter :: main_subset_label = 'pol3' 
 ! Name of the subset to which the average value is attached
character(len=ids_string_length), parameter :: average_subset_label = 'average'

The constants ????are the identifier names by which the subsets are found by the methods of this module when writing an EIRENE tally (given as a type(eirene_data)-structure) to IMAS IDS and, vice versa, reading it from IDS. The 'main_part' component is associated with the grid subset of all triangles; the 'average' component, with the subset having the name 'average'. 

 Methods provided

  • put_quantity_to_ids

  • get_quantity_from_ids

  • get_quantity_from_equilibrium

  • put_quantity_for_single_subset

  • get_quantity_for_single_subset

  • get_quantity_for_single_subset_in_equilibrium

...