Towards CNC Programming Using Haskell
|
|
|
- Matilda Henry
- 9 years ago
- Views:
Transcription
1 Towards CNC Programming Using Haskell G. Arroyo 1, C. Ochoa 2, J. Silva 2, and G. Vidal 2 1 CIIDET, Av. Universidad 282 Pte. Centro, Santiago de Querétaro, Qro, Mexico. [email protected] 2 DSIC, Tech. University of Valencia, Camino de Vera s/n, E Valencia, Spain. {cochoa,jsilva,gvidal}@dsic.upv.es Abstract. Recent advances in Computerized Numeric Control (CNC) have allowed the manufacturing of products with high quality standards. Since CNC programs consist of a series of assembler-like instructions, several high-level languages (e.g., AutoLISP, APL, OMAC) have been proposed to raise the programming abstraction level. Unfortunately, the lack of a clean semantics prevents the development of formal tools for the analysis and manipulation of programs. In this work, we propose the use of Haskell for CNC programming. The declarative nature of Haskell provides an excellent basis to develop program analysis and manipulation tools and, most importantly, to formally prove their correctness. 1 Introduction Computerized Numeric Control (CNC for short) machines have become the basis of many industrial processes. CNC machines include robots, production lines, and all those machines that are controlled by digital devices. Typically, CNC machines have a machine control unit (MCU) which inputs a CNC program and controls the behavior and movements of all the parts of the machine. Currently as stated by the standard ISO 6983 [3] CNC programs interpreted by MCUs are formed by an assembler-like code which is divided into single instructions called G-codes (see Fig. 1 below). One of the main problems of CNC programming is their lack of portability. In general, each manufacturer introduces some extension to the standard G-codes in order to support the wide variety of functions and tools that CNC machines provide. Thus, when trying to reuse a CNC program, programmers have to tune it first for the MCU of their specific CNC machines. For example, even though both CNC machines HASS VF-0 and DM2016 are milling machines, the G-codes they accept are different because they belong to different manufacturers (e.g., the former is newer and is able to carry out a wider spectrum of tasks). CNC programming is not an easy task since G-codes represent a low-level language without control statements, procedures, and many other advantages of modern high-level languages. In order to provide portability to CNC programs This work has been partially supported by CICYT TIC , by Generalitat Valenciana GRUPOS03/025, by EU-India Economic Cross Cultural Prog. ALA/95/23/2003/ , and by MCYT under grant HU
2 and to raise the abstraction level of the language, there have been several proposals of intermediate languages, such as APL [9] and OMAC [7], from which G-codes can be automatically generated with compilers and post-processors. Unfortunately, the lack of a clean semantics in these languages prevents the development of formal tools for the analysis and manipulation of programs. Current CNC programming languages, such as Auto-Code [6] or AutoLISP [2, 12], allow us to completely specify CNC programs but do not permit to analyze program properties like, e.g., termination, or to formally use heuristics when defining the behavior of CNC machines (as it happens with autonomous robots). In this work, we propose the use of the pure functional language Haskell [11] to design CNC programs. Our choice relies on the fact that Haskell is a modern high-level language which provides a very convenient framework to produce and formally analyze and verify programs. Furthermore, it has many useful features such as, e.g., lazy evaluation (which allows us to cope with infinite data structures), higher-order constructs (i.e. the use of functions as first-class citizens, which allows us to easily define complex combinators), type classes for arranging together types of the same kind, etc. This paper presents our proposal for CNC programming using Haskell and shows the main advantages of Haskell over current languages which are used for the same purpose. This paper is organized as follows. In the next section, we provide a brief review of CNC programming. Section 3 introduces the functional language Haskell. In Sect. 4, we illustrate the use of Haskell to represent CNC programs and, then, in Sect. 5, we enumerate some advantages of choosing Haskell over other existing languages. Some implementation details are discussed in Sect. 6 and, finally, conclusions and some directions for future work are presented in Sect CNC: A Brief Review Computer numerical control is the process of having a computer controlling the operation of a machine [17]. CNC machines typically replace (or work in conjunction with) some existing manufacturing processes. Almost all operations performed with conventional machine tools are programmable with CNC machines. For instance, with CNC machines we can perform motion control in linear along a straight line or rotary along a circular path axes. A CNC program is composed by series of blocks containing one or more instructions, written in assembly-like format [13]. These blocks are executed in sequential order, step by step. Each instruction has a special meaning, as they get translated into a specific order for the machine. They usually begin with a letter indicating the type of activity the machine is intended to do, like F for feed rate, S for spindle speed, and X, Y and Z for axes motion. For any given CNC machine type, there are about instructions that can be used on a regular basis. G words, commonly called G codes, are major address codes for preparatory functions, which involves tool movement and material removal. These include rapid moves, lineal and circular feed moves, and canned cycles. M words, commonly called M codes, are major address codes for miscellaneous functions
3 N0010 (3 hole drilling) N0020 G90 G21 G17 G54 N0030 T01 M06 N0040 S1200 M03 N0050 F300 N0060 G00 X25 Y75 Z5 N0070 G01 Z 25 N0080 Z5 N0090 X50 Y50 N0100 Z 25 N0110 Z5 N0120 X75 Y25 N0130 Z 25 N0140 G28 Z0 Fig. 1. Simple CNC Program that perform various instructions do not involving actual tool dimensional movement. These include spindle on and off, tool changes, coolant on and off, and other similar related functions. Most G and M-codes have been standardized, but some of them still have a different meaning for particular controllers. As mentioned earlier, a CNC program is composed by series of blocks, where each block can contain several instructions. For example, N0030 G01 X3.0 Y1.7 is a block with one instruction, indicating the machine to do a movement (linear interpolation) in the X and Y axes. Figure 1 shows an example of a simple CNC program for drilling three holes in a straight line. 3 An Overview of Haskell Haskell is a general-purpose, purely functional programming language that provides higher-order functions, non-strict semantics, static polymorphic typing, user-defined algebraic datatypes, pattern matching, list comprehensions, a monadic input/output system, and a rich set of primitive datatypes [11]. In Haskell, functions are defined by a sequence of rules of the form f t 1... t n = e where t 1,...,t n are constructor terms and the right-hand side e is an expression. The left-hand side must not contain multiple occurrences of the same variable. Constructor terms may contain variables and constructor symbols, i.e., symbols which are not defined by the program rules. Functions can also be defined by conditional equations which have the form f t 1... t n c = e where the condition (or guard) c must be a Boolean function. Function definitions have a (perhaps implicit) declaration of its type, of the form f :: a 1 a 2... a n b
4 which means that f takes n elements of types a 1,...,a n and returns an element of type b. For example, the following function returns the length of a given list: length :: [a] -> Int length [] = 0 length (_:xs) = 1 + length xs Note that in this example, a is a type variable which stands for any type. Local declarations can be defined by using the let or where constructs. For example, the following function returns True if the first argument is smaller than the length of the list being passed as a second argument, or False otherwise: indexchecker :: Int -> [a] -> Bool indexchecker n xs = n <= l where l = length xs A Haskell function is higher-order if it takes a function as an argument, returns a function as a result, or both. For instance, map is a higher-order function that applies a given function to each element in a list: map :: (a -> b) -> [a] -> [b] map f [] = [] map f (x:xs) = f x : map f xs Haskell provides a static type semantics, and even though it has several primitive datatypes (such as integers and floating-point numbers), it also provides a way of defining our own (possibly recursive) types using data declarations: data Bool = False True data Tree a = Leaf a Branch (Tree a) (Tree a) For convenience, Haskell also provides a way to define type synonyms; i.e., names for commonly used types. Type synonyms are created using a type declaration. Here are some examples: type String = [Char] type Name = String type Person = (Name,Address) data Address = None Addr String Type classes (or just classes) in Haskell provide a structured way to introduce overloaded functions that must be supported by any type that is an instance of that class. For example, the Equality class in Haskell is defined as follows: class Eq a where (==) :: a -> a -> Bool A type is made an instance of a class by defining the signature functions for the type, e.g., in order to make Address an instance of the Equality class: instance Eq Address where None == None = True Addr st1 == Addr st2 = st1 == st2 _ == _ = False where _ is a wildcard, used to introduce a default case. We refer the interested reader to the report on the Haskell language [11] for a detailed description of all the features of the pure functional language Haskell.
5 G01: Moves the turret chuck along the XYZ axes. It can be followed by XYZ codes. G90: Indicates that absolute positioning is being used. G91: Indicates that incremental positioning is being used. X(-)nn: used to move the turret chuck along the X axis Y(-)nn: used to move the turret chuck along the Y axis Z(-)nn: used to move the turret chuck along the Z axis where nn indicates: the new absolute position in the corresponding axis, where (0,0,0) is a given reference point over the table (absolute positioning). the number of units in the current axis that the tool is being shifted (incremental positioning). Fig. 2. Instructions set for simple CNC drilling machine 4 Using Haskell for CNC Programming In this section, we illustrate the use of Haskell for CNC programming. By lack of space, we consider a simple CNC drilling machine which can just move the turret chuck in the X and Y axes (in order to position the drill bit), and in the Z axis (in order to make the hole). The machine also handles absolute and incremental positioning of the turret chuck. 3. A CNC program for this machine consists of a header and a body. The header is optional and is usually a short comment, whilst the body is a list of blocks, where each block is identified by a number (Nnnnn) and can contain either one or more instructions or a comment, where comments are always parenthesized. An instruction can contain one of the CNC codes shown in Fig. 2. In the following, we consider millimeters as measurement units. For instance, a CNC program for drilling two holes at positions (10,10) and (15,15) is as follows: N0010 (two-hole drilling) N0060 Z05 N0020 G90 N0070 X15 Y15 N0030 G01 Z05 N0080 Z-25 N0040 X10 Y10 N0090 Z05 N0050 Z-25 In this example, the block N0010 denotes a comment, N0020 instructs the CNC machine to use absolute positioning, N0030 moves the turret chuck 5mm over the table in the Z axis, N0040 positions the turret chuck in the (10,10) coordinate (note that X10 Y10 is a shortcut for G01 X10 Y10), N0050 moves the turret chuck 25mm under the table in the Z axis, thus making a hole, N0060 moves the turret chuck 5mm over the table in the Z axis, in order to be able to move it again in the XY axes, N0070 positions the turret chuck in the (15,15) coordinate, and finally N0080 and N0090 create the second hole. 3 A full example with the implementation of complete data structures needed to represent CNC programs can be found at
6 data CNCprogram = Header Body data Header = Maybe Comment type Comment = String data Maybe a = Nothing Just a type Body = [Block] data Block = Com Comment Code Command type Command = [Instruction] data Instruction = X Int Y Int Z Int G String Fig. 3. Haskell data structures for representing a CNC program It should be clear from this example that, when a big number of holes should be done, the amount of lines of code we have to write also increases considerably. The Haskell data structure intended to hold a CNC program is shown in Fig. 3. For simplicity, our data structure does not contain information about block numbering. Nevertheless, given a list of blocks, it is straightforward to build a function that adds such numbering to each block. In our context, a CNC program is composed of a header and a body. A header is an optional comment (a String or the constructor Nothing when missing). A body is a set of blocks, each block being a comment or a set of instructions. Figure 4 shows a function for drilling n holes in a straight line implemented in Haskell. Note that nholesline returns a list of blocks, instead of a complete CNC program as defined in Fig. 3 (the header is missing). Far from being a shortcoming, this is due to the fact that nholesline is integrated in an environment with many other different functions; therefore, there is a master function which builds the whole program by prompting the user for a header comment, if any, and integrating the code obtained from the different functions. The function nholesline receives as parameters the number of holes, n, the initial XY coordinate and the corresponding increments in each axis. Then, this function generates a list of blocks by creating a list of n elements containing the absolute XY coordinates of the holes; it uses the higher-order function map to apply the function makehole to each XY coordinate. Note that, even though the list of n elements is created by first calling createline which generates an infinite list only n elements of such a list are actually built. This is due to the lazy evaluation of Haskell (see Sect. 5). For instance, in order to make 50 holes, starting at position (10,10) and increasing 5mm in each axis per hole, we simply call function nholesline as follows: nholesline The same example using G codes requires about 150 lines of code. However, with Haskell functions it is very simple to change any of the parameters to achieve any straight line of holes to be drilled. In the same way, a lot of helpful functions can be created, in order to make different shapes like ellipses, grids, etc, that are able to work with other CNC machines like lathes and milling machines.
7 -- creates a [Block] containing the CNC instructions for -- making n holes in a straight line nholesline :: Int -> Int -> Int -> Int -> Int -> [Block] nholesline n x y incx incy = [posit,init] ++ concat (map makehole nline) where line = createline x y incx incy nline = finiteline n line posit = Code [G "90"] init = Code [G "00",Z 5] -- creates an infinite list of absolute coordinates createline :: Int -> Int -> Int -> Int -> [(Int,Int)] createline x y incx incy = (x,y):createline (x+incx) (y+incy) incx incy -- takes a list and returns a sublist containing the first n elements finiteline :: Int -> [a] -> [a] finiteline _ [] = [] finiteline 0 _ = [] finiteline n (x:xs) = x : finiteline (n-1) xs -- takes an XY coordinate and return a block containing -- all instructions needed to make a hole at such position makehole :: (Int,Int) -> [Block] makehole (x,y) = [posxy,down,up] where up = Code [Z 5] down = Code [Z (-25)] posxy = Code [X x,y y] Fig. 4. Example program nholesline 5 Some Advantages of Haskell In the following, we summarize the most significant advantages of Haskell for CNC programming: Data structures and recursion. Haskell allows the definition of complex data structures (such as 3D geometric pieces) or iterative ones (such as hole meshes) that can be later manipulated and reused. A common way of defining and manipulating such data structures is to use recursion. In Fig. 4, two lists, line and nline, are used to describe a set of specific positions of a piece. We recursively apply a defined function to them by using a simple command. Polymorphism. Functions in Haskell can be polymorphic, i.e., they can be applied to different types (compare function length, which can be applied to lists of any kind). In our context, this means that some functions can be reused in many parts of the CNC program with different input data. Higher-order functions. Higher-order facilities [4] are one of the main advantages of Haskell over the rest of languages currently used for CNC programming, incorporating a big amount of predefined higher-order functions allowing us to optimize and minimize the size of the code with a high expressiveness.
8 Laziness. Haskell follows a lazy evaluation model [1, 16], which means that functions are evaluated on demand. This is particularly useful when dealing with infinite data structures. For instance, consider a robot hand which performs a specific movement each time a piece is under it. Thanks to laziness, we can define the behavior of the robot hand by this infinite movement since it will only be evaluated as much as needed. To the best of our knowledge, all languages used in CNC programming lack of lazy evaluation (i.e., they are strict languages with call by value evaluation). Type checking system. Haskell includes a standard type inference algorithm during compilation. Type checking can be very useful to detect errors in a CNC program, e.g., to detect that a drilling tool has not been separated from the piece surface after its use. Since CNC programs are usually employed in mass-production processes, program errors are very expensive. Therefore, having built-in type error checkers provided by a high-level compiler represents a significant advantage over usual CNC programs written by hand. Type classes. Type classes in Haskell provide a structured way to introduce overloaded 4 functions that must be supported by any type that is an instance of that class [18]. This is a powerful concept that allows us, e.g, to arrange together data structures (representing CNC machines) having a similar functionality and to define standard functions for such types. When introducing a new data structure representing a CNC machine having a functionality similar to an existing one, we can just derive it from such a class, applying the existing functions to this data structure without re-writing any code. Verification and heuristics. Haskell is a formal language with many facilities to prove the correctness of programs [14]. This represents the main advantage of our proposal compared with current languages being used for the same purpose. Thus, formal verification of CNC programs can be performed to demonstrate its termination, correctness, etc. Moreover, it makes possible the application of heuristics to define the behavior of CNC machines (as it happens with autonomous robots). This is subject of ongoing work and justifies our choice of Haskell for CNC programming. Furthermore, Haskell is amenable to formal verification by using theorem provers such as Isabelle [10] or HOL [8], verification logics such as P-Logic [5], etc. 6 Implementation Remarks The implementation of a Haskell library to design and manipulate CNC programs has been undertaken. This library currently contains: an XML DTD properly defined to completely represent any CNC program, a specific Haskell data structure equivalent to the DTD, and a set of functions to build and test CNC programs. 4 While polymorphic functions have a single definition over many types, overloaded functions have different definitions for different types.
9 In order to guarantee the portability of the CNC programs produced in our setting, we have defined an XML DTD which is able to represent any CNC program since it contains all the syntactic constructs specified in the standard ISO 6983 [3], as well as the extensions proposed in [15, 17]. With this DTD, we can properly define any CNC program and, with some Haskell translation functions, automatically convert it to/from an equivalent Haskell data structure. We have also implemented a library of functions which allows us to build and transform the data structure representing CNC programs in a convenient way. We provide several basic testing and debugging functions. Preliminary experiments are encouraging and point out the usefulness of our approach. More information (the implementation of Haskell library, the XML DTD and some examples) are publicly available at 7 Conclusions and Future Work This work proposes Haskell as a high-level language for the design and implementation of CNC programs. We have clarified its advantages over existing languages for CNC programming. Besides typical high-level features such as control sequence, recursion, rich data structures, polymorphism, etc. Haskell provides several advanced features like higher-order combinators, lazy evaluation, type classes, etc. Furthermore, Haskell offers a clean semantics which allows the development of formal tools. We have defined a Haskell data structure which is able to represent any CNC program, allowing us to properly manipulate it by using Haskell features. Furthermore, we implemented an XML DTD which is fully equivalent to the Haskell data structure. This DTD ensures the portability of our programs among applications and platforms. Preliminary experiments are encouraging and point out the usefulness of our approach. However, there is plenty of work to be done, like augmenting our library with other useful functions for making geometric figures, defining functions for other CNC machines (lathes, milling machines, etc), defining libraries for assisting the user in the post-processing of CNC programs, defining a graphical environment for simplifying the task of designing CNC programs, etc. References 1. R. Bird. Introduction to Functional Programming Using Haskell, 2nd Ed. Prentice Hall Press, H. Carr and R. Holt. The AutoLISP Platform for Computer Aided Design. In 40th Anniversary of Lisp Conference: Lisp in the Mainstream, Berkeley, California, November International Standardization for Organizations. Technical committee: ISO/TC 184/SC 1. Numerical control of machines Program format and definition of address words, September J. Hughes. Why Functional Programming Matters. Computer Journal, 32(2):98 107, 1989.
10 5. R. Kieburtz. P-logic: Property Verification for Haskell Programs, The Programatica Project, 6. B. Kramer. The AutoCADET s Guide to Visual LISP. CMP Books, J. Michaloski, S. Birla, C.J. Yen, R. Igou, and G. Weinert. An Open System Framework for Component-Based CNC Machines. ACM Computing Surveys, 32(23), T.F. Melham M.J.C. Gordon. TIntroduction to HOL. Cambridge University Press, T.P. Otto. An apl compiler. In International Conference on APL, editor, Proceedings of the international conference on APL-Berlin-2000 conference, pages ACM Press - New York, NY, USA, L.C. Paulson. The Foundation of a Generic Theorem Prover. Journal of Automated Reasoning, 5(3): , S. Peyton Jones, editor. Haskell 98 Language and Libraries: The Revised Report. Cambridge University Press, R. Rawls and M. Hagen. AutoLISP Programming: Principles and Techniques. Goodheart-Willcox Co, W. Seames. CNC: Concepts and Programming. Delmar Learning, S. Thompson. Formulating Haskell. Technical Report 29-92*, University of Kent, Computing Laboratory, University of Kent, Canterbury, UK, November J. Richard W. Maeder, V. Nguyen and J. Stark. Standardisation of the Manufacturing Process: the IMS STEP-NC Project. In Proc. of the IPLnet Workshop, P. Wadler. The Essence of Functional Programming. In Proceedings of the Symposium on Principles of Programming Languages (POPL 92), Albequerque. ACM Press, M. Weck, J. Wolf, and D. Kiritsis. Step-nc The STEP Compliant NC Programming Interface: Evaluation and Improvement of the Modern Interface. In Proc. of the ISM Project Forum 2001, M. Wenzel. Type Classes and Overloading in Higher-Order Logic. In E. Gunter and A. Felty, editors, Proceedings of the 10th International Conference on Theorem Proving in Higher Order Logics (TPHOLs 97), pages , Murray Hill, New Jersey, 1997.
UNIT 1 INTRODUCTION TO NC MACHINE TOOLS
UNIT 1 INTRODUCTION TO NC MACHINE TOOLS Structure 1.1 Introduction Objectives 1.2 NC Machines 1.2.1 Types of NC Machine 1.2.2 Controlled Axes 1.2.3 Basic Components of NC Machines 1.2.4 Problems with Conventional
Functional Programming
FP 2005 1.1 3 Functional Programming WOLFRAM KAHL [email protected] Department of Computing and Software McMaster University FP 2005 1.2 4 What Kinds of Programming Languages are There? Imperative telling
The countdown problem
JFP 12 (6): 609 616, November 2002. c 2002 Cambridge University Press DOI: 10.1017/S0956796801004300 Printed in the United Kingdom 609 F U N C T I O N A L P E A R L The countdown problem GRAHAM HUTTON
Name: Class: Date: 9. The compiler ignores all comments they are there strictly for the convenience of anyone reading the program.
Name: Class: Date: Exam #1 - Prep True/False Indicate whether the statement is true or false. 1. Programming is the process of writing a computer program in a language that the computer can respond to
CNC Programming. Lecture 25. Engineering 475 Automated Production Systems
CNC Programming Lecture 25 Engineering 475 Automated Production Systems Information Needed by a CNC Machine 1. Preparatory Information: units, incremental or absolute positioning 2. Coordinates: X,Y,Z,
Regular Expressions and Automata using Haskell
Regular Expressions and Automata using Haskell Simon Thompson Computing Laboratory University of Kent at Canterbury January 2000 Contents 1 Introduction 2 2 Regular Expressions 2 3 Matching regular expressions
Presentation on CNC MACHINES. By: Hafiz Muhammad Rizwan
Presentation on CNC MACHINES By: Hafiz Muhammad Rizwan WELCOME CNC Machines What is a CNC Machine? CNC : Computer Numerical Control Conventionally, an operator decides and adjusts various machines parameters
The Clean programming language. Group 25, Jingui Li, Daren Tuzi
The Clean programming language Group 25, Jingui Li, Daren Tuzi The Clean programming language Overview The Clean programming language first appeared in 1987 and is still being further developed. It was
Moving from CS 61A Scheme to CS 61B Java
Moving from CS 61A Scheme to CS 61B Java Introduction Java is an object-oriented language. This document describes some of the differences between object-oriented programming in Scheme (which we hope you
Functional Programming. Functional Programming Languages. Chapter 14. Introduction
Functional Programming Languages Chapter 14 Introduction Functional programming paradigm History Features and concepts Examples: Lisp ML 1 2 Functional Programming Functional Programming Languages The
Course outline. Know Your Machine From A Programmer s Viewpoint 11 If you ve had experience with conventional (non-cnc) machine tools 11
Course outline Know Your Machine From A Programmer s Viewpoint 11 If you ve had experience with conventional (non-cnc) machine tools 11 Machine Configurations 13 Vertical machining centers 13 C-frame style
Type Classes with Functional Dependencies
Appears in Proceedings of the 9th European Symposium on Programming, ESOP 2000, Berlin, Germany, March 2000, Springer-Verlag LNCS 1782. Type Classes with Functional Dependencies Mark P. Jones Department
The C Programming Language course syllabus associate level
TECHNOLOGIES The C Programming Language course syllabus associate level Course description The course fully covers the basics of programming in the C programming language and demonstrates fundamental programming
Summary Of GCODE Commands By Category (HTT0196)
Summary Of GCODE Commands By Category (HTT0196) SET UP COMMANDS CODE COMMAND FORMAT PURPOSE PAGE # F Feed Speed Fn Designates feed rate, or rate 05 of movement, of the axes. G4 Dwell Time G4/d Specifies
ME 1355 CAD/CAM LABORATORY CNC MILLING PROGRAM. Study of G Codes and M Codes to Write Manual Part Programming for Fanuc Control Systems
ME 1355 CAD/CAM LABORATORY CNC MILLING PROGRAM Ex.No.1 Study of G Codes and M Codes to Write Manual Part Programming for Fanuc Control Systems PREPARATORY FUNCTION ( G CODES ) The preparatory functions
CHAPTER 7 GENERAL PROOF SYSTEMS
CHAPTER 7 GENERAL PROOF SYSTEMS 1 Introduction Proof systems are built to prove statements. They can be thought as an inference machine with special statements, called provable statements, or sometimes
KITES TECHNOLOGY COURSE MODULE (C, C++, DS)
KITES TECHNOLOGY 360 Degree Solution www.kitestechnology.com/academy.php [email protected] [email protected] Contact: - 8961334776 9433759247 9830639522.NET JAVA WEB DESIGN PHP SQL, PL/SQL
High-Level Programming Languages. Nell Dale & John Lewis (adaptation by Michael Goldwasser)
High-Level Programming Languages Nell Dale & John Lewis (adaptation by Michael Goldwasser) Low-Level Languages What are disadvantages of low-level languages? (e.g., machine code or assembly code) Programming
Regular Expressions with Nested Levels of Back Referencing Form a Hierarchy
Regular Expressions with Nested Levels of Back Referencing Form a Hierarchy Kim S. Larsen Odense University Abstract For many years, regular expressions with back referencing have been used in a variety
Lecture 1: Introduction
Programming Languages Lecture 1: Introduction Benjamin J. Keller Department of Computer Science, Virginia Tech Programming Languages Lecture 1 Introduction 2 Lecture Outline Preview History of Programming
Embedded Systems. Review of ANSI C Topics. A Review of ANSI C and Considerations for Embedded C Programming. Basic features of C
Embedded Systems A Review of ANSI C and Considerations for Embedded C Programming Dr. Jeff Jackson Lecture 2-1 Review of ANSI C Topics Basic features of C C fundamentals Basic data types Expressions Selection
ML for the Working Programmer
ML for the Working Programmer 2nd edition Lawrence C. Paulson University of Cambridge CAMBRIDGE UNIVERSITY PRESS CONTENTS Preface to the Second Edition Preface xiii xv 1 Standard ML 1 Functional Programming
2 SYSTEM DESCRIPTION TECHNIQUES
2 SYSTEM DESCRIPTION TECHNIQUES 2.1 INTRODUCTION Graphical representation of any process is always better and more meaningful than its representation in words. Moreover, it is very difficult to arrange
CNC HARDWARE & TOOLING BASICS
Computer Aided Manufacturing (CAM) CNC HARDWARE & TOOLING BASICS Assoc. Prof. Dr. Tamer S. Mahmoud 1. Parts of CNC Machine Tools Any CNC machine tool essentially consists of the following parts: Part Program,
Object Oriented Software Design
Object Oriented Software Design Introduction to Java - II Giuseppe Lipari http://retis.sssup.it/~lipari Scuola Superiore Sant Anna Pisa September 14, 2011 G. Lipari (Scuola Superiore Sant Anna) Introduction
FAGOR CNC 8055 ia-mc Control
FAGOR CNC 8055 ia-mc Control The Fagor 8055 i/a-mc CNC control combines value & reliability with a featured packed modular control. This control was built for the shop environment with a rugged keyboard
ADVANCED SCHOOL OF SYSTEMS AND DATA STUDIES (ASSDAS) PROGRAM: CTech in Computer Science
ADVANCED SCHOOL OF SYSTEMS AND DATA STUDIES (ASSDAS) PROGRAM: CTech in Computer Science Program Schedule CTech Computer Science Credits CS101 Computer Science I 3 MATH100 Foundations of Mathematics and
Testing LTL Formula Translation into Büchi Automata
Testing LTL Formula Translation into Büchi Automata Heikki Tauriainen and Keijo Heljanko Helsinki University of Technology, Laboratory for Theoretical Computer Science, P. O. Box 5400, FIN-02015 HUT, Finland
Machine Tool Control. Besides these TNCs, HEIDENHAIN also supplies controls for other areas of application, such as lathes.
Machine Tool Control Contouring controls for milling, drilling, boring machines and machining centers TNC contouring controls from HEIDENHAIN for milling, drilling, boring machines and machining centers
The Technology Behind a Graphical User Interface for an Equational Reasoning Assistant
The Technology Behind a Graphical User Interface for an Equational Reasoning Assistant Andy Gill Department of Computing Science, University of Glasgow Abstract The Haskell Equational Reasoning Assistant
CHAPTER 1. Introduction to CAD/CAM/CAE Systems
CHAPTER 1 1.1 OVERVIEW Introduction to CAD/CAM/CAE Systems Today s industries cannot survive worldwide competition unless they introduce new products with better quality (quality, Q), at lower cost (cost,
Parameter passing in LISP
Parameter passing in LISP The actual parameters in a function call are always expressions, represented as lists structures. LISP provides two main methods of parameter passing: Pass/Call-by-value. The
Informatica e Sistemi in Tempo Reale
Informatica e Sistemi in Tempo Reale Introduction to C programming Giuseppe Lipari http://retis.sssup.it/~lipari Scuola Superiore Sant Anna Pisa October 25, 2010 G. Lipari (Scuola Superiore Sant Anna)
Fun with Phantom Types
1 Fun with Phantom Types RALF HINZE Institut für Informatik III, Universität Bonn Römerstraße 164, 53117 Bonn, Germany Email: [email protected] Homepage: http://www.informatik.uni-bonn.de/~ralf
Glossary of Object Oriented Terms
Appendix E Glossary of Object Oriented Terms abstract class: A class primarily intended to define an instance, but can not be instantiated without additional methods. abstract data type: An abstraction
Visual Programming of Logic, Motion, and Robotics
ADVANCED Motion Controls October 2014 Visual Programming of Logic, Motion, and Robotics Sándor Barta Overview The art of programming consists of mentally translating a workflow into a sequential programming
1 Operational Semantics for While
Models of Computation, 2010 1 1 Operational Semantics for While The language While of simple while programs has a grammar consisting of three syntactic categories: numeric expressions, which represent
Sources: On the Web: Slides will be available on:
C programming Introduction The basics of algorithms Structure of a C code, compilation step Constant, variable type, variable scope Expression and operators: assignment, arithmetic operators, comparison,
Proficiency Test For Machining Center
Proficiency Test For Machining Center Name: Date: Section One: General CNC Questions 1) The spindle speed for a particular tool in a program is incorrect and you wish to reduce it. The kind of CNC word
Bachelors of Computer Application Programming Principle & Algorithm (BCA-S102T)
Unit- I Introduction to c Language: C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating
G10 Data Setting Command
G10 Data Setting Command Though it s barely mentioned in most basic CNC courses, the G10 command is an extremely important basic CNC feature It allows you to input data from within CNC programs This data
C++ INTERVIEW QUESTIONS
C++ INTERVIEW QUESTIONS http://www.tutorialspoint.com/cplusplus/cpp_interview_questions.htm Copyright tutorialspoint.com Dear readers, these C++ Interview Questions have been designed specially to get
Chapter 1. Dr. Chris Irwin Davis Email: [email protected] Phone: (972) 883-3574 Office: ECSS 4.705. CS-4337 Organization of Programming Languages
Chapter 1 CS-4337 Organization of Programming Languages Dr. Chris Irwin Davis Email: [email protected] Phone: (972) 883-3574 Office: ECSS 4.705 Chapter 1 Topics Reasons for Studying Concepts of Programming
Optimized NC programming for machinery and heavy equipment. Summary NX CAM software redefines manufacturing productivity with a full range of NC
Siemens PLM Software NX CAM for machinery Optimized NC programming for machinery and heavy equipment Benefits Effectively program any type of machinery part Program faster Reduce air cutting Automate programming
Introducing Formal Methods. Software Engineering and Formal Methods
Introducing Formal Methods Formal Methods for Software Specification and Analysis: An Overview 1 Software Engineering and Formal Methods Every Software engineering methodology is based on a recommended
Anatomy of Programming Languages. William R. Cook
Anatomy of Programming Languages William R. Cook Copyright (C) 2013 2 Chapter 1 Preliminaries Preface What? This document is a series of notes about programming languages, originally written for students
PART-A Questions. 2. How does an enumerated statement differ from a typedef statement?
1. Distinguish & and && operators. PART-A Questions 2. How does an enumerated statement differ from a typedef statement? 3. What are the various members of a class? 4. Who can access the protected members
1998. (R. Bird and P. Wadler, Introduction to Functional Programming, Prentice
Mathematical Structures in Programs 15 Algebra) The Shorter Oxford English Dictionary): the reunion of broken parts a calculus of symbols combined according to defined laws Haskell 3 4 Richard Bird. Introduction
Timber: A Programming Language for Real-Time Embedded Systems
Timber: A Programming Language for Real-Time Embedded Systems Andrew P. Black, Magnus Carlsson, Mark P. Jones, Richard Kieburtz and Johan Nordlander Department of Computer Science and Engineering OGI School
Introduction to Software Paradigms & Procedural Programming Paradigm
Introduction & Procedural Programming Sample Courseware Introduction to Software Paradigms & Procedural Programming Paradigm This Lesson introduces main terminology to be used in the whole course. Thus,
Short Description Installation Starting Up Configuration. Generalized Postprocessor
Short Description Installation Starting Up Configuration Generalized Postprocessor Index TesoPost Generalized Postprocessor Index... 2 Short Description...3 Concept...3 System Requirements... 4 Delivered
Object Oriented Software Design
Object Oriented Software Design Introduction to Java - II Giuseppe Lipari http://retis.sssup.it/~lipari Scuola Superiore Sant Anna Pisa October 28, 2010 G. Lipari (Scuola Superiore Sant Anna) Introduction
Towards a Framework for Generating Tests to Satisfy Complex Code Coverage in Java Pathfinder
Towards a Framework for Generating Tests to Satisfy Complex Code Coverage in Java Pathfinder Matt Department of Computer Science and Engineering University of Minnesota [email protected] Abstract We present
SmartArrays and Java Frequently Asked Questions
SmartArrays and Java Frequently Asked Questions What are SmartArrays? A SmartArray is an intelligent multidimensional array of data. Intelligent means that it has built-in knowledge of how to perform operations
Programming Languages
Programming Languages Qing Yi Course web site: www.cs.utsa.edu/~qingyi/cs3723 cs3723 1 A little about myself Qing Yi Ph.D. Rice University, USA. Assistant Professor, Department of Computer Science Office:
6.080/6.089 GITCS Feb 12, 2008. Lecture 3
6.8/6.89 GITCS Feb 2, 28 Lecturer: Scott Aaronson Lecture 3 Scribe: Adam Rogal Administrivia. Scribe notes The purpose of scribe notes is to transcribe our lectures. Although I have formal notes of my
Testing and Tracing Lazy Functional Programs using QuickCheck and Hat
Testing and Tracing Lazy Functional Programs using QuickCheck and Hat Koen Claessen 1, Colin Runciman 2, Olaf Chitil 2, John Hughes 1, and Malcolm Wallace 2 1 Chalmers University of Technology, Sweden
Chapter 7: Functional Programming Languages
Chapter 7: Functional Programming Languages Aarne Ranta Slides for the book Implementing Programming Languages. An Introduction to Compilers and Interpreters, College Publications, 2012. Fun: a language
Software documentation systems
Software documentation systems Basic introduction to various user-oriented and developer-oriented software documentation systems. Ondrej Holotnak Ondrej Jombik Software documentation systems: Basic introduction
Mach4 CNC Controller Mill Programming Guide Version 1.0
Mach4 CNC Controller Mill Programming Guide Version 1.0 1 Copyright 2014 Newfangled Solutions, Artsoft USA, All Rights Reserved The following are registered trademarks of Microsoft Corporation: Microsoft,
VHDL Test Bench Tutorial
University of Pennsylvania Department of Electrical and Systems Engineering ESE171 - Digital Design Laboratory VHDL Test Bench Tutorial Purpose The goal of this tutorial is to demonstrate how to automate
CSE 135: Introduction to Theory of Computation Decidability and Recognizability
CSE 135: Introduction to Theory of Computation Decidability and Recognizability Sungjin Im University of California, Merced 04-28, 30-2014 High-Level Descriptions of Computation Instead of giving a Turing
POLYTYPIC PROGRAMMING OR: Programming Language Theory is Helpful
POLYTYPIC PROGRAMMING OR: Programming Language Theory is Helpful RALF HINZE Institute of Information and Computing Sciences Utrecht University Email: [email protected] Homepage: http://www.cs.uu.nl/~ralf/
1 Introduction. 2 An Interpreter. 2.1 Handling Source Code
1 Introduction The purpose of this assignment is to write an interpreter for a small subset of the Lisp programming language. The interpreter should be able to perform simple arithmetic and comparisons
Chapter 13: Program Development and Programming Languages
Understanding Computers Today and Tomorrow 12 th Edition Chapter 13: Program Development and Programming Languages Learning Objectives Understand the differences between structured programming, object-oriented
SINUMERIK 810/840D DIN Programming for Milling
SINUMERIK 810/840D DIN Programming for Milling Training Manual Edition 2008.01 Training Documentation SINUMERIK 810/840D Operating and Programming DIN - Milling Valid for: Control SINUMERIK 810/840D Edition
Notes on Complexity Theory Last updated: August, 2011. Lecture 1
Notes on Complexity Theory Last updated: August, 2011 Jonathan Katz Lecture 1 1 Turing Machines I assume that most students have encountered Turing machines before. (Students who have not may want to look
Tail Recursion Without Space Leaks
Tail Recursion Without Space Leaks Richard Jones Computing Laboratory University of Kent at Canterbury Canterbury, Kent, CT2 7NF rejukc.ac.uk Abstract The G-machine (Johnsson, 1987; Peyton Jones, 1987)
Radius Compensation G40, G41, & G42 (cutter radius compensation for machining centers, tool nose radius compensation for turning centers)
Radius Compensation G40, G41, & G42 (cutter radius compensation for machining centers, tool nose radius compensation for turning centers) These features are commonly well covered in most basic CNC courses.
3. Mathematical Induction
3. MATHEMATICAL INDUCTION 83 3. Mathematical Induction 3.1. First Principle of Mathematical Induction. Let P (n) be a predicate with domain of discourse (over) the natural numbers N = {0, 1,,...}. If (1)
From Wikipedia, the free encyclopedia
Page 1 of 10 CNC From Wikipedia, the free encyclopedia The abbreviation CNC stands for computer numerical control, and refers specifically to a computer "controller" that reads G-code instructions and
Computer Programming I
Computer Programming I COP 2210 Syllabus Spring Semester 2012 Instructor: Greg Shaw Office: ECS 313 (Engineering and Computer Science Bldg) Office Hours: Tuesday: 2:50 4:50, 7:45 8:30 Thursday: 2:50 4:50,
Chapter One Introduction to Programming
Chapter One Introduction to Programming 1-1 Algorithm and Flowchart Algorithm is a step-by-step procedure for calculation. More precisely, algorithm is an effective method expressed as a finite list of
CNC Applications. Introduction to Machining Centers
CNC Applications Introduction to Machining Centers Machining Centers A machining center is simply a CNC milling machine with an automatic tool changer and an enclosure. There are a number of different
Object-Oriented Software Specification in Programming Language Design and Implementation
Object-Oriented Software Specification in Programming Language Design and Implementation Barrett R. Bryant and Viswanathan Vaidyanathan Department of Computer and Information Sciences University of Alabama
El Dorado Union High School District Educational Services
El Dorado Union High School District Course of Study Information Page Course Title: ACE Computer Programming II (#495) Rationale: A continuum of courses, including advanced classes in technology is needed.
Regular Languages and Finite Automata
Regular Languages and Finite Automata 1 Introduction Hing Leung Department of Computer Science New Mexico State University Sep 16, 2010 In 1943, McCulloch and Pitts [4] published a pioneering work on a
Continued Fractions and the Euclidean Algorithm
Continued Fractions and the Euclidean Algorithm Lecture notes prepared for MATH 326, Spring 997 Department of Mathematics and Statistics University at Albany William F Hammond Table of Contents Introduction
1.1 WHAT IS A PROGRAMMING LANGUAGE?
1 INTRODUCTION 1.1 What is a Programming Language? 1.2 Abstractions in Programming Languages 1.3 Computational Paradigms 1.4 Language Definition 1.5 Language Translation 1.6 Language Design How we communicate
Computing Concepts with Java Essentials
2008 AGI-Information Management Consultants May be used for personal purporses only or by libraries associated to dandelon.com network. Computing Concepts with Java Essentials 3rd Edition Cay Horstmann
ASSEMBLY PROGRAMMING ON A VIRTUAL COMPUTER
ASSEMBLY PROGRAMMING ON A VIRTUAL COMPUTER Pierre A. von Kaenel Mathematics and Computer Science Department Skidmore College Saratoga Springs, NY 12866 (518) 580-5292 [email protected] ABSTRACT This paper
Boolean Expressions, Conditions, Loops, and Enumerations. Precedence Rules (from highest to lowest priority)
Boolean Expressions, Conditions, Loops, and Enumerations Relational Operators == // true if two values are equivalent!= // true if two values are not equivalent < // true if left value is less than the
https://williamshartunionca.springboardonline.org/ebook/book/27e8f1b87a1c4555a1212b...
of 19 9/2/2014 12:09 PM Answers Teacher Copy Plan Pacing: 1 class period Chunking the Lesson Example A #1 Example B Example C #2 Check Your Understanding Lesson Practice Teach Bell-Ringer Activity Students
Source Code Translation
Source Code Translation Everyone who writes computer software eventually faces the requirement of converting a large code base from one programming language to another. That requirement is sometimes driven
Certification Authorities Software Team (CAST) Position Paper CAST-13
Certification Authorities Software Team (CAST) Position Paper CAST-13 Automatic Code Generation Tools Development Assurance Completed June 2002 NOTE: This position paper has been coordinated among the
Sample. CNC Programming product family... CNC Programming: Basics & Tutorial Textbook. & CNC Programming: Reference Book. CNC Programming: Workbook
CNC Programming product family... CNC Programming: Basics & Tutorial Textbook CNC Programming: Reference Book CNC Programming: Workbook CNC Programming: Workbook - Instructor Edition CNC Programming: Basics
Robot Task-Level Programming Language and Simulation
Robot Task-Level Programming Language and Simulation M. Samaka Abstract This paper presents the development of a software application for Off-line robot task programming and simulation. Such application
AP Computer Science Java Subset
APPENDIX A AP Computer Science Java Subset The AP Java subset is intended to outline the features of Java that may appear on the AP Computer Science A Exam. The AP Java subset is NOT intended as an overall
The Taxman Game. Robert K. Moniot September 5, 2003
The Taxman Game Robert K. Moniot September 5, 2003 1 Introduction Want to know how to beat the taxman? Legally, that is? Read on, and we will explore this cute little mathematical game. The taxman game
Algorithms, Flowcharts & Program Design. ComPro
Algorithms, Flowcharts & Program Design ComPro Definition Algorithm: o sequence of steps to be performed in order to solve a problem by the computer. Flowchart: o graphical or symbolic representation of
Semester Review. CSC 301, Fall 2015
Semester Review CSC 301, Fall 2015 Programming Language Classes There are many different programming language classes, but four classes or paradigms stand out:! Imperative Languages! assignment and iteration!
Lecture 1: Systems of Linear Equations
MTH Elementary Matrix Algebra Professor Chao Huang Department of Mathematics and Statistics Wright State University Lecture 1 Systems of Linear Equations ² Systems of two linear equations with two variables
The ProB Animator and Model Checker for B
The ProB Animator and Model Checker for B A Tool Description Michael Leuschel and Michael Butler Department of Electronics and Computer Science University of Southampton Highfield, Southampton, SO17 1BJ,
Acta Universitaria ISSN: 0188-6266 [email protected] Universidad de Guanajuato México
Acta Universitaria ISSN: 0188-6266 [email protected] Universidad de Guanajuato México Ramos-Díaz, J. Guadalupe; Navarro, Isela; Silva, Josep; Arroyo, Gustavo Defining DSL design principles for
G and M Programming for CNC Milling Machines. Denford Limited Birds Royd Brighouse West Yorkshire England HD6 1NB Tel: +44 (0) 1484 712264
COMPUTERISED MACHINES AND SYSTEMS G and M Programming for CNC Milling Machines Denford Limited Birds Royd Brighouse West Yorkshire England HD6 1NB Tel: +44 (0) 1484 712264 G AND M Fax: PROGRAMMING +44
CNC Turning Training CNC MILLING / ROUTING TRAINING GUIDE. www.denford.co.uk Page 1
CNC Turning Training www.denford.co.uk Page 1 Table of contents Introduction... 3 Start the VR Turning Software... 3 Configure the software for the machine... 4 Load your CNC file... 5 Configure the tooling...
Working with Machine and Control Definitions
Working with Machine and Control Definitions This document is designed to be a companion to the Working with Machine and Control Definition set of videos that was introduced in January 2006. The first
Programming Language Rankings. Lecture 15: Type Inference, polymorphism & Type Classes. Top Combined. Tiobe Index. CSC 131! Fall, 2014!
Programming Language Rankings Lecture 15: Type Inference, polymorphism & Type Classes CSC 131 Fall, 2014 Kim Bruce Top Combined Tiobe Index 1. JavaScript (+1) 2. Java (-1) 3. PHP 4. C# (+2) 5. Python (-1)
Chapter 9. Systems of Linear Equations
Chapter 9. Systems of Linear Equations 9.1. Solve Systems of Linear Equations by Graphing KYOTE Standards: CR 21; CA 13 In this section we discuss how to solve systems of two linear equations in two variables
