variable_offset#

ptrace.variable_offset(p0: float) int#

Sets the distance from the surface into the flow field at which the velocity variable will be sampled. The tangential component of the variable at this offset distance is the field that will be used to trace through for surface restricted traces.

A positive number moves the distance in the direction of the positive normal of the surface, while a negative number moves in the opposite direction. If there is only flow on one side of the surface, the program will flip the sign internally.
Used only for surface restricted particle traces.
Args:
p0:

‘offset_distance’ distance into the field

Examples:
#
# Selecting the parent part
#
ensight.part.select_begin(1)
#
# Setting some attributes before creation
# (the variable_offset for the surface_restricted trace
#  is being set here)
#
ensight.ptrace.begin()
ensight.part.description("Particle trace part")
ensight.ptrace.surface_restricted("ON")
ensight.ptrace.variable_offset(1.0000e-01)
ensight.ptrace.display_offset(0.5000e+00)
ensight.ptrace.total_time(2.0000e+02)
ensight.ptrace.emit_at_current_time("ON")
ensight.ptrace.end()
#
# Creating trace from a point
#
ensight.ptrace.create_pt()
Returns:

zero on success, non-zero on error