Problem Set 2, 6.964 Pervasive Computing, September 25, 2001 Due: Oct 11, 2001 Title: Equation Specifier via widgets on the ipaq The purpose of this assignment is to learn how to build an application that uses buttons, menus, lists, and pop-up windows for user input on an iPaq. There are many ways to build such applications; we are going to suggest using the GTK+ package. GTK+ is a set of runtime routines that manage the layout of widgets on the screen and associates a set of events and call-backs with actions associated with the widget. Glade, a GUI program that automatically generates the GTK+ calls is a great way to start. You can then muck around with the low-level GTK+ routines, either in C, C++, or Python. Python is simplier but may be hard to figure out what to do; C requires either a native compilation on the ra.lcs.mit.edu maching or a cross compilation step. Glade information can be found at http://glade.gnome.org. The assignment is to build the buttons to input mathematical equations. I have specified a minimal grammar; feel free to extend and generalize. Commands such as simplify or integrate will eventually be hooked up to a mathematica or maple backend. For now, just have those buttons do something silly until we learn about network communication. You can also postpone the actual display of the equation until we get some flash cards for the ipaq. You have two weeks for the assignment and may work in pairs. The goal of this project is to make sure you know how to build a simple input module for the iPaq as it will be needed for the final project. This current assignment is just a way to get you started. Commands: * Define equation e * Simplify e * Display e * Differentiate e * Differentiate e with respect to * Integrate e * Integrate e with respect to Equations: * plus e.g. x+y * minus e.g. y-e2 * of e.g. g(x) * times e.g. x*y * multiplied by e.g. x*y * divided by e.g. x/y * to the power of e.g. x^y * to e.g. x^y Where can be either "u, v, w, x, y, z" or e and is either "f, g, h"