
Invariants are defined as predicates on the store and are proved by structural in-
duction on the system state: i.e. as a base step, prove that the initial state satisfies the
invariant and then, as inductive steps, prove that each collaboration maintains it. The
following is a global invariant we proved about the library system which is expressed
by Object Constraint Language (OCL [3]). This says ”the total number of items lent by
all customers is equal to the number of items unavailable”.
library
customer.lend->size = item->select(lend->size>0)->size
3 Related works
A lot of works including [7] [8] has proposed theories to verify OO programming lan-
guage. Our theory is similar to them but different in that it is for the verification of
analysis models, where we can use not only basic types of programming languages but
high abstract types that appear in the system domain.
4 Conclusions and future work
This paper has presented a methodology of OO model verification based on collabo-
rations in HOL. Collaborations are expressed as sequences of function application and
defined by operators introduced in the theory corresponding to the model elements.
Invariants that are global in the system are proved by induction on the system state.
As a future work, we are considering to develop a collaboration-based design method-
ology based on our OO theory. We are currently interested in applying our theory to
layered designs [6], where systems are constructed incrementally as layers of collabo-
rations. We expect that an effective proof methodology can be established by clarifying
the relationship between layered collaborations and dependency of their invariants.
References
1. OMG. Unified Modeling Language. URL: http://www.omg.org/.
2. The HOL system. URL: http://hol.sourceforge.net/.
3. J. Warmer and A. Kleppe. The object constraint language: precise modeling with UML.
Addison-Wesley.
4. E.M.Clarke and W.Heinle: Modular Translation of Satatecharts to SMV, Technical Report
CMU-CS-00-XXX, Carnegie Mellon University School of Computer Science, 2000.
5. T.Schafer, A.Knapp, and S.Merz: Model Checking UML State Machines and Collaborations,
Electric Notes in Theoretical Computer Science 47, 2001.
6. Y. Smaragdakis and D. Batory. Implementing layered designs with mixin layers. Proceedings
of the European Conference on Object-Oriented Programming (ECOOP), 1998.
7. A. Poetzsch-Heffter and P. Muller. Logical foundation for typed object-oriented languages.
Programing Concepts and Methods (PROCOMET), 1998.
8. J. van den Berg, M. Huisman, B. Jacobs, and E. Poll. A type-theoretic memory model for
verification of sequential Java programs. Techn. Rep. CSI-R9924, Comput. Sci. Inst., Univ. of
Nijmegen, 1999.
80