next up previous contents
Next: Program flows Up: Code implementation Previous: The critical path retrieving   Contents

The derived classes

Every time a new optimization algorithm or a new simulator must be introduced a new class should be derived from the main classes.

As examples, the class for the HSPICE simulator is derived as:


\begin{listingcont}
class Hspice: public EvaluationAlgorithm
{
private:
...
pub...
...it,
const double *NewWidth,
const unsigned* ValidPath);
};
\end{listingcont}

and the class for the Powell optimization algorithm (§4.2.3.2, page [*]) is derived as:


\begin{listingcont}
class Powell: public OptimizationAlgorithm
{
private:
...
p...
... EvaluationAlgorithm& simulation );
~Powell();
int Run();
};
\end{listingcont}

Basically, both the classes should provide only the method Run(...) (with different parameters, of course), that performs the real simulation or the real optimization algorithm.



marco+site@equars.com