Difference between revisions of "Outputs"

From Planets
Jump to: navigation, search
(the Xhistins.nc file)
 
(5 intermediate revisions by the same user not shown)
Line 5: Line 5:
 
</syntaxhighlight>
 
</syntaxhighlight>
  
to write down variables to either:
+
in physiq_mod to write down variables to both the diagfi.nc file, and the XIOS outputs (see below).
 +
<code>
 +
WARNING: '''both''' files will be written if you activate XIOS along with having variables in you diagfi.def file.
 +
</code>
 +
 
 +
The first parameter is the keyword for the variable, the second parameter is the long name (description) and the third the units.
 +
The function automatically finds the dimensions of the variable.
 +
 
 +
 
  
 
== the '''[[diagfi.nc]]''' file ==
 
== the '''[[diagfi.nc]]''' file ==
 
You can select the variables written in '''diagfi.nc''' using the [[diagfi.def]] configuration file.
 
You can select the variables written in '''diagfi.nc''' using the [[diagfi.def]] configuration file.
 +
A variable can also be written via the
 +
<syntaxhighlight lang="fortran">
 +
    call writediagfi(ngrid,"temperature","temperature","K",3,zt)
 +
</syntaxhighlight>
 +
which is the actual call made by ''write_output()''. This is the historical way of writing variables in the diagfi file, and is still done in other models.
 +
 
Please refer to [[diagfi.nc]] for more information.
 
Please refer to [[diagfi.nc]] for more information.
  
== XIOS outputs ==
+
== [[LMDZ XIOS outputs|XIOS outputs for LMDZ]] ==
  
 
XIOS outputs are generated in the case of using [[XIOS]] with LMDZ physics or when using [[DYNAMICO]].
 
XIOS outputs are generated in the case of using [[XIOS]] with LMDZ physics or when using [[DYNAMICO]].
Line 23: Line 37:
  
 
To select variables, use the '''[[LMDZ XIOS outputs#file_def_physics.xml|file_def_physics.xml]]''' file.
 
To select variables, use the '''[[LMDZ XIOS outputs#file_def_physics.xml|file_def_physics.xml]]''' file.
 +
 +
WARNING: you should probably use an '''empty diagfi.def''' to avoid also writing a diagfi.nc file.

Latest revision as of 11:00, 11 March 2025

Whether you use the Mars, Generic or Pluto PCM, you will use the routine

         call write_output("temperature","temperature","K",zt)

in physiq_mod to write down variables to both the diagfi.nc file, and the XIOS outputs (see below). WARNING: both files will be written if you activate XIOS along with having variables in you diagfi.def file.

The first parameter is the keyword for the variable, the second parameter is the long name (description) and the third the units. The function automatically finds the dimensions of the variable.


the diagfi.nc file

You can select the variables written in diagfi.nc using the diagfi.def configuration file. A variable can also be written via the

     call writediagfi(ngrid,"temperature","temperature","K",3,zt)

which is the actual call made by write_output(). This is the historical way of writing variables in the diagfi file, and is still done in other models.

Please refer to diagfi.nc for more information.

XIOS outputs for LMDZ

XIOS outputs are generated in the case of using XIOS with LMDZ physics or when using DYNAMICO. The main output will be the Xhistins.nc file (equivalent of the diagfi.nc file. Xhistins.nc can be renamed in your XML configuration files (see LMDZ XIOS outputs)

To compile with XIOS enabled, one must specify the option

 -io xios

To select variables, use the file_def_physics.xml file.

WARNING: you should probably use an empty diagfi.def to avoid also writing a diagfi.nc file.