include/Photos/photosC.h
1#ifndef _photosC_h_included_
2#define _photosC_h_included_
3
4namespace Photospp
5{
6
7const static int NMXHEP = 10000;
8const static double PI = 3.14159265358979324;
9const static double TWOPI = 6.28318530717958648;
10
11/** Definition of the PHOEVT common block */
12extern struct HEPEVT
13{
14 int nevhep;
15 int nhep;
16 int isthep[NMXHEP];
17 int idhep[NMXHEP];
18 int jmohep[NMXHEP][2];
19 int jdahep[NMXHEP][2];
20 double phep[NMXHEP][5];
21 double vhep[NMXHEP][4];
22 int qedrad[NMXHEP]; // to be bool once compatibility with F77 removed
23 const static int nmxhep=NMXHEP;
24 // NEVPHO,NPHO,ISTPHO(NMXPHO),IDPHO(NMXPHO),
25 // JMOPHO(2,NMXPHO),JDAPHO(2,NMXPHO),PPHO(5,NMXPHO),VPHO(4,NMXPHO)
26 // int qedrad[NMXHEP] was an add up
27 // for HEPEVT in F77 times. Separate common PH_PHOQED
28 // also phoif_.chkif[NMXPHO] was add up for PHOEVT
29 // now it is pho.qedrad
30} hep,pho;
31//ph_hepevt_,phoevt_;
32
33
34
35extern struct PHOCOP
36{
37 double alpha;
38 double xphcut;
39} phocop;
40
41extern struct PHNUM
42{
43 double iev;
44} phnum;
45
46extern struct PHOKEY
47{
48 double fsec;
49 double fint;
50 double expeps;
51 int interf;
52 int isec;
53 int itre;
54 int iexp;
55 int iftop;
56 int ifw;
57} phokey;
58
59extern struct PHOSTA
60{
61 int status[10];
62 int ifstop;
63} phosta;
64
65extern struct PHOLUN
66{
67 int phlun;
68} pholun;
69
70extern struct PHOPHS
71{
72 double xphmax;
73 double xphoto;
74 double costhg;
75 double sinthg;
76} phophs;
77
78extern struct TOFROM
79{
80 double QQ[4];
81 double XM;
82 double th1;
83 double fi1;
84} tofrom;
85
86extern struct PHOPRO
87{
88 double probh;
89 double corwt;
90 double xf;
91 int irep;
92} phopro;
93
94extern struct PHOREST
95{
96 double fi3;
97 double fi1;
98 double th1;
99 int irep; // provably line to be removed
100} phorest;
101
102extern struct PHWT
103{
104 double beta;
105 double wt1;
106 double wt2;
107 double wt3;
108} phwt;
109
110extern struct PHOCORWT
111{
112 double phocorwt3;
113 double phocorwt2;
114 double phocorwt1;
115} phocorwt;
116
117extern struct PHOMOM
118{
119 double mchsqr;
120 double mnesqr;
121 double pneutr[5];
122} phomom;
123
124extern struct PHOCMS
125{
126 double bet[3];
127 double gam;
128} phocms;
129
130extern struct PHOEXP
131{
132 const static int NX = 10;
133 double pro[NX];
134 int nchan;
135 int expini; // bool
136} phoexp;
137
138//debug mode on if ipoin < 1 and ipoinm > 1
139extern struct PHLUPY
140{
141 int ipoin;
142 int ipoinm;
143} phlupy;
144
145/** Initialize kinematic corrections */
146void PHCORK(int modcor);
147
148/** Single branch processing */
149void PHOTOS_MAKE_C(int id);
150
151/* Central management routine. Defines what action
152 will be performed at point ID. */
153void PHTYPE(int ID);
154
155} // namespace Photospp
156#endif
157