197 lines
12 KiB
HTML
197 lines
12 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<title>NC Optimization | HiAPI-C# 2025 </title>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<meta name="title" content="NC Optimization | HiAPI-C# 2025 ">
|
|
|
|
|
|
<link rel="icon" href="../../img/HiAPI.favicon.ico">
|
|
<link rel="stylesheet" href="../../public/docfx.min.css">
|
|
<link rel="stylesheet" href="../../public/main.css">
|
|
<meta name="docfx:navrel" content="../../toc.html">
|
|
<meta name="docfx:tocrel" content="toc.html">
|
|
|
|
<meta name="docfx:rel" content="../../">
|
|
|
|
|
|
|
|
<meta name="loc:inThisArticle" content="In this article">
|
|
<meta name="loc:searchResultsCount" content="{count} results for "{query}"">
|
|
<meta name="loc:searchNoResults" content="No results for "{query}"">
|
|
<meta name="loc:tocFilter" content="Filter by title">
|
|
<meta name="loc:nextArticle" content="Next">
|
|
<meta name="loc:prevArticle" content="Previous">
|
|
<meta name="loc:themeLight" content="Light">
|
|
<meta name="loc:themeDark" content="Dark">
|
|
<meta name="loc:themeAuto" content="Auto">
|
|
<meta name="loc:changeTheme" content="Change theme">
|
|
<meta name="loc:copy" content="Copy">
|
|
<meta name="loc:downloadPdf" content="Download PDF">
|
|
|
|
<script type="module" src="./../../public/docfx.min.js"></script>
|
|
|
|
<script>
|
|
const theme = localStorage.getItem('theme') || 'auto'
|
|
document.documentElement.setAttribute('data-bs-theme', theme === 'auto' ? (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light') : theme)
|
|
</script>
|
|
|
|
</head>
|
|
|
|
<body class="tex2jax_ignore" data-layout="" data-yaml-mime="">
|
|
<header class="bg-body border-bottom">
|
|
<nav id="autocollapse" class="navbar navbar-expand-md" role="navigation">
|
|
<div class="container-xxl flex-nowrap">
|
|
<a class="navbar-brand" href="../../index.html">
|
|
<img id="logo" class="svg" src="../../img/HiAPI.logo.png" alt="">
|
|
|
|
</a>
|
|
<button class="btn btn-lg d-md-none border-0" type="button" data-bs-toggle="collapse" data-bs-target="#navpanel" aria-controls="navpanel" aria-expanded="false" aria-label="Toggle navigation">
|
|
<i class="bi bi-three-dots"></i>
|
|
</button>
|
|
<div class="collapse navbar-collapse" id="navpanel">
|
|
<div id="navbar">
|
|
<form class="search" role="search" id="search">
|
|
<i class="bi bi-search"></i>
|
|
<input class="form-control" id="search-query" type="search" disabled placeholder="Search" autocomplete="off" aria-label="Search">
|
|
</form>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
</header>
|
|
|
|
<main class="container-xxl">
|
|
<div class="toc-offcanvas">
|
|
<div class="offcanvas-md offcanvas-start" tabindex="-1" id="tocOffcanvas" aria-labelledby="tocOffcanvasLabel">
|
|
<div class="offcanvas-header">
|
|
<h5 class="offcanvas-title" id="tocOffcanvasLabel">Table of Contents</h5>
|
|
<button type="button" class="btn-close" data-bs-dismiss="offcanvas" data-bs-target="#tocOffcanvas" aria-label="Close"></button>
|
|
</div>
|
|
<div class="offcanvas-body">
|
|
<nav class="toc" id="toc"></nav>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="content">
|
|
<div class="actionbar">
|
|
<button class="btn btn-lg border-0 d-md-none" type="button" data-bs-toggle="offcanvas" data-bs-target="#tocOffcanvas" aria-controls="tocOffcanvas" aria-expanded="false" aria-label="Show table of contents">
|
|
<i class="bi bi-list"></i>
|
|
</button>
|
|
|
|
<nav id="breadcrumb"></nav>
|
|
</div>
|
|
|
|
<article data-uid="NcOptimization">
|
|
<h1 id="nc-optimization">NC Optimization</h1>
|
|
|
|
<p>Also refer to the script commands section <a class="xref" href="../../workflows/nc-optimization.html">Workflow: NC Optimization</a>.</p>
|
|
<h2 id="optimization-objective">Optimization Objective</h2>
|
|
<p>Optimization aims to make the physical quantities during machining as close to the target values as possible.</p>
|
|
<p>Since the optimization uses a conservative feed rate strategy, the physical quantities in the optimized NC code will be as close to <strong>equal to or less than</strong> the target values as possible.</p>
|
|
<h3 id="factors-determining-the-optimized-feed-rate">Factors Determining the Optimized Feed Rate</h3>
|
|
<p>The optimized feed rate is determined by:</p>
|
|
<ol>
|
|
<li><strong>Physical quantity constraints of individual <a class="xref" href="../runtime/step.html">steps</a></strong>: Feed rate limits calculated for each step based on target force, yielding stress, spindle torque, etc. For detailed descriptions of indicators such as yielding stress ratio and spindle torque ratio, refer to "<a href="machinability.html">Evaluating Process Machinability</a>".</li>
|
|
<li><strong>Inter-step smoothing</strong>: Interactions such as acceleration/deceleration limits and extended distances.</li>
|
|
</ol>
|
|
<h2 id="differences-in-simulation-results-after-optimization">Differences in Simulation Results After Optimization</h2>
|
|
<p>Simulation with modified feed rates produces different interpolation points than before, resulting in:</p>
|
|
<ol>
|
|
<li>Different simulation mesh errors</li>
|
|
<li>Surface morphology changes at the surface roughness level</li>
|
|
</ol>
|
|
<p>Therefore, the simulated physical quantities after optimization may not always be equal to or below the target values — they may also be slightly above.</p>
|
|
<p>The influence of interpolation point density on surface morphology is greater at rounded corners than on straight lines, so this effect may be more pronounced at corners.</p>
|
|
<div class="TIP">
|
|
<h5>Tip</h5>
|
|
<p>For abnormally low optimized feed rates at corners, refer to <a href="corner-behavior.html">Corner Feed Rate Optimization</a>.</p>
|
|
</div>
|
|
<h2 id="velocity-smoothing">Velocity Smoothing</h2>
|
|
<p>The smoothing range terminates at macro commands or line commands with unresolvable paths.</p>
|
|
<p><em>Velocity smoothing</em> applies acceleration/deceleration limits based on the path length traversed by the current line command.
|
|
Therefore, <em>velocity smoothing</em> is effective for <em>re-interpolatable</em> regions;
|
|
however, for non-re-interpolatable regions, although acceleration/deceleration limits still apply, the excessively long path length of a single line may render them impractical in actual use.</p>
|
|
<h2 id="impact-of-geometric-errors">Impact of Geometric Errors</h2>
|
|
<p>Current NC optimization is based on an ideal geometric model. If the workpiece is a casting or has installation errors, a conservatively larger workpiece geometry should be configured in the system to prevent the system from misidentifying cutting regions as non-cutting regions, which could cause tool crashes.</p>
|
|
<h2 id="tool-breakage-solutions">Tool Breakage Solutions</h2>
|
|
<p>Modify the toolpath to reduce cutting width/depth, or use HiNC's optimization feature to adjust feed rates, bringing the <strong>yielding stress ratio</strong>, <strong>max spindle torque ratio</strong>, and <strong>max spindle power ratio</strong> below 100%.</p>
|
|
<p>For detailed descriptions of these indicators and tool breakage criteria, refer to "<a href="machinability.html">Evaluating Process Machinability</a>".</p>
|
|
<h2 id="tuning-peak-tolerance">Tuning Peak Tolerance</h2>
|
|
<p>Optimization defaults treat the 100 % line on every ratio as a hard ceiling. In practice some metrics tolerate routine excursions and others don't. The per-metric <code>Opt*UtilizationFactor</code> levers let the optimizer accept higher peaks where physically safe.</p>
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Metric</th>
|
|
<th>Factor (API)</th>
|
|
<th>When to raise</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<td>Yielding stress</td>
|
|
<td><a class="xref" href="../../api/Hi.MachiningProcs.SessionShell.html#Hi_MachiningProcs_SessionShell_OptYieldingUtilizationFactor">OptYieldingUtilizationFactor</a></td>
|
|
<td><strong>Per-instant.</strong> Safe to raise. If 150 % is routinely tolerated without breakage, set <code>1.5</code>. Controller corner smoothing and spindle inertia absorb a single-revolution overshoot.</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Spindle torque</td>
|
|
<td><a class="xref" href="../../api/Hi.MachiningProcs.SessionShell.html#Hi_MachiningProcs_SessionShell_OptSpindleTorqueUtilizationFactor">OptSpindleTorqueUtilizationFactor</a></td>
|
|
<td><strong>Cumulative.</strong> Keep at 1. Sustained excursions stall the spindle: feed continues, rpm drops, feed-per-tooth grows, forces spike further.</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Spindle power</td>
|
|
<td><a class="xref" href="../../api/Hi.MachiningProcs.SessionShell.html#Hi_MachiningProcs_SessionShell_OptSpindlePowerUtilizationFactor">OptSpindlePowerUtilizationFactor</a></td>
|
|
<td><strong>Cumulative.</strong> Keep at 1. Same reason as torque.</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Thermal yield</td>
|
|
<td><a class="xref" href="../../api/Hi.MachiningProcs.SessionShell.html#Hi_MachiningProcs_SessionShell_OptThermalYieldUtilizationFactor">OptThermalYieldUtilizationFactor</a></td>
|
|
<td><strong>Long-term.</strong> Can be raised modestly if the calibrated tool material is more thermally tolerant than the conservative defaults — see <a href="machinability.html#thermal-plastic-deformation-of-cutting-edge">Thermal Plastic Deformation of Cutting Edge</a>.</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<p>Rule of thumb: relax per-instant per-step metrics based on observed stable extremes; never relax cumulative metrics.</p>
|
|
<p>For a complementary feed-rate floor lever — useful when the NC cannot be modified to remove single-revolution peaks — see <a class="xref" href="../../api/Hi.NcOpt.NcOptOption.html#Hi_NcOpt_NcOptOption_MinFeedPerTooth_mm">MinFeedPerTooth_mm</a> (API) and <a href="cam-floating-point-drift.html#when-the-nc-cannot-be-modified">When the NC Cannot Be Modified</a>.</p>
|
|
<h2 id="thermal-edge-chipping-solutions">Thermal Edge Chipping Solutions</h2>
|
|
<p>After addressing tool breakage issues, reduce the spindle speed to allow sufficient time for the cutting edge to dissipate heat.</p>
|
|
<p>Note that whether the coolant is properly directed at the cutting edge has a significant impact.</p>
|
|
<h2 id="tracking-physical-quantity-constraints-of-individual-steps">Tracking Physical Quantity Constraints of Individual Steps</h2>
|
|
<p>To determine which physical quantity limits the feed rate for an individual step, first disable smoothing-related settings, then enable logging:</p>
|
|
<pre><code class="lang-csharp">OptMaxAcceleration_mmds2 = double.PositiveInfinity;
|
|
OptFeedrateAssignmentRatio = 0;
|
|
OptExtendedPreDistance_mm = 0;
|
|
OptExtendedPostDistance_mm = 0;
|
|
EnableIndividualStepAdjustmentLog = true;
|
|
EmbeddedLogMode = NcOptimizationEmbeddedLogMode.FullLog;
|
|
</code></pre>
|
|
<p>After running the optimization, inspect the <code>.IndependentStepAdjustment.log</code> file to view the independent optimization calculation results for each step and identify which physical quantity limited the feed rate.</p>
|
|
<p>For detailed field descriptions of the log file, refer to the <a href="../../workflows/nc-optimization.html#optimization-logs">Optimization Logs</a> section in the <a class="xref" href="../../workflows/nc-optimization.html">Workflow: NC Optimization</a> workflow.</p>
|
|
|
|
</article>
|
|
|
|
<div class="contribution d-print-none">
|
|
</div>
|
|
|
|
<div class="next-article d-print-none border-top" id="nextArticle"></div>
|
|
|
|
</div>
|
|
|
|
<div class="affix">
|
|
<nav id="affix"></nav>
|
|
</div>
|
|
</main>
|
|
|
|
<div class="container-xxl search-results" id="search-results"></div>
|
|
|
|
<footer class="border-top text-secondary">
|
|
<div class="container-xxl">
|
|
<div class="flex-fill">
|
|
<span> Copyright © 2025 <a href='https://superhightech.com.tw'>Tech Coordinate</a>. All rights reserved. <a href='https://superhightech.com.tw'>超級高科技股份有限公司</a> © 2025 版權所有 </span>
|
|
</div>
|
|
</div>
|
|
</footer>
|
|
</body>
|
|
</html>
|