uLib-0.2
Main Page
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
LinearFit.h
Go to the documentation of this file.
1
/*//////////////////////////////////////////////////////////////////////////////
2
// CMT Cosmic Muon Tomography project //////////////////////////////////////////
4
5
Copyright (c) 2014, Universita' degli Studi di Padova, INFN sez. di Padova
6
All rights reserved
7
8
Authors: Andrea Rigoni Garola < andrea.rigoni@pd.infn.it >
9
10
------------------------------------------------------------------
11
This library is free software; you can redistribute it and/or
12
modify it under the terms of the GNU Lesser General Public
13
License as published by the Free Software Foundation; either
14
version 3.0 of the License, or (at your option) any later version.
15
16
This library is distributed in the hope that it will be useful,
17
but WITHOUT ANY WARRANTY; without even the implied warranty of
18
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19
Lesser General Public License for more details.
20
21
You should have received a copy of the GNU Lesser General Public
22
License along with this library.
23
25
26
27
28
#ifndef U_LINEARFIT_H
29
#define U_LINEARFIT_H
30
31
#include "Math/Dense.h"
32
#include "ChamberDetector.h"
33
34
35
namespace uLib {
36
37
class LinearFitData {
38
public:
39
inline const Vector2f & Position() const { return this->m_Position; }
40
inline const Vector2f & Slope() const { return this->m_Slope; }
41
inline const Vector2f & PositionError() const { return this->m_PositionError; }
42
inline const Vector2f & SlopeError() const { return this->m_SlopeError; }
43
inline int GetHitsNumber() const { return this->m_HitsNumber; }
44
inline ChamberDetector::ID GetIdv() const { return this->m_Idv; }
45
46
protected:
47
Vector2f m_Position;
48
Vector2f m_Slope;
49
Vector2f m_PositionError;
50
Vector2f m_SlopeError;
51
int m_HitsNumber;
52
DetectorChamber::ID m_Idv;
53
};
54
55
56
class LinearFit : public LinearFitData {
57
public:
58
inline Vector2f & Position() { return this->m_Position; }
59
inline Vector2f & Slope() { return this->m_Slope; }
60
inline Vector2f & PositionError() { return this->m_PositionError; }
61
inline Vector2f & SlopeError() { return this->m_SlopeError; }
62
inline void SetHitsNumber(int name) { this->m_HitsNumber = name; }
63
inline void SetIdv(ChamberDetector::ID name) { this->m_Idv = name; }
64
};
65
66
67
68
}
69
70
71
#endif // LINEARFIT_H
Detectors
LinearFit.h
Generated by
1.8.5