Skip to content

Write RFC file

Expected behavior

Output the trajectory in the RFC format.

Initial state

Variation: "GMT"

Input variables

Variable name Description
floatdetails The FLOAT section stored in an RFB file.
interpolated Flag that tells if the line is interpolated
line_number The line number
rafos_day The rafos day
temperature temperature array
pressure pressure array
lat latitude array
lon longitude array
u velocity array
v veloctiy array
w veloctiy array

Output parts

Header part

The header part always consists of the following text. All uppercase text is replaced by a variable:

** Float: FLOATNAME
** Variables: InterpFlag LineNum RafosDay  Temp  Pres  Lat  Lon  U     V     W
** Units    : #          #       #         degC  dbar  deg  deg  cm/s  cm/s  mm/s
** Dummies  : NA         NA      NA        -9.99 -999  999  999   999   999   999
** Cycle    : CURRENTCYCLE
** Launch position (Cycle Start position): LAT LON
** Surface position (Cycle End position) : LAT LON
** Cycle Start time             : YYYY MM DD HH mm ss (RAFOS day RAFOSCYCLESTARTTIME)
** Launch time                  : LAUNCHTIME
** Cycle End time               : YYYY MM DD HH mm ss (RAFOS day RAFOSCYCLEENDTIME)
** First surface Position time  : RECOVERTIME0 (RAFOS day RAFOSRECOVERTIME)

The 0 after RECOVERTIME is hard coded into the generation.

Data part

If the data part is empty, the following string will be appended:

** -------
 *   No trajectory information, flt not tracked.
Shortname Description Value/Format Default value
[IFLAG] The interpolation flag [#] 12.2d
[MESSAGE_NUMBER] The message number [#] 12.3d
[MESSAGE_DATE] Rafos date [#] 12.2f
[TEMP] Temperature [degC] 12.3f -9.99
[PRES] Pressure [dBar] 12.1f -999
[LAT] Latitude [deg] 12.3f -999
[LON] Longitude [deg] 12.3f -999
[u] Velocity [cm/s] 12.2f -999
[v] Velocity [cm/s] 12.2f -999
[w] Velocity [mm/s] 12.2f -999

Output of one line

[IFLAG] [MESSAGE_NUMBER] [MESSAGE_DATE] [TEMP] [PRES] [LAT] [LON] [u] [v] [w]

EDIT: Updated the input variables.

EDIT: Updated output line variables.

EDIT: Updated header representation.

EDIT: Updated description when tracking has not been done yet.

Edited by Olaf Boebel