Table of Contents

Class ActMcPolarSpiralContour

Namespace
Hi.Numerical.Acts
Assembly
HiMech.dll

Circular (arc/helix) contour on the polar hypothetical plane while Polar Coordinate Interpolation (Fanuc G12.1) is active.

The arc geometry lives entirely in central polar Rxcz coordinates (X = radius-direction linear axis mm, Y = hypothetical rotary-substitute axis mm, Z = real Z mm, origin on the rotary center) — the same spiral math as ActMcXyzSpiralContour. Each sampled point is then converted to machine coordinates the way ActMcPolarLinearContour does: radius drives machine X, the atan2 angle drives the machine C axis with the branch chained from the previous step (GetNoInterpolationOrdinaryProgramXcz_rad(vec3d_t, double, vec3d_t)), machine Y/A/B stay frozen at the previous position, and Z carries the coordinate/tool-height offset.

The chaining state is local to each enumeration, so the act can be re-enumerated safely and arcs crossing the ±180° branch (or spanning multiple turns via AdditionalCircleNum) stay continuous — unlike the HardNc per-point unresolved atan2, whose machine C jumps by one cycle at the branch cut (same physical pose). Known divergence: per-step machine X is the raw polar radius and machine Y stays frozen — coordinate-offset X/Y components are NOT applied (only Z carries an offset), consistent with ActMcPolarLinearContour and the turn-mill assumption that machine X ≡ radius. HardNc is internally inconsistent here: its polar arc steps run the full transform chain (G5x X/Y included) while its polar linear steps use the raw radius like this act.
public class ActMcPolarSpiralContour : IActDuration, IActMcXyzabcContour, IAct
Inheritance
ActMcPolarSpiralContour
Implements
Inherited Members
Extension Methods

Constructors

ActMcPolarSpiralContour(dvec3d_t, vec3d_t, vec3d_t, vec3d_t, vec3d_t, int, TimeSpan, double, PolarModeDirEnum)

Initializes a new instance of the ActMcPolarSpiralContour class.

public ActMcPolarSpiralContour(dvec3d_t preMcXyzabc_rad, vec3d_t programPolarBegin, vec3d_t programPolarEnd, vec3d_t programPolarCenterOnBeginPlane, vec3d_t centerNormal, int additionalCircleNum, TimeSpan duration, double zCoordinateOffset, PolarModeDirEnum polarDir = PolarModeDirEnum.XC)

Parameters

preMcXyzabc_rad dvec3d_t

Previous machine XYZ-ABC coordinates in radians

programPolarBegin vec3d_t

Arc begin in central polar Rxcz (mm)

programPolarEnd vec3d_t

Arc end in central polar Rxcz (mm)

programPolarCenterOnBeginPlane vec3d_t

Arc center on the begin plane, central polar Rxcz (mm)

centerNormal vec3d_t

Plane normal with rotation sign

additionalCircleNum int

Number of additional full circles

duration TimeSpan

Duration of the contour movement

zCoordinateOffset double

Depth-axis (plane normal) offset

polarDir PolarModeDirEnum

Polar axis pair (default XC)

Properties

ActDuration

Gets or sets the duration of the action.

public TimeSpan ActDuration { get; set; }

Property Value

TimeSpan

Remarks

The duration represents:

  • The time required to complete the action
  • Should be positive and finite
  • Zero duration indicates an instantaneous action
  • Used for scheduling and timing calculations

AdditionalCircleNum

Number of additional full circles (helix).

public int AdditionalCircleNum { get; set; }

Property Value

int

CenterNormal

Plane normal with rotation sign (XC pair → (0,0,±1)).

public vec3d_t CenterNormal { get; set; }

Property Value

vec3d_t

PolarDir

The polar axis pair mapping the triple-space steps onto machine axes (XC unless the machine runs G12.1 on YA/ZB).

public PolarModeDirEnum PolarDir { get; }

Property Value

PolarModeDirEnum

ProgramPolarBegin

Arc begin in central polar Rxcz coordinates (mm).

public vec3d_t ProgramPolarBegin { get; set; }

Property Value

vec3d_t

ProgramPolarCenterOnBeginPlane

Arc center on the begin plane, central polar Rxcz (mm).

public vec3d_t ProgramPolarCenterOnBeginPlane { get; set; }

Property Value

vec3d_t

ProgramPolarEnd

Arc end in central polar Rxcz coordinates (mm).

public vec3d_t ProgramPolarEnd { get; set; }

Property Value

vec3d_t

Methods

GetActMcXyzabcSteps(IMachiningMotionResolution, double, Action<object>)

Gets the machine XYZABC steps for this contour.

public IEnumerable<ActMcXyzabcStep> GetActMcXyzabcSteps(IMachiningMotionResolution ncResolution, double spindleMountToToolTipLength, Action<object> coordinateConversionFailedAction)

Parameters

ncResolution IMachiningMotionResolution

The machining motion resolution to use for step generation.

spindleMountToToolTipLength double

The length from spindle mount to tool tip, used for computing step numbers.

coordinateConversionFailedAction Action<object>

Called when attacher NP to MC conversion fails; the argument is the failed dvec3d_t (attacher NP).

Returns

IEnumerable<ActMcXyzabcStep>

A collection of machine XYZABC steps.

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.