00001 #include "Bin.h"
00002 #include <iostream>
00003 using namespace Bin;
00004
00005 void Bin::initPtAry(TArrayD* ary, int type)
00006 {
00007 double ptAry0[]=
00008 {
00009 1.6,1.7,1.8,1.9,2.0,2.2,2.45,2.7,3.0,3.35,3.8,4.4,5.1,6.0,7.0,8.0
00010 };
00011 int n0 = (int)sizeof(ptAry0)/sizeof(double);
00012
00013 double ptAry1[]=
00014 {
00015 1.6,1.7,1.8,1.9,2.0,2.2,2.4,2.6,2.8,3.0,3.25,3.5,3.75,4.0,4.3,4.6,5.1,6.0,7.0,8.0
00016 };
00017 int n1 = (int)sizeof(ptAry1)/sizeof(double);
00018 switch(type){
00019 case 0: ary->Set(n0,ptAry0); break;
00020 case 1: ary->Set(n1,ptAry1); break;
00021 default:
00022 cout << "ERROR. type " << type << "out of range" << endl; exit(1);
00023 }
00024
00025 }