Subject: Re: CCL:Design/OO/standardization

From: Konrad Hinsen <[email-masked]>
Date: Fri, 8 Aug 1997 16:13:15 +0200

> Development of software for Computational Chemistry
> by researchers is usualy focused on new methodologies.
> That's a matter of specialization: people who develop
> and maintain scientific software have less time to use 
> these software to applied research than people interested
> in applications only. These two communities have distinct
> needs: 
>...

The needs are distinct, but that doesn't mean that they can't be dealt
with in a single implementation. A well-designed modular system
would consist of well-tested high-performance modules for established
techniques and experimental modules for experimental techniques.

> Computer scientific community uses standardization commitees
> that consist of experts in one field talking together until they
> agree on a standard: ONE way to do something that meet experts
> idea of what is important (performances, reusability, extensability..).

That is one possibility, but equally many products are essentially
designed by a single person. There are good and bad aspects about
both approaches.

> What about standardizing interfaces for common algorithms ?
> It seems to me that a minimization algorithm looks like
> another and should be used the same way from the code
> I'm writing (whatever the implementation I actually decide
> to retain)

Almost. Minimization algorithms do essentially the same job, but
require different parameters for controlling convergence, step sizes,
etc. And there are many more situations in which various algorithms
have almost the same interface.

An OO solution to this problem is to encapsulate the algorithm in
an object that also stores all the parameters. For example, you
could create a "steepest descent object" with a certain parameters
and a "conjugent gradient object" with another set of parameters,
and then apply the two in exactly the same way to a molecular
system.

> Couldn't we design our software so that algorithms are
> parameters for algorithms (at compile time). Maybe an example

Once algorithms are encapsulated in objects, this is trivial:
the algorithm object is simply passed as an ordinary parameter.
For an example, look at the description of minimizer objects
in my Molecular Modelling Toolkit; the relevant page of the manual
is http://starship.skyport.net/crew/hinsen/mmtk_manual/dynamics.html.
-- 
-------------------------------------------------------------------------------
Konrad Hinsen                          | E-Mail: [email-masked]
Laboratoire de Dynamique Moleculaire   | Tel.: +33-4.76.88.99.28
Institut de Biologie Structurale       | Fax:  +33-4.76.88.54.94
41, av. des Martyrs                    | Deutsch/Esperanto/English/
38027 Grenoble Cedex 1, France         | Nederlands/Francais
-------------------------------------------------------------------------------