Variation Programming with the Choice Calculus

The choice calculus provides a language for representing and transforming variation in software and other structured documents. Variability is captured in localized choices between alternatives. The space of all variations is organized by dimensions, which provide scoping and structure to choices. The variation space can be reduced through a process of selection, which eliminates a dimension and resolves all of its associated choices by replacing each with one of their alternatives. The choice calculus also allows the definition of arbitrary functions for the flexible construction and transformation of all kinds of variation structures. In this tutorial we will first present the motivation, general ideas, and principles that underlie the choice calculus. This is followed by a closer look at the semantics. We will then present practical applications based on several small example scenarios and consider the concepts of ”variation programming” and ”variation querying”. The practical applications involve work with a Haskell library that supports variation programming and experimentation with the choice calculus.

[1]  Mira Mezini,et al.  Variability management with feature-oriented programming and aspects , 2004, SIGSOFT '04/FSE-12.

[2]  Michael D. Adams Scrap your zippers: a generic zipper for heterogeneous types , 2010, WGP '10.

[3]  Walter F. Tichy,et al.  Tools for Software Configuration Management , 1988, SCM.

[4]  Andreas Classen,et al.  Tag and prune: a pragmatic approach to software product line implementation , 2010, ASE.

[5]  Martin Erwig,et al.  The Choice Calculus: A Representation for Software Variation , 2011, TSEM.

[6]  Ridha Khédri,et al.  Feature Algebra , 2006, FM.

[7]  Klaus Pohl,et al.  Software Product Line Engineering , 2005 .

[8]  Martin Erwig,et al.  A language for software variation research , 2010, GPCE '10.

[9]  Walter F. Tichy,et al.  Implementation and evaluation of a revision control system , 1982 .

[10]  Henry Spencer,et al.  #ifdef Considered Harmful, or Portability Experience with C News , 1992, USENIX Summer.

[11]  Philip Wadler,et al.  Theorems for free! , 1989, FPCA.

[12]  Sven Apel,et al.  Analyzing the discipline of preprocessor annotations in 30 million lines of C code , 2011, AOSD '11.

[13]  Stephen R. Davis,et al.  The C++ Preprocessor , 2011 .

[14]  David Lorge Parnas,et al.  On the Design and Development of Program Families , 2001, IEEE Transactions on Software Engineering.

[15]  Sven Apel,et al.  Granularity in software product lines , 2008, 2008 ACM/IEEE 30th International Conference on Software Engineering.

[16]  Gordon Reynolds,et al.  G T-B , 1980 .

[17]  Tim Sheard,et al.  Accomplishments and Research Challenges in Meta-programming , 2001, SAIG.

[18]  Bryan O'Sullivan,et al.  Making Sense of Revision-control Systems , 2009, ACM Queue.

[19]  Tobias Nipkow,et al.  FM 2006: Formal Methods, 14th International Symposium on Formal Methods, Hamilton, Canada, August 21-27, 2006, Proceedings , 2006, FM.

[20]  Sven Apel,et al.  An Overview of Feature-Oriented Software Development , 2009, J. Object Technol..

[21]  Simon L. Peyton Jones,et al.  Scrap your boilerplate: a practical design pattern for generic programming , 2003, TLDI '03.

[22]  Tzilla Elrad,et al.  Aspect-oriented programming: Introduction , 2001, CACM.

[23]  Mira Mezini,et al.  Conquering aspects with Caesar , 2003, AOSD '03.

[24]  Chuan Yi Tang,et al.  A 2.|E|-Bit Distributed Algorithm for the Directed Euler Trail Problem , 1993, Inf. Process. Lett..

[25]  David Roundy Darcs: distributed version management in haskell , 2005, Haskell '05.

[26]  Martin Erwig,et al.  Program fields for continuous software , 2010, FoSER '10.

[27]  Peter A. Darnell,et al.  The C Preprocessor , 1991 .

[28]  Stephen A. MacKay,et al.  The State of the Art in Concurrent, Distributed Configuration Management , 1995, SCM.

[29]  Walid Taha,et al.  MetaML and multi-stage programming with explicit annotations , 2000, Theor. Comput. Sci..

[30]  Don S. Batory,et al.  Feature Models, Grammars, and Propositional Formulas , 2005, SPLC.

[31]  Gordon Bell,et al.  Digital immortality , 2001, CACM.

[32]  Ali Ebnenasir,et al.  Feasibility of Stepwise Design of Multitolerant Programs , 2011, TSEM.

[33]  William G. Griswold,et al.  Getting started with ASPECTJ , 2001, CACM.

[34]  Simon L. Peyton Jones,et al.  Template meta-programming for Haskell , 2002, Haskell '02.

[35]  Chris Okasaki,et al.  Purely functional data structures , 1998 .

[36]  Klaus Pohl,et al.  Software Product Line Engineering - Foundations, Principles, and Techniques , 2005 .

[37]  Tom Mens,et al.  A State-of-the-Art Survey on Software Merging , 2002, IEEE Trans. Software Eng..

[38]  Kyo Chul Kang,et al.  Feature-Oriented Domain Analysis (FODA) Feasibility Study , 1990 .

[39]  Walid Taha Semantics, Applications, and Implementation of Program Generation , 2003, J. Funct. Program..

[40]  Don S. Batory,et al.  Scaling step-wise refinement , 2004, IEEE Transactions on Software Engineering.

[41]  Umeshwar Dayal,et al.  An Overview of Repository Technology , 1994, VLDB.

[42]  William R. Cook,et al.  Mixin-based inheritance , 1990, OOPSLA/ECOOP '90.