1#include "include/MdcCosWire.h"
7 double lx = m_wpos[0] - m_wpos[3];
8 double ly = m_wpos[1] - m_wpos[4];
9 double lz = m_wpos[2] - m_wpos[5];
11 double xhit = (z - m_wpos[2]) * lx / lz + m_wpos[0];
12 double yhit = (z - m_wpos[2]) * ly / lz + m_wpos[1];
14 double r = sqrt( (xhit * xhit) + (yhit * yhit) );
15 double phi = asin(yhit / r);
17 if(xhit < 0) phi =
PI - phi;
18 if(phi < 0) phi +=
PI2;
24 fprintf(fout,
"\n%10s %10s %10s %10s %10s %10s %10s\n",
25 "WireLabel",
"Wire",
"Layer",
"Cell",
26 "Radius",
"PhiF",
"Ten");
30 fprintf(fout,
"%10s %10s %10s %10s %10s %10s %10s\n",
31 "Xf",
"Yf",
"Zf",
"Xb",
"Yb",
"Zb",
"Sag");
32 fprintf(fout,
"%10.3f %10.3f %10.3f %10.3f %10.3f %10.3f\n\n",
const char * getWireLabel() const
double getPhi(double z) const
void print(FILE *fout=stdout) const