CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HcalCholeskyMatrix.cc
Go to the documentation of this file.
2 #include <cmath>
3 
5 {
6  for(int cap = 0; cap != 4; cap++)
7  for(int i = 0; i != 55; i++)
8  cmatrix[cap][i] = 0;
9 }
10 
11 float
12 HcalCholeskyMatrix::getValue(int capid, int i,int j) const
13 {
14  if(i < j) return 0;
15  int ii = i + 1;
16  int jj = j + 1;
17  float blah = (float)(cmatrix[capid][(ii*(ii-1)/2+jj)-1]);
18  return blah/1000;
19 }
20 
21 void
22 HcalCholeskyMatrix::setValue(int capid, int i, int j, float val)
23 {
24  if(i < j) return;
25  int ii = i + 1;
26  int jj = j + 1;
27  cmatrix[capid][(int)(ii*(ii-1)/2+jj)-1] = (signed short int)(floor)(val*10000);
28 }
29 
float getValue(int capid, int i, int j) const
int i
Definition: DBlmapReader.cc:9
static const double cap
Definition: HcalTimeSlew.cc:7
void setValue(int capid, int i, int j, float val)
int ii
Definition: cuy.py:588
signed short int cmatrix[4][55]
int j
Definition: DBlmapReader.cc:9
HcalCholeskyMatrix(int fId=0)