Transformations In Functional and Database Contexts
Two tutorials reflected the wide range of application of transformation techniques: Zhenjiang Hu (University of Tokyo) focused on deterministic transformations from one algorithmic representation of a functional program to another, and Jean-Luc Hainault (University of Namur) showed jhow transformation tie all the levels a database schema together and how to take advantage of this.
Zhenjiang described how to write both clear and efficient programs. He proposes to write clear programs not bothering about efficiency, then to transform them automatically to make them more efficient. This is not low-level compiler optimization but high-level transformations where lists or trees can be merged with the corresponding transformations to their corresponding functions. An existing way to perform this optimization is to expand function calls and propagate known facts (unfolding), while searching for expressions that can be converted back into function calls (folding). This so-called "fold/unfold" method is somewhat heuristic as there is no easy way to decide what can or cannot be folded. Zhenjiang argued that a better way to transform the code is through program calculation where no guessing is necessary--"you just need to solve equations!".
There is a catch. The programs must be written using homomorphisms (a restricted form of recursion) and promotions (transformation properties of the homomorphisms) need to be defined. He then used his method to easily transform an inefficient max function built by selecting the first result of a sort function into an efficient program. Going a bit deeper he showed how different loops can be merged together in a formal manner (loop fusion) and how parallel execution also fits into program calculation. If you have ever delved some depth into functional programming you will know how tricky it is to get anywhere near this type of result. These technics are definitely impressive and supported as part of Haskell tool he has written.
Jean-Luc Hainault's tutorial was more pragmatic. He has led a team that has developed a "universal" database schema model. He has taken many different existing schema models (for example, conceptual, logical, physical, product specific, SQL, COBOL, relational, UML, and so on) and brought them all into a single model. He can then apply 40 or so primitive operations which lets him convert pretty much any type of schema to another. This is really impressive, but gets even better because many of these transformations can be run backwards--allowing reengineering from a deeper schema level to a higher one. With the addition of a COBOL analysis tool he showed us how he could make sense out of 30-year old databases. He did mention that for these types of refactoring some human help is needed. The work is available as part of the DB-MAIN tool. Anthony Cleve, a member of Jean-Luc's team, later showed us how queries could be transformed to automatically reflect schema transformations, including both COBOL and SQL sources.