Batch File Structure

In Pandat™, any calculation condition defined by user is automatically saved in a batch file. A batch file, which has an extension name of .pbfx, is written in the language of XML(Extensible Markup Language). Users do not need to be familiar with the format of a batch file, as Pandat automatically generates it after a calculation. However, user can easily modify it as wishes based on the generated file as a template. The purpose here is to explain the format and contents of a batch file.

A batch file contains several sections, the "Header" section, which starts by <Header copyright="CompuTherm, LLC"> and ends by </Header>, provides basic information about the Pandat™ version. The “Calculation” section, which starts with <calculation name="Example#1" type="section">, and ends with </calculation>, contains all the details about the calculation including the calculation conditions and output results setting. The keyword “type” defines the type of calculation.

Four subsections are included in the “Calculation” section. They are: Databases, Units, System and output.

Databases

This section defines the databases to be used in the calculation including the thermodynamic (or combined with mobility or property) database with name of .tdb or .pdb, and the kinetic parameter database, such as .kdb needed by PanEvolution module, .sdb by PanSolidification module, and .pfdb by PanPhaseField module. In the “file_name” field, if only database name is provided, the database and the batch file should locate in the same folder, otherwise the folder path where the database is located should be given. In the below example, the kdb file is located in the same folder as that of the batch file, while the tdb file is not.

<databases>

<database type="tdb" file_name="C:\..\Pandat 2024 Example book\AlNi_Prep.tdb" />

<database type="kdb" file_name="Ni-14Al_Precipitation.kdb" />

</databases>

Units

The section define the units used in the calculation and simulation. It is very important to check the units setting during the calculation and simulation. The values provided in system section are all corresponding to the units set here.

<units>

<unit name="T" value="C" />

<unit name="length" value="m" />

<unit name="n" value="x%" />

<unit name="time" value="hour" />

</units>

Note: If math operations are carried out in the output table, the output properties after math operations are in the SI units instead of the units set in the unit section . For example, the “time” unit is selected as “hour” here, but, the log10(time) value in output will be calculated using second as the unit of time.

System

Four subsections are included in the system section: Components; Phases; Points; and Conditions;

Components The components of the system are defined in this section.

<components>

<component name="Al" status="Selected" />

<component name="Mg" status="Selected" />

</components>

Phases The status of phases are defined in this section. The “*” means all phases in the system, the phase status can be set as “Entered”, “Suspended” and “Dormant”.

<phases>

<phase name="*" status="Entered" />

<phase name="Fcc" status="Suspended" />

<phase name="Liquid" status="Dormant" />

</phases>

Points Points defines the state variables of a particular point, such temperature, pressure, and composition. The units of these state points are defined in the Units section. For point calculation, and some other calculations, such as solidification, only one point needs to be defined here. Two points at the two ends are needed for a line calculation, and three points, corresponding to the three corners of the section, are required for a 2D section calculation.

<points>

<point>

<statespace>

<T value="300" />

<P value="1" />

<n component="Al" value="0.5" />

<n component="Mg" value="0.5" />

</statespace>

</point>

</points>

Condition Some advanced features in Pandat™ can be defined in the condition section, such as contour lines in PanPhaseDiagram module. Heat treatment schedule (time and temperature) needed in PanDiffusion, PanEvolution and PanSolidification modules are also defined in this condition section.

<condition>

<steps value="100" />

<contour name="isotherm_lines" property="T" step="0" interval="50">

<equilibrium_type value="" />

</contour>

</condition>

Output

Two subsections are included in the Output section: Tables and Graphs.

Tables Here user may define the properties to be included in a table. More than one table can be defined, with each table defined separately. As the example below, the first table is imported from “Al-Mg_Exp.dat” and named as “exp”. “</table>” means that it is the end of a table. The second table is the calculated “Default” table, including the calculated properties defined by the “column name”. If the table name is with the extension name of “.dat”, the .dat file will be output directly after the calculation. The .dat file will be saved in the same folder with that of the batch file if only the file name is provided, as shown by the third example table below. The .dat file can also save to a designated location if the file path is provided in the “Table name”.

The table “type” can be defined as “Default”, “Tie-line”, “Invariant”, “Invariant_Tieline”, “Contour” and “psd” in PanEvolution.

<tables>

<table source="Al-Mg_Exp.dat" name="exp" />

<table name="Default" source="Default" type="Default">

<column name="T" />

<column name="x(*)" />

<column name="phase_name" />

<column name="f(@*)" />

<column name="G" />

<column name="w(*)" />

</table>

<table name="Al-Mg_Calc.dat" source="Default" type="Default">

<column name="T" />

<column name="x(*)" />

<column name="phase_name" />

<column name="w(*)" />

</table>

<tables>

Graphs The graph settings are defined in Graphs section. The default graph type is Cartesian coordinates, but users can define the type = "triangle"to ploy Gibbs triangle diagrams, for example ternary isothermal sections: <graph name="AlMgZn_700K" type="triangle"> . The default plot type is line, users can also define it as “point”, “line”, and “linepoint” by setting as plot type="point". Below are two typical examples for Graphs.

Example 1: The graph for Al-Mg binary phase diagram

<graphs>

<graph name="2D_Al-Mg">

<plot table_name="Default" xaxis="x(Mg)" yaxis="T" />

<plot type="point" table_name="exp" xaxis="x(Mg)" yaxis="T" />

<plot table_name="tieline" xaxis="x(Mg)" yaxis="T" />

<plot table_name="invariant_tieline" xaxis="x(Mg)" yaxis="T" />

</graph>

</graphs>

Example 2: Graphs after precipitation simulation showing the number density, average size and hardness.

<graphs>

<graph name="number density">

<plot table_name="185C_KWN" xaxis="log10(t)" yaxis="log10(nd(*))"/>

<plot type="point" table_name="nd_exp" xaxis="logt" yaxis="nd"/>

</graph>

<graph name="average size">

<plot table_name="185C_KWN" xaxis="log10(t)" yaxis="log10(s(*)*1e10)"/>

<plot type="point" table_name="size_exp" xaxis="logt" yaxis="size"/>

</graph>

<graph name="hardness">

<plot table_name="185C_KWN" xaxis="log10(t)" yaxis="hv"/>

<plot type="point" table_name="hv_exp" xaxis="logt" yaxis="hv"/>

</graph>

</graphs>