DAT to DAT: Difference between revisions

Content deleted Content added
No edit summary
No edit summary
Line 1:
<ol>
<br><br>=Introduction=
<br><br>
This utility performs a variety of operations on the TUFLOW 2D outputs. Valid formats are .xmdf (as of utility version 2012-10-AC) and .dat files. This page is split into two section, utility operations (e.g. maximum, difference etc.) and general options. The general options can be used regardless of operation being performed. The table of contents can be used to jump to a desired operation.
<font size=125%; color="red">This pages is being updated to include the latest version of the utility which supports .xmdf format resutls</font>
<br><br>=Introduction=
We are currently working on an updated version of the dat_to_dat utility which includes support for the XMDF file type. This page will be updated when this is complete.
 
=Operations=
ThisThe section of the con table below contains a list of operationthe operations that the utility can perform. Additional input options are included in the next section. One of thethese operations frommust thisbe sectionspecified mustor bethe includedutility inwill thegenerate inputan argumenterror.
 
==Max==
Line 22 ⟶ 20:
<u>Description</u><br>
This can be used to compare two datasets. If a third files is specified, the third file is used as the output file. The output filename can also be specified with the -out option. The output is the first results minus the second result file.<br>
A special wet/dry algorithm is used. If water level results are not specified (_h.dat or -typeH), the algorithm opens these files, as well as opens the .2dm file associated with the results files, and uses the water levels and ZH Zpt values (for 2D cells) and elevations at the WLL triangle corners to determine whether a node (corner of an mesh element) is wet or dry. This allows two special values to be output in the event that a node is dry in one results file and wet in the other or vicavice versa. A value of 99 is used to indicate that a node is dry in the first results file, but is flooded in the second resuiltsresults file, while +99 indicates that the node was wet in the first results file but is dry in the second results file. Specifying '''-nowetdry''' does not carry out a wet/dry check using the water level results.
<br>
The -t option can be used to carry out the difference at a particular time (rather than all times). The most common time is to take the difference at the flood peak, ie. specify t99999.<br>
Line 92 ⟶ 90:
Creates an an output file with the specified filename "xmdf_info.txt", which contains information about the contents of the xmdf file.
 
==VelocityVector Angle==
'''Input Switch: -va'''<br>
<u>Description</u><br>
Outputs the vector direction in degrees relative to north (North = 0°, East = 90°, South = 180°/-180°, West = -90°).
 
<u>Examples</u><br>
<li><tt>dat_to_dat.exe -va results_v.dat</tt></li>
 
Outputs the velocity direction for all timesteps in the results_V.dat file.
==Concatenate==
'''Input Switch: -con'''<br>
<u>Description</u><br>
Concatenates (joins) two or more results files into one. Each results file must be from the same 1D/2D mesh.
 
<u>Examples</u><br>
<li><tt>dat_to_dat.exe -con results1_h.dat results2_h.dat results3_h.dat</tt></li>
Joins the three files into a single .dat file.
<li><tt>dat_to_dat.exe -con -typeH results1.xmdf results2.xmdf results3.xmdf</tt></li>
Joins the water level results contained in the .xmdf files into a single
 
==Convert==
'''Input Switch: -conv'''<br>
<u>Description</u><br>
Converts between .dat and .xmdf format results. Not to be confused with -con (concatenate option described above)!
 
<u>Examples</u><br>
<li><tt>dat_to_dat.exe -conv -typeH -t99999 results1.xmdf</tt></li>
Converts the maximum water level results in the xmdf file into .dat file format.
<li><tt>dat_to_dat.exe -conv results1.xmdf</tt></li>
Converts all datasets and times in the .xmdf file into .dat file format. This will output a number of .dat files.
<li><tt>dat_to_dat.exe -conv results1_h.dat</tt></li>
Converts all times in the .dat file into xmdf file format.
 
==Ensight (beta)==
'''Input Switch: -ensight'''<br>
<u>Description</u><br>
Converts an .xmdf file (.dat not yet supported) into Ensight Gold format.<br>
If the input dataset is corner based (standard output) the Ensight results are output as scalar / vector '''per node''' (cell and triangle corners).<br>
If the result is high resolution (Map Output Format == xmdf high res) then the Ensight results are '''per element'''. For 2D cells this is based on the cell centre output, for triangles (1D water level lines) this is based on an interpolation of the triangle vertices.
The conversion produces the following output files:<br>
* Ensight case file;
* Ensight geometry file;
* Ensight results as either per node or per element depending on the input file.
'''This conversion is in beta stage and any feedback can be sent to support@tuflow.com.<br>
<u>Examples</u><br>
<li><tt>dat_to_dat.exe -ensight results1.xmdf</tt></li>
Converts all datasets in the xmdf file into Ensight format.
 
<u>Examples</u><br>
=General Options=
==Batch Mode==
For examples on the current dat_to_dat utility please see section 11.3 of the 2010 TUFLOW manual.
'''Input Switch: -b'''<br>
Batch mode suppresses prompt to press Enter at end of processing. Used in .bat files where two or more files are to be processed in succession.
==Output Filename==
'''Input Switch: -out "output_filename"'''<br>
Sets the output filename.
 
{{Tips Navigation
|uplink=[[TUFLOW_Utilities | Back to TUFLOW Utilities]]