DDASToys for NSCLDAQ  6.2-000
lmfit_analytic.h
Go to the documentation of this file.
1 /*
2  This software is Copyright by the Board of Trustees of Michigan
3  State University (c) Copyright 2017.
4 
5  You may use this software under the terms of the GNU public license
6  (GPL). The terms of this license are described at:
7 
8  http://www.gnu.org/licenses/gpl.txt
9 
10  Authors:
11  Ron Fox
12  Jeromy Tompkins
13  Aaron Chester
14  FRIB
15  Michigan State University
16  East Lansing, MI 48824-1321
17 */
18 
25 #ifndef LMFIT_ANALYTIC_H
26 #define LMFIT_ANALYTIC_H
27 
28 #include <cstdint>
29 #include <vector>
30 
31 #include "fit_extensions.h"
32 
34 namespace ddastoys {
36  namespace analyticfit {
37 
50  const std::vector<std::pair<uint16_t, uint16_t>>* s_pPoints;
51  };
52 
68  void lmfit1(
69  fit1Info* pResult, std::vector<uint16_t>& trace,
70  const std::pair<unsigned, unsigned>& limits,
71  uint16_t saturation = 0xffff
72  );
73 
85  void lmfit2(
86  fit2Info* pResult, std::vector<uint16_t>& trace,
87  const std::pair<unsigned, unsigned>& limits,
88  fit1Info* pSinglePulseFit = nullptr,
89  uint16_t saturation = 0xffff
90  );
91 
105  void lmfit2fixedT(
106  fit2Info* pResult, std::vector<uint16_t>& trace,
107  const std::pair<unsigned, unsigned>& limits,
108  fit1Info* pSinglePulseFit = nullptr,
109  uint16_t saturation = 0xffff
110  );
111 
114  }
115 };
116 
117 #endif
Define structs used by fitting functions and to extend DDAS hits.
void lmfit1(fit1Info *pResult, std::vector< uint16_t > &trace, const std::pair< unsigned, unsigned > &limits, uint16_t saturation=0xffff)
Driver for the GSL LM fitter for single pulses.
Definition: lmfit_analytic.cpp:406
void lmfit2fixedT(fit2Info *pResult, std::vector< uint16_t > &trace, const std::pair< unsigned, unsigned > &limits, fit1Info *pSinglePulseFit=nullptr, uint16_t saturation=0xffff)
Driver for the GSL LM fitter for double pulses, constraining the two timing parameters (rise time and...
Definition: lmfit_analytic.cpp:942
void lmfit2(fit2Info *pResult, std::vector< uint16_t > &trace, const std::pair< unsigned, unsigned > &limits, fit1Info *pSinglePulseFit=nullptr, uint16_t saturation=0xffff)
Driver for the GSL LM fitter for double pulses.
Definition: lmfit_analytic.cpp:600
Data passed around the fitting subsystem to Jacobian and function evaluators.
Definition: lmfit_analytic.h:48
const std::vector< std::pair< uint16_t, uint16_t > > * s_pPoints
Definition: lmfit_analytic.h:50
Full fitting information for the single pulse.
Definition: fit_extensions.h:48
Full fitting information for the double pulse.
Definition: fit_extensions.h:60