Mathias Ricken

Mathias Ricken


Home

Bio


CV/Resume


Curriculum Vitae (pdf)
(doc)  (txt)  (embedded)

Resume (pdf)
(doc)  (txt)  (embedded)


Publications


External linkArchive on A Concurrent Affair

RSSPublication RSS Feed


Research Projects


External linkConcutest: A Framework for Testing Concurrent Programs

Mint: Multi-stage Programming for Java

xajavac: Extended Annotations-Enabled javac

LAPT-javac: Local Variable-Enabled javac

DrJava IDE

Programming for Change: The Temperature Calculator

Object-Oriented Design Festival

Design Patterns for Parsing

Assignments for an Objects-First Curriculum

Design Patterns for Marine Biology Simulation

Geometry Synthesis

DrC# IDE

Geometry Synthesis by Analogy

Teaching


External linkCOMP 410 - Software Engineering Methodology

Past Classes

Blog


External linkA Concurrent Affair

RSSBlog RSS Feed


External linkMy Academia.edu
External linkPapers
External linkTalks
External linkTeaching

External linkMy SciNetSC

Shared Feed Items

      Programming for Change: The Temperature Calculator

Contents

Dr. Dung Nguyen and I have created an assignment for an object-oriented CS2 introductory programming course that illustrates the process and importance of programming for change. It uses the Temperature Calculator from our SIGCSE 2006 workshop.

This material has been accepted for publication as "nifty assignment" and was presented at the OOPSLA 2006 Educators' Symposium in Portland, Oregon, on October 23, 2006.

Abstract

The development of any piece of software begins with a set of specifications describing in some detail the problems to be solved. Almost invariably, the specifications change during the development of the software. Trying to anticipate all possible changes and write a program that does everything is a futile undertaking. However, it is not unreasonable to expect that programs be written in such a way that an "epsilon" (read "small") change in the specifications will only necessitate a "delta" (read "manageable") change in code.

Programming for change is a continual process in which software is designed over many iterations to capture the problem's essence and express. At the heart of this process is the effort to identify those elements that can vary (variants) and delineate them from those that do not — the invariants. A properly designed software system should strive to decouple the variants from the invariants in order to facilitate the re-use of the invariants and allow modifications to the variants with minimal perturbation to the existing code.

To illustrate the importance of programming for change to students, we guide them through the development of a program that converts temperature measurements. The assignment consists of a series of small exercises, each of which imposes a small change in the requirements and forces appropriate modifications of the code. To promote code re-use, we apply the Janus Principle and require that the programs must be written in a way that supports multiple distinct user interfaces. For certain specification changes, we ask students to identify the variants and the invariants and make appropriate modifications to the code. In several situations, we require the students to modify their code in more than one way and discuss the pros and cons.

Materials

All of the materials of Temperature Calculator: Programming for Change are available online:


         
http://www.cs.rice.edu/research/tempcalc/index.shtml
Copyright © 2002-2011 by Mathias Ricken. All rights reserved.