Proposed specification for estimation functions

This includes factorization of common code and extensions for (unexpected) structural change

Estimated parameters description

xparam1 becomes a structure with the following fields

Functions