Table of Contents

Class MillingToolPhysicsPack

Namespace
Hi.Milling.MillingTools
Assembly
HiMech.dll

The scalar physics derivations of one tool (and one cutting-parameter set), computed once on a sequential boundary and frozen. The per-step force build, the sequential physics, and the step/shot writers read these values thousands to millions of times per play; the tool and cutter objects themselves expose them as deliberately uncached pure computations, so hot session paths read this pack instead — callers outside a session simply pass null and the pure computation runs on use. Owned per session by MachiningSession, keyed by tool id. A pack is never updated in place: the paths that change tool/cutter/para state invalidate the session's packs explicitly (run-op start, tool change — see MachiningSession.InvalidateToolPhysicsPacks), and IsStaleFor(IMachiningTool, ICuttingPara) re-keys on object replacement.

public sealed record MillingToolPhysicsPack : IEquatable<MillingToolPhysicsPack>
Inheritance
MillingToolPhysicsPack
Implements
Inherited Members
Extension Methods

Constructors

MillingToolPhysicsPack(IMachiningTool, ICuttingPara, double, double, double, double, double, CutterBeamCompliance, double, double, double)

The scalar physics derivations of one tool (and one cutting-parameter set), computed once on a sequential boundary and frozen. The per-step force build, the sequential physics, and the step/shot writers read these values thousands to millions of times per play; the tool and cutter objects themselves expose them as deliberately uncached pure computations, so hot session paths read this pack instead — callers outside a session simply pass null and the pure computation runs on use. Owned per session by MachiningSession, keyed by tool id. A pack is never updated in place: the paths that change tool/cutter/para state invalidate the session's packs explicitly (run-op start, tool change — see MachiningSession.InvalidateToolPhysicsPacks), and IsStaleFor(IMachiningTool, ICuttingPara) re-keys on object replacement.

public MillingToolPhysicsPack(IMachiningTool Tool, ICuttingPara Para, double SpindleMountToToolTipLength, double ObservationHeightFromToolTip, double EffectiveCuttingDiameter_mm, double BendingPara_umdN, double ZDeflectionPara_umdN, CutterBeamCompliance BeamCompliance, double FakeRakeAngle_rad, double MinimumUncutChipThickness_mm, double SetupAngle_rad)

Parameters

Tool IMachiningTool

The tool the pack was built from.

Para ICuttingPara

The cutting-parameter set the para-dependent members were built from (may be null).

SpindleMountToToolTipLength double

See SpindleMountToToolTipLength.

ObservationHeightFromToolTip double

See ObservationHeightFromToolTip; NaN when the tool is not a MillingTool.

EffectiveCuttingDiameter_mm double

See EffectiveCuttingDiameter_mm; NaN without a MillingCutter.

BendingPara_umdN double

See ExposedCutterBendingPara_umdN; NaN when the deflection geometry is degenerate (the pure getter throws there instead — the pack stays buildable so geometry-only paths keep working).

ZDeflectionPara_umdN double

The pair member of BendingPara_umdN — see ExposedCutterZDeflectionPara_umdN.

BeamCompliance CutterBeamCompliance

The cutter beam's compliance as a function of the height its load sits at — see GetBeamCompliance(); the two scalars above are its tip values. Null when the cutter has no beam to state (no beam material, no exposed height, degenerate inner-beam geometry) — the scalars are NaN then.

FakeRakeAngle_rad double

The simplified (side/bottom averaged) rake angle; NaN without a MillingCutter.

MinimumUncutChipThickness_mm double

See GetMinimumUncutChipThickness_mm(ICuttingPara) for Para.

SetupAngle_rad double

See SetupAngle_rad; 0 when the tool is not a MillingTool. Frozen here, not read when the native session is built later, so the angle the force kernel uses is the one the session recorded when it built this pack.

Properties

BeamCompliance

The cutter beam's compliance as a function of the height its load sits at — see GetBeamCompliance(); the two scalars above are its tip values. Null when the cutter has no beam to state (no beam material, no exposed height, degenerate inner-beam geometry) — the scalars are NaN then.

public CutterBeamCompliance BeamCompliance { get; init; }

Property Value

CutterBeamCompliance

BendingPara_umdN

See ExposedCutterBendingPara_umdN; NaN when the deflection geometry is degenerate (the pure getter throws there instead — the pack stays buildable so geometry-only paths keep working).

public double BendingPara_umdN { get; init; }

Property Value

double

EffectiveCuttingDiameter_mm

public double EffectiveCuttingDiameter_mm { get; init; }

Property Value

double

FakeRakeAngle_rad

The simplified (side/bottom averaged) rake angle; NaN without a MillingCutter.

public double FakeRakeAngle_rad { get; init; }

Property Value

double

MinimumUncutChipThickness_mm

public double MinimumUncutChipThickness_mm { get; init; }

Property Value

double

ObservationHeightFromToolTip

See ObservationHeightFromToolTip; NaN when the tool is not a MillingTool.

public double ObservationHeightFromToolTip { get; init; }

Property Value

double

Para

The cutting-parameter set the para-dependent members were built from (may be null).

public ICuttingPara Para { get; init; }

Property Value

ICuttingPara

SetupAngle_rad

See SetupAngle_rad; 0 when the tool is not a MillingTool. Frozen here, not read when the native session is built later, so the angle the force kernel uses is the one the session recorded when it built this pack.

public double SetupAngle_rad { get; init; }

Property Value

double

SpindleMountToToolTipLength

public double SpindleMountToToolTipLength { get; init; }

Property Value

double

Tool

The tool the pack was built from.

public IMachiningTool Tool { get; init; }

Property Value

IMachiningTool

ZDeflectionPara_umdN

The pair member of BendingPara_umdN — see ExposedCutterZDeflectionPara_umdN.

public double ZDeflectionPara_umdN { get; init; }

Property Value

double

Methods

Build(IMachiningTool, ICuttingPara)

Builds a pack from the tool's (and cutter's) pure computations. Call on a sequential boundary (session/play start, tool change) or ad hoc from a no-session caller that wants the values bundled.

public static MillingToolPhysicsPack Build(IMachiningTool tool, ICuttingPara para)

Parameters

tool IMachiningTool

The tool to derive from; null yields null.

para ICuttingPara

The cutting-parameter set for the para-dependent members; may be null.

Returns

MillingToolPhysicsPack

The frozen pack, or null when tool is null.

IsStaleFor(IMachiningTool, ICuttingPara)

Whether this pack was built from different objects than the live ones — a replaced tool under the same id, or a swapped cutting para. In-place edits are not detected here; they are covered by the explicit invalidation points (MachiningSession.InvalidateToolPhysicsPacks).

public bool IsStaleFor(IMachiningTool tool, ICuttingPara para)

Parameters

tool IMachiningTool

The live tool to compare against.

para ICuttingPara

The live cutting-parameter set to compare against.

Returns

bool

True when the pack must be rebuilt.