added some routines to implement multiparameter bfgs optimization,
the routines are not called yet