Module “utils”¶
-
class
tc_python.utils.CompositionUnit(value)¶ Bases:
enum.EnumThe composition unit.
-
MASS_FRACTION= 2¶ Mass fraction.
-
MASS_PERCENT= 3¶ Mass percent.
-
MOLE_FRACTION= 0¶ Mole fraction.
-
MOLE_PERCENT= 1¶ Mole percent.
-
-
class
tc_python.utils.ConversionUnit(value)¶ Bases:
enum.EnumThe composition unit used in a conversion.
-
MOLE_FRACTION= 0¶ Mole fraction.
-
MOLE_PERCENT= 1¶ Mole percent.
-
WEIGHT_FRACTION= 2¶ Weight fraction.
-
WEIGHT_PERCENT= 3¶ Weight percent.
-
-
class
tc_python.utils.InterfacePosition(value)¶ Bases:
enum.EnumThe position of an interface relative to its region. Only used for diffusion simulations.
-
LOWER= 0¶ The interface is on the lower side of its region.
-
UPPER= 1¶ The interface is on the upper side of its region.
-
-
class
tc_python.utils.ResultValueGroup(result_line_group_java)¶ Bases:
objectA x-y-dataset representing a line data calculation result (i.e. a Thermo-Calc quantity 1 vs. quantity 2).
Warning
Depending on the calculator, the dataset might contain NaN-values to separate the data between different subsets.
- Variables
label – a str describing what the data corresponds to
x – list of floats representing the first quantity (“x-axis”)
y – list of floats representing the second quantity (“y-axis”)
-
get_label() → str¶ Accessor for the line label :return the line label
-
get_x() → List[float]¶ Accessor for the x-values :return the x values
-
get_y() → List[float]¶ Accessor for the y-values :return the y values
-
class
tc_python.utils.TemperatureProfile¶ Bases:
objectRepresents a time-temperature profile used by non-isothermal calculations.
Note
The total simulation time can differ from the defined temperature profile. Constant temperature is assumed for any timepoint after the end of the defined profile.
-
add_time_temperature(time: float, temperature: float)¶ Adds a time-temperature point to the non-isothermal temperature profile.
- Parameters
time – The time [s]
temperature – The temperature [K]
- Returns
This
TemperatureProfileobject
-