This Thursday evening I had a business meeting with Damir Tomicic and during that we also had some fun chat. I explained him some thoughts I'm carrying with me for a long time now about what "elegance" means when we talk about software. He seemed to find it funny, so I feel encouraged to blog about that.
Isn't it interesting that disciplines like mathematics or computer science which to most mere mortals appear to be very dry, for those working in these disciplines you find a very common sense for aesthetics in their disciplines? When you studied mathematics, don't you remember those magic moments when you studied a theorem and while reading the proof you got electrified by the "beauty" of what you just understood? Wasn't there a magic moment when you studied a software implementation and then you felt: what a beautiful solution to that problem? Or didn't you study whole architectures where you got the feeling that all that is very elegant?
I find it kind of interesting that people working in these very formal sciences have such a sensory for vague concepts like "beauty" or "elegance". I remember when I studied mathematics (now more than two decades ago), I read a book about the foundations of mathematics and there I found the semi-formal definition of what "elegance" means for the proof of a mathematical theorem (unfortunately I don't remember the author): the elegance of a proof is proportional to the number of further ideas you can derive from that proof and inverse proportional to the efforts you have to spend for the proof.
If you translate that definition to a software implementation or an architecture, it may look like
"Elegance of Architecture ~ (Number of further ideas you can derive from it) / (Efforts to implement it)"
Of course the measurability of the nominator and the denominator is a tough challenge:-) But as someone working in and with formal disciplines I now feel much more comfortable to have a formula (metric) for "elegance" or "beauty"[:D]