This blog is an excerpt from the Tecplot 360 Best Practices section of our Data Format Guide.
If you wish to generate native Tecplot 360 data files automatically from applications such as complex flow solvers, you have a number of options for outputting data into a format compatible with Tecplot. This blog outlines a few “best practices” for doing so.
1. Create Binary Data Files instead of ASCII
Binary data files (.plt or .szplt) are more efficient than ASCII files (.dat), in terms of disk space and time to first image. To create binary data files, you may use functions provided in the TecIO library. To create ASCII files, you can write out plain text in the usual manner. There are some cases where ASCII files are preferred.
Create ASCII files when:
- Your data files are small.
- Your application runs on a platform for which the TecIO library is not provided. If this is the case, please contact us at email@example.com. There may be a way to resolve this issue.
- You wish users to be able to view or edit the data in a text editor.
2. Offer the Option to Write SZL Files
SZL (pronounced “sizzle”) or Subzone-Load-on Demand is a technology that makes it possible to more quickly load and analyze large data files in Tecplot 360. SZL file format uses an .szplt file extension. Read more about SZL Technology
- SZL file format improves the experience, especially for large, 3-dimensional, non-Polyhedral cases.
- Use TECFLUSH142 to reduce memory usage when writing SZL files. TECFLUSH142 must be called after writing a complete zone. More information on TECFLUSH142 can be found in the Binary Data File Function Reference section of the Data Format Guide.
- Use SZL to allow Read capability.
3. Use Block Format instead of Point Format
Block format is by far the most efficient format when it comes to loading a file into Tecplot 360. If your data files are small and you can only obtain the data in a point-like format (for example, with a spreadsheet), then using point format is acceptable. Binary files can only be written in block format. Point format is allowed for ASCII files, but running the Preplot utility will convert the data to block format.
4. Add Auxiliary data to Preset Variable Assignments in Tecplot 360
Zone Auxiliary data can be used to give Tecplot 360 hints about properties of your data. For example, it can be used to set the defaults for which variables to use for certain kinds of plots. Auxiliary data is supported by both binary and ASCII formats.
More information can be found for binary data TECAUXSTR142 in the Binary Data File Function Reference section, and for ASCII data in the Data Set Auxiliary Data Record section of the Data Format Guide.
5. Transient Data
- Data Sharing
- Share variables whenever possible.
Variable sharing is commonly used for the spatial variables (X, Y, and Z) when you have many sets of data that use the same basic grid. This saves disk space, as well as memory when the data is loaded into Tecplot 360. In addition, the benefits are compounded with scratch data derived from these variables because it is also shared within Tecplot 360.
- Do not share variables between 3D and 2D zones
- Share variables whenever possible.
- Consider using Grid and Solution files for transient data.
- Use one object or mesh per StrandID which consists of multiple solution times. More information for binary data TECZNE142 in the Binary Data File Function Reference section, and for ASCII data in the Variable and Connectivity List Sharing section of the Data Format Guide.
6. Parallel Output
- Use TecIO-MPI which writes SZL files in parallel.
- Be sure to write to a parallel file system.
- Maximize striping for efficiency.
7. Passive Variables
Tecplot 360 can manage many data sets at the same time. However, within a given data set you must supply the same number of variables for each zone. In some cases, you may have data where there are many variables and, for some of the zones some of those variables are not important or not calculated. You can set selected variables in those zones to be passive. A passive variable is one that will always return the value zero if queried (e.g. in a probe) but will not involve itself in operations such as the calculations of the min and max range. This is very useful when calculating default contour levels.
8. Use the Native Byte Ordering for the Target Machine
When you create binary data, you can elect to produce these files in either Motorola (big- endian) byte order or Intel (little-endian) byte order. Today’s most popular platforms all use Intel byte order, and generally this is the order you should use when writing binary data. The exceptions involve older platforms no longer supported by Tecplot. If you are using such legacy platforms, it can improve performance to write the binary data in the order native to the platform on which it will be viewed, if this is known, even though Tecplot 360 will load data with either byte order.
NOTE: SZL doesn’t support big-endian byte ordering and only supports Native Byte Ordering at this time. TECFOREIGN142 has not yet been implemented in the SZL API. See more about TECFOREIGN142 in the Binary Data File Function Reference section of the Data Format Guide.
9. Use TECNODE instead of TECNOD to more flexibly specify the finite-element connectivity list (node list)
TECNOD requires you to provide the entire connectivity list for the zone while TECNODE allows you to give the connectivity list in chunks of specified size. It is often memory-inefficient to build the full connectivity list – especially if the data has mixed element types. Using TECNODE avoids this problem.
For help using TecIO, please email firstname.lastname@example.org or call our support line at 425-653-9393.
Chief Technical Officer