Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!uunet!munnari.oz.au!bunyip.cc.uq.oz.au!brolga!uqcspe!cs.uq.oz.au!brendan From: brendan@cs.uq.oz.au (Brendan Mahony) Newsgroups: comp.specification Subject: Re: Skepticism Towards Specifications Message-ID: <1921@uqcspe.cs.uq.oz.au> Date: 13 Jun 91 01:11:43 GMT References: <1991Jun12.203347.17380@netcom.COM> Sender: news@cs.uq.oz.au Reply-To: brendan@cs.uq.oz.au Lines: 43 In <1991Jun12.203347.17380@netcom.COM> jls@netcom.COM (Jim Showalter) writes: >[someone with whom I agree states:] ->I'd assert, however, that ->more than 95% of a reasonably sized program's code is an attempt at writing ->a non-ambiguous specification. 1/2 :-) It would seem that 5% of the program code is completely wasted then :-). >I think there is a lesson here for anyone who wants to specify systems >in a formal language--it may well be the case that any time one wants >to formally specify a system of suitable complexity to be interesting, >the resulting specification language is itself so complex that it provides >scant improvement over English or, alternatively, the language of >implementation itself. (There are certainly development groups I'm aware >of that use Ada as their specification and implementation language.) I think you are getting a little bit confused between two connotations of the word specify. I would label them specify-requirements and characterise. If you want a full characterisation of the behaviour of a program then it is likely that you will be able to express it most succinctly in the programming language itself. This is the most complete specification of the expected behaviour of the program. If on the other hand you simply want to specify what you intend to use the program to do, it is rare that arrays, files, pointers, interrupts etc are required to express your meaning. The best language to write this specification is the language people normally use in discussing the sort of problem that is to be solved. If you wish to perform integer calculations then integer arithmetic proves the appropriate language; if you wish to heat a room you use the language of thermodynamics; etc.. What you really need is a specification language that lets you adopt the vocabulary appropriate to the application domain. It is also useful to adopt a development strategy that lets you progressively replace the language of the application domain with the language of programming (arrays, files, pointers, etc.) so that each level of development may be discussed in the most appropriate language for the objects being manipulated. -- Brendan Mahony | brendan@batserver.cs.uq.oz Department of Computer Science | heretic: someone who disgrees with you University of Queensland | about something neither of you knows Australia | anything about.