# Thursday, October 08, 2009

When I use the term software engineering, the definition I am referring to is:

“Software Engineering is the application of a systematic, disciplined, quantifiable approach to the development, operation, and maintenance of software, and the study of these approaches; that is, the application of engineering to software.” 

So what then is a Software Abstraction?  Take this paragraph from the awesome book, “Software Abstractions”, by Daniel Jackson:

“Software is built on abstractions.  Pick the right ones, and programming will flow naturally from design, modules will have small and simple interfaces, and new functionality will more than likely fit in without extensive reorganization.  Pick the wrong ones, and programming will be a series of nasty surprises: interfaces will become baroque and clumsy as they are forced to accommodate unanticipated interactions, and even the simplest of changes will be hard to make.  No amount of refactoring, bar starting again from scratch, can rescue a system built on flawed concepts”.

Brilliant!  It’s the first paragraph of the 1st chapter into a world of real software design - i.e. formal specification, including the ability to model and automatically analyze your design:

“Unlike theorem proving, this analysis is not “complete”: it examines only a finite space of cases.  But because of recent advances in constraint – solving technology, the space of cases examined is usually huge – billions of cases or more – and therefore offers a degree of coverage unattainable in testing.”

“Moreover, unlike testing, this analysis requires no test cases.  The user instead provides a property to be checked, which can usually be expressed succinctly as a single test case.  A kind of exploration therefore becomes possible that combines the incrementally and immediacy of extreme programming with the depth and clarity of formal specification.”

Check out Alloy Analyzer and the Community.

It’s slow going for me, but I am getting through the book.  Until you read this and run Alloy Analyzer, you cannot imagine the number of “cases” Alloy Analyzer can run, like the text says, a billion or more.  It picks apart your design like you have never seen before.  Imagine what the number of cases would be when you combine dozens of models to formulate a software application. 

This is a leap forward in software engineering design in my opinion.  Being able to analyze your design against a billion cases without writing a single line of production or test code is unheard of in mainstream software development industry today.  Using this design approach will produce software design's that will be more robust, perhaps by orders of magnitude, than any manual method we apply today.  The software design itself, is a complete formal specification used by the “end” software programming language to transform the complete design into a runtime solution.

What about the software engineering definition comment in the opening?  I am pointing out that we are following the definition of software engineering by using Alloy for designing software; it is one way to apply a systematic, disciplined and quantifiable approach to software design.  In my opinion, we as an industry, and as professionals, should be applying more effort towards software design.  Why?  Read the “Software is built on abstractions…” paragraph again.

Daniel Jackson and his team’s work on Alloy Analyzer, to me, is the state of the art in software design today.  When will it become mainstream?  Good question, but you can help.  As a Software Designer, have a look at Alloy.  Maybe apply it to a hobby project.  With enough practice, perhaps introduce formal design specification to the workplace on one small specific issue or algorithm you are working on.  That's my approach.

I know change is hard and everyone resists, but look at it as an experiment to try out, see how it works, and if it makes sense to you.  As a software engineering practitioner, I am trying to become a better software designer by learning new concepts and techniques.  I believe Daniel Jackson’s Alloy makes me a better software designer.

 

Thursday, October 08, 2009 11:57:34 PM (Pacific Daylight Time, UTC-07:00)  #    Comments [0]