[syllabus] | [lecture notes] | [HW1-6,Q1] | [HW7-10,Q2,F] | [project]
[simulators/parsers] | [language definitions] | [automata definitions] | [computable definitions]
The goal of the semester project is to be sure you understand some part of this course in detail.
Pick one of the following, do two for extra credit: 1) Write a program in a language of your choice to convert a DFA machine description into a regular grammar. Use the formats defined on Simulators/Parsers 2) Write a program in a language of your choice to convert a regular grammar into a DFA. Use the formats defined on Simulators/Parsers 3) Write a Turing Machine program to do the following: Given an input tape with two numbers in monadic form, produce an output that is the product. Typical input format 111*11= Tape at finish 111*11=111111 e.g. 3*2=6 Use the formats defined on Simulators/Parsers 4) Write a Turing Machine program to do the following: Given an input tape with two binary numbers, twos complement, do a subtract operation. Typical input format 0111-0101= Tape at finish 0111-0101=0010 e.g. 7-5=2 Handle positive and negative input and output. Use the formats defined on Simulators/Parsers Suggested First test 01-00= result 1 OK for all inputs to have leading zero Second test 01-01= result 0 Remember the definitions and correspondences between machines and grammars: +--------------------+ | +----------------------+ | | | | G = ( V, T, P, S) M = ( Q, Sigma, delta, q0, F) | | | | | +----------------------------+ +--------------------------+ T and Sigma are single characters (or one character long strings) V and Q are case sensitive strings. (can be used interchangeably) keywords are case sensitive. Basically, everything is case sensitive.
From a gl machine, e.g. linux.gl.umbc.edu, ... Submit your source code file(s). NO Binary, NO executable. Submit your input data file(s). Submit you output file(s) that your source code produced doing the conversion. (Be sure to label which input files went to which source code if you did the extra credit of doing both conversions.) The command to do the submit is: submit cs451 proj1 <your file names> # project submit cs451 proj2 <your file names> # extra credit The 'submit' command takes multiple, space separated, files. Multiple 'submit' commands can be used to each send one or more files. Send only plain text files because I am just going to print them on a dumb printer and grade the printed output. If for some reason 'submit' will not work for you, print out what is supposed to be submitted, add a table of contents and say what part(s) you completed, turn in a project folder, or EMail to squire@umbc.edu .
DO NOT LEAVE THIS TO THE LAST DAY! Expect to spend 8 hours of very careful programming on this project. (It will take 40 hours if you are sloppy or careless.) Comment your code as much for yourself as for grading. Use indentation to match the structure of your code. You can leave debug print in your code, under control of something to turn it off when generating the output that is turned in.
Grading: 50% for a reasonable try that reads and prints the data 75% for some correct output 100% for correct output 110% for converting one way, then converting back (or in general, extra credit) Points can be lost by: Partially incorrect results, Lack of comments to follow what code is doing at a coarse level. Really bad programming practice. Partial credit will be given for partially working code. Get some amount of output.
Last updated 4/1/21