EDM4eic
EIC data model
Loading...
Searching...
No Matches
Cov2f.h
Go to the documentation of this file.
1
// AUTOMATICALLY GENERATED FILE - DO NOT EDIT
2
3
#ifndef EDM4EIC_Cov2f_H
4
#define EDM4EIC_Cov2f_H
5
6
#include <ostream>
7
8
#if defined(PODIO_JSON_OUTPUT) && !defined(__CLING__)
9
#include "nlohmann/json_fwd.hpp"
10
#endif
11
12
namespace
edm4eic
{
13
14
15
/** @class Cov2f
16
*
17
* @author:
18
*/
19
class
Cov2f
{
20
public
:
21
float
xx
{};
22
float
yy
{};
23
float
xy
{};
24
25
Cov2f
() :
xx
{0},
yy
{0},
xy
{0} {}
26
Cov2f
(
double
vx,
double
vy,
double
vxy = 0)
27
:
xx
{static_cast<float>(vx)},
yy
{static_cast<float>(vy)},
xy
{static_cast<float>(vxy)} {}
28
float
operator()
(
unsigned
i,
unsigned
j)
const
{
29
// diagonal
30
if
(i == j) {
31
return
*(&
xx
+ i);
32
}
33
// off-diagonal
34
// we have as options (0, 1), and (1, 0)
35
// note that, starting from xy, we find the correct element at (i+j+1)/2)
36
return
*(&
xy
+ (i + j + 1) / 2);
37
}
38
39
40
};
41
42
std::ostream&
operator<<
(std::ostream& o,
const
Cov2f& value);
43
44
#if defined(PODIO_JSON_OUTPUT) && !defined(__CLING__)
45
void
to_json(nlohmann::json& j,
const
Cov2f& value);
46
#endif
47
48
namespace
v850 {
49
using
Cov2f
=
edm4eic::Cov2f
;
50
}
// namespace v850
51
52
53
}
// namespace edm4eic
54
55
56
#endif
edm4eic::Cov2f
Definition
Cov2f.h:19
edm4eic::Cov2f::operator()
float operator()(unsigned i, unsigned j) const
Definition
Cov2f.h:28
edm4eic::Cov2f::Cov2f
Cov2f()
Definition
Cov2f.h:25
edm4eic::Cov2f::yy
float yy
Definition
Cov2f.h:22
edm4eic::Cov2f::xx
float xx
Definition
Cov2f.h:21
edm4eic::Cov2f::Cov2f
Cov2f(double vx, double vy, double vxy=0)
Definition
Cov2f.h:26
edm4eic::Cov2f::xy
float xy
Definition
Cov2f.h:23
edm4eic::v850::Cov2f
edm4eic::Cov2f Cov2f
Definition
Cov2f.h:49
edm4eic
Definition
CalorimeterHit.cc:17
edm4eic::operator<<
std::ostream & operator<<(std::ostream &o, const CalorimeterHit &value)
Definition
CalorimeterHit.cc:99
build
edm4eic
Cov2f.h
Generated by
1.13.2