Calculate Lambda-2 Criterion

Problem: How do I calculate the Lambda-2 criterion? Solution: Use a Tecplot Macro to automate the calculation. Make sure Tecplot is aware of the variables representing your velocity field (Analyze->Field Variables menu).   The commands are as follow: Calculate the tensor of velocity gradients. This command can be obtained by recording the Analyze->Calculate Variables…->Velocity Gradient (tensor) action in Tecplot’s graphical user interface (GUI). $!EXTENDEDCOMMAND COMMANDPROCESSORID = ‘CFDAnalyzer4’ COMMAND = ‘Calculate […]

» Read More


Precise Probe to Create Time Series Plot

Problem: How do I Probe to Create Time Series Plot at a given set of coordinates? Solution: Use Tecplot’s macro language to precisely define the point to probe. The commands are as follow: Prompt for the (X, Y, Z) coordinates of the point to probe: $!PROMPTFORTEXTSTRING |xPosition| INSTRUCTIONS = “Enter X position of the probe.” Or define them directly in the macro: $!VARSET |xPosition|= 0.1 Pass these coordinates to the […]

» Read More


Extract Vortex Cores over time

Problem: How do I extract vortex cores over time? Solution: Use a Tecplot Macro to loop over time and extract the vortex cores at each time step. Make sure Tecplot is aware of the variables representing your velocity field (Analyze->Field Variables menu).   The commands are as follow: Retrieve the number of time steps $!EXTENDEDCOMMAND COMMANDPROCESSORID=’extend time mcr’ COMMAND=’QUERY.NUMTIMESTEPS NUMTIMESTEPS’ Loop over time $!LOOP |NUMTIMESTEPS| $!EXTENDEDCOMMAND COMMANDPROCESSORID=’extend time mcr’ COMMAND=’SET.CURTIMESTEP […]

» Read More


Load Multiple Files at Once with a Macro

Problem: I have many files that need to be loaded into Tecplot but loading them all is tedious. I want to load multiple files at once without having to select each individual file. Solution: For files that only differ by a constant, PyTecplot or macro scripts can be configured to load your datasets quickly and accurately. For example, if you have a directory containing many files: file001.plt file002.plt etc. You […]

» Read More