Function Machines is based on a "function as machine" metaphori n which mathematical functions are viewed as machines that communicatewith other machines through data flow and control flow connections. The system provides as primitive constructs, machines correspondingto the standard mathematical, graphics, list processing, logic,and I/O operations found in one-dimensional languages. Thesemachines are used as building blocks to construct more complexmachines in a modular and extensible fashion. The explicit representationof data paths (by graphically animating the passage of data betweenmachines) and the explicit representation of control paths (byillumination of currently running machines and by graphicallyanimating the passage of control activation) makes the semanticsof functional operation transparently clear in Function Machines. The operation of recursion is made visually explicit by displayinga separate window for each instantiation of the procedure as itis created, and erasing it when it terminates. Function Machinesthus provides a natural starting point for the teaching of programmingas a prelude and complement to nontrivial work with functionallanguages like Logo and Scheme.
In the Function Machines environment, a machine runs wheneverits inputs are available. Since this can occur simultaneouslyfor several machines, the system naturally supports parallel operation. Thus, as well as facilitating the teaching of programming andmathematical inquiry, the system opens new opportunities for introducingthe study of parallel algorithms and models, an "advanced" topic, to beginning students of mathematics. Function Machineshas been piloted in several elementary and secondary mathematicsclassrooms. I will show several examples of teachers' and students'work.