10 #ifndef ROOT_Minuit2_MnUserTransformation 
   11 #define ROOT_Minuit2_MnUserTransformation 
   29 class MnUserCovariance;
 
   38 class MnUserTransformation {
 
   42    MnUserTransformation() : fPrecision(MnMachinePrecision()),
 
   43                             fParameters(std::vector<MinuitParameter>()),
 
   44                             fExtOfInt(std::vector<unsigned int>()),
 
   45                             fDoubleLimTrafo(SinParameterTransformation()),
 
   46                             fUpperLimTrafo(SqrtUpParameterTransformation()),
 
   47                             fLowerLimTrafo(SqrtLowParameterTransformation()),
 
   48                             fCache(std::vector<double>()) {}
 
   50    MnUserTransformation(
const std::vector<double>&, 
const std::vector<double>&);
 
   52    ~MnUserTransformation() {}
 
   54    MnUserTransformation(
const MnUserTransformation& trafo) :
 
   55       fPrecision(trafo.fPrecision),
 
   56       fParameters(trafo.fParameters),fExtOfInt(trafo.fExtOfInt),
 
   57       fDoubleLimTrafo(trafo.fDoubleLimTrafo),
 
   58       fUpperLimTrafo(trafo.fUpperLimTrafo),
 
   59       fLowerLimTrafo(trafo.fLowerLimTrafo), fCache(trafo.fCache) {}
 
   61    MnUserTransformation& operator=(
const MnUserTransformation& trafo) {
 
   63          fPrecision = trafo.fPrecision;
 
   64          fParameters = trafo.fParameters;
 
   65          fExtOfInt = trafo.fExtOfInt;
 
   66          fDoubleLimTrafo = trafo.fDoubleLimTrafo;
 
   67          fUpperLimTrafo = trafo.fUpperLimTrafo;
 
   68          fLowerLimTrafo = trafo.fLowerLimTrafo;
 
   69          fCache = trafo.fCache;
 
   77   std::vector<double> operator()(
const MnAlgebraicVector&) 
const;
 
   83    double Int2ext(
unsigned int, 
double) 
const;
 
   86    double Int2extError(
unsigned int, 
double, 
double) 
const;
 
   88    MnUserCovariance Int2extCovariance(
const MnAlgebraicVector&, 
const MnAlgebraicSymMatrix&) 
const;
 
   91    double Ext2int(
unsigned int, 
double) 
const;
 
   94    double DInt2Ext(
unsigned int, 
double) 
const;
 
  100    unsigned int IntOfExt(
unsigned int) 
const;
 
  103    unsigned int ExtOfInt(
unsigned int internal)
 const {
 
  104       assert(
internal < fExtOfInt.size());
 
  105       return fExtOfInt[
internal];
 
  108    const std::vector<MinuitParameter>& Parameters()
 const {
 
  112    unsigned int VariableParameters()
 const {
return static_cast<unsigned int> ( fExtOfInt.size() );}
 
  115    const std::vector<double> & InitialParValues()
 const {
 
  122    const MnMachinePrecision& Precision()
 const {
return fPrecision;}
 
  123    void SetPrecision(
double eps) {fPrecision.SetPrecision(eps);}
 
  127    std::vector<double> Params() 
const;
 
  128    std::vector<double> Errors() 
const;
 
  131    const MinuitParameter& Parameter(
unsigned int) 
const;
 
  134    bool Add(
const std::string &, 
double, 
double);
 
  136    bool Add(
const std::string &, 
double, 
double, 
double, 
double);
 
  138    bool Add(
const std::string &, 
double);
 
  141    void Fix(
unsigned int);
 
  142    void Release(
unsigned int);
 
  143    void RemoveLimits(
unsigned int);
 
  144    void SetValue(
unsigned int, 
double);
 
  145    void SetError(
unsigned int, 
double);
 
  146    void SetLimits(
unsigned int, 
double, 
double);
 
  147    void SetUpperLimit(
unsigned int, 
double);
 
  148    void SetLowerLimit(
unsigned int, 
double);
 
  149    void SetName(
unsigned int, 
const std::string &);
 
  151    double Value(
unsigned int) 
const;
 
  152    double Error(
unsigned int) 
const;
 
  155    void Fix(
const std::string &);
 
  156    void Release(
const std::string &);
 
  157    void SetValue(
const std::string &, 
double);
 
  158    void SetError(
const std::string &, 
double);
 
  159    void SetLimits(
const std::string &, 
double, 
double);
 
  160    void SetUpperLimit(
const std::string &, 
double);
 
  161    void SetLowerLimit(
const std::string &, 
double);
 
  162    void RemoveLimits(
const std::string &);
 
  164    double Value(
const std::string &) 
const;
 
  165    double Error(
const std::string &) 
const;
 
  168    unsigned int Index(
const std::string &) 
const;
 
  170    int FindIndex(
const std::string & ) 
const;
 
  173    const std::string & GetName(
unsigned int) 
const;
 
  175    const char* Name(
unsigned int) 
const;
 
  179    MnMachinePrecision fPrecision;
 
  181    std::vector<MinuitParameter> fParameters;
 
  182    std::vector<unsigned int> fExtOfInt;
 
  184    SinParameterTransformation fDoubleLimTrafo;
 
  185    SqrtUpParameterTransformation fUpperLimTrafo;
 
  186    SqrtLowParameterTransformation fLowerLimTrafo;
 
  188    mutable std::vector<double> fCache;
 
  197 #endif  // ROOT_Minuit2_MnUserTransformation