BOSS
8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
Emc/EmcRawEvent/test/main.cxx
Go to the documentation of this file.
1
#include "EmcRawEvent/EmcDigi.h"
2
#include "Identifier/EmcID.h"
3
#include "Identifier/Identifier.h"
4
#include <iostream>
5
using namespace
std
;
6
7
int
main
() {
8
Identifier
id;
9
id
=
EmcID::crystal_id
( 1, 3, 5 );
10
EmcDigi
digi1(
id
, 25, 1000, 1 );
11
EmcDigi
digi2(
id
, 25, 1000, 2 );
12
cout <<
"digi1: "
<< digi1 << endl;
13
cout <<
"digi2: "
<< digi2 << endl;
14
digi1 += digi2;
15
cout <<
"digi sum: "
<< digi1 << endl;
16
17
id
=
EmcID::crystal_id
( 0, 2, 4 );
18
EmcDigi
digi3(
id
, 25, 1000 );
19
EmcDigi
digi4(
id
, 35, 2000 );
20
cout <<
"digi3: "
<< digi3 << endl;
21
cout <<
"digi4: "
<< digi4 << endl;
22
digi3 += digi4;
23
cout <<
"digi sum: "
<< digi3 << endl;
24
25
id
=
EmcID::crystal_id
( 2, 2, 4 );
26
EmcDigi
digi5(
id
, 25, 1000 );
27
id
=
EmcID::crystal_id
( 2, 3, 4 );
28
EmcDigi
digi6(
id
, 35, 2000 );
29
cout <<
"digi5: "
<< digi5 << endl;
30
cout <<
"digi6: "
<< digi6 << endl;
31
digi5 += digi6;
32
cout <<
"digi sum: "
<< digi5 << endl;
33
}
main
int main()
Definition
Emc/EmcRawEvent/test/main.cxx:7
EmcDigi
Definition
Emc/EmcRawEvent/include/EmcRawEvent/EmcDigi.h:15
EmcID::crystal_id
static Identifier crystal_id(const unsigned int barrel_ec, const unsigned int theta_module, const unsigned int phi_module)
For a single crystal.
Definition
EmcID.cxx:63
Identifier
Definition
DetectorDescription/Identifier/include/Identifier/Identifier.h:20
std
Definition
x86_64-el9-gcc13-dbg/Event/RootEventData/RootEventDataDict.cxx:101
8.0.0
BOSS_Source
Emc
EmcRawEvent
test
main.cxx
Generated by
1.16.1