Skip to main content
Log in

CNC codes conversion from linear and circular paths to NURBS curves

  • ORIGINAL ARTICLE
  • Published:
The International Journal of Advanced Manufacturing Technology Aims and scope Submit manuscript

Abstract

A novel approach is proposed for converting NC files of G01/G02/G03 codes into NURBS curves. The NC points are first acquired from an NC file composed of lines and arcs. A segmentation algorithm based on the angles and lengths evaluated from adjacent points is then used to subdivide the entire group of points into segments. An error-bounded constrained curve fitting algorithm is implemented to fit each segment of points into a curve, maintaining the accuracy, smoothness and boundary continuity between the curves. The chord errors between the NC points and the fitted curves are controlled, which ensures the accurate recovery of NC paths. Also, a knot insertion algorithm is proposed to determine the appropriate number of control points automatically, allowing effective fitting of all segments. Several examples are presented to demonstrate the feasibility of the proposed approach.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

References

  1. Piegl L, Tiller W (1997) The NURBS Book. Springer

  2. Hoschek J (1988) Spline approximation of offset curves. Comput Aided Geom Des 5:33–40

    Article  MATH  MathSciNet  Google Scholar 

  3. Rogers DF, Fog NG (1988) Constrained B-spline curve and surface fitting. CAD 21(10):641–648

    Google Scholar 

  4. Sarkar B, Menq CH (1991) Parameter optimization in approximating curves and surfaces to measurement data. Comput Aided Geom Des 8:267–290

    Article  MATH  MathSciNet  Google Scholar 

  5. Wang W, Pottmann H, Liu Y (2004) Fitting B-spline curves to point clouds by squared distance minimization. HKU CS Tech Report TR-2004-11

  6. Ma W, Kruth JP (1995) Parameterization of randomly measured points for least squares fitting of B-spline curves and surfaces. CAD 27(9):663–675

    MATH  Google Scholar 

  7. Szobonya L, Renner G (2002) Construction of curves and surfaces based on point clouds. Proc. First Hungarian Conference on Computer Graphics and Geometry, Budapest 57–62

  8. Yang H, Wang W, Sun J (2004) Control point adjustment for B-spline curve approximation. CAD 36:639–652

    Google Scholar 

  9. Park H, Kim K, Lee SC (2000) A method for approximate NURBS compatibility based on multiple curve refitting. CAD 32:237–252

    Google Scholar 

  10. Alhanaty M, Bercovier M (2001) Curve and surface fitting and design by optimal control methods. CAD 33:167–182

    Google Scholar 

  11. Benko P, Kos G, Varady T, Andor L, Martin R (2002) Constrained fitting in reverse engineering. Comput Aided Geom Des 19:173–205

    Article  MathSciNet  Google Scholar 

  12. Ueng WD, Lai JY, Tsai YC (2007) Unconstrained and constrained curve fitting for reverse engineering. Int J Adv Manuf Technol, on-line first

  13. Leon SJ (1994) Linear Algebra with Applications, Fourth Edition. Prentice Hall, New York

  14. Press WH, Flannery BP, Teukolsky SA, Vetterling WT (1992) Numerical Recipes in C: The Art of Scientific Computing. Cambridge, New York

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Jiing-Yih Lai.

Rights and permissions

Reprints and permissions

About this article

Cite this article

Lin, KY., Ueng, WD. & Lai, JY. CNC codes conversion from linear and circular paths to NURBS curves. Int J Adv Manuf Technol 39, 760–773 (2008). https://doi.org/10.1007/s00170-007-1271-x

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s00170-007-1271-x

Keywords

Navigation