162 {+15.15 , +9.15 , +3.15 , -9.15 , -15.15 , +15.15 , +9.15 , +3.15 ,
164 {+21.15 , +15.15 , +9.15 , +3.15 , -9.15 , -15.15 , -21.15 , +21.15 ,
165 +15.15 , +9.15 , +3.15 , -9.15 , -15.15 , -21.15 },
166 {+27.15 , +21.15 , +15.15 , +9.15 , +3.15 , -9.15 , -15.15 , -21.15 ,
167 -27.15 , +27.15 , +21.15 , +15.15 , +9.15 , +3.15 , -9.15 , -15.15 ,
170 {-0.15 , -0.15 , +2.85 , -0.15 , -0.15 , +0.15 , +0.15 , -2.85 ,
172 {-0.15 , -0.15 , -0.15 , +2.85 , -0.15 , -0.15 , -0.15 , +0.15 ,
173 +0.15 , +0.15 , -2.85 , +0.15 , +0.15 , +0.15 },
174 {-0.15 , -0.15 , -0.15 , -0.15 , +2.85 , -0.15 , -0.15 , -0.15 ,
175 -0.15 , +0.15 , +0.15 , +0.15 , +0.15 , -2.85 , +0.15 , +0.15 ,
178 {+1.36 + 4.31 , +0.14 + 4.31 , +1.36 + 4.31 , +0.0 + 4.31 , +1.22 + 4.31 , +0.0 ,
179 +1.22 , 0.0 , +1.36 , +0.14 },
180 {+0.14 + 4.31 , +1.36 + 4.31 , +0.14 + 4.31 , +1.36 + 4.31 , +0.0 + 4.31 ,
181 +1.22 + 4.31 , +0.0 + 4.31 , +1.22 , +0.0 , +1.22 , +0.0 , +1.36 ,
183 {+1.36 + 4.31 , +0.14 + 4.31 , +1.36 + 4.31 , +0.14 + 4.31 , +1.36 + 4.31 ,
184 +0.0 + 4.31 , +1.22 + 4.31 , +0.0 + 4.31 , +1.22 + 4.31 , +0.0 , +1.22 ,
185 +0.0 , +1.22 , +0.0 , +1.36 , +0.14 , +1.36 , +0.14 }};
327 ofstream SiFileOut(xml_file_name.
Data(), ios::out);
329 SiFileOut <<
"<StationSet>\n";
334 cout <<
"istation = " << istation <<
": -----------------------------\n";
336 SiFileOut <<
"<!-- Station " << istation <<
" -->\n";
338 SiFileOut <<
"\t<Station";
342 SiFileOut <<
" rotAngleDeg=\"" <<
"0.0" <<
"\"";
343 SiFileOut <<
" rotCenterX=\"" <<
"0.0" <<
"\"";
344 SiFileOut <<
" rotCenterY=\"" <<
"0.0" <<
"\"";
350 cout <<
" imodule = " << imodule <<
"\n";
352 SiFileOut <<
"\t\t<!-- module " << imodule <<
" -->\n";
354 SiFileOut <<
"\t\t<Module";
357 SiFileOut <<
" xShift=\"" << 0.0 <<
"\"";
358 SiFileOut <<
" yShift=\"" << 0.0 <<
"\"";
359 SiFileOut <<
" zShift=\"" <<
ZModuleShifts[istation][imodule] <<
"\"";
390 Bool_t isDeadZone_UpLayer =
false;
391 Bool_t isDeadZone_LowLayer =
false;
396 Int_t firstStripNumber_UpLayer[2];
397 Int_t firstStripNumber_LowLayer[2];
439 for (
Int_t ilayer = 0; ilayer < 2; ++ilayer) {
440 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
449 isDeadZone_UpLayer =
false;
450 isDeadZone_LowLayer =
true;
511 for (
Int_t ilayer = 0; ilayer < 2; ++ilayer) {
512 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
521 isDeadZone_UpLayer =
false;
522 isDeadZone_LowLayer =
true;
589 for (
Int_t ilayer = 0; ilayer < 2; ++ilayer) {
590 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
599 isDeadZone_UpLayer =
true;
600 isDeadZone_LowLayer =
false;
667 for (
Int_t ilayer = 0; ilayer < 2; ++ilayer) {
668 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
677 isDeadZone_UpLayer =
true;
678 isDeadZone_LowLayer =
false;
700 cout <<
" Orig_UpLayer[0](x:y) = ( " << xOrig_UpLayer[0] <<
" : " << yOrig_UpLayer[0] <<
" )\n";
701 cout <<
" Orig_LowLayer[0](x:y) = ( " << xOrig_LowLayer[0] <<
" : " << yOrig_LowLayer[0] <<
" )\n";
702 cout <<
" Orig_UpLayer[1](x:y) = ( " << xOrig_UpLayer[1] <<
" : " << yOrig_UpLayer[1] <<
" )\n";
703 cout <<
" Orig_LowLayer[1](x:y) = ( " << xOrig_LowLayer[1] <<
" : " << yOrig_LowLayer[1] <<
" )\n";
707 cout <<
" Size_UpLayer[0](dx:dy) = ( " << xSize_UpLayer[0] <<
" : " << ySize_UpLayer[0] <<
" )\n";
708 cout <<
" Size_LowLayer[0](dx:dy) = ( " << xSize_LowLayer[0] <<
" : " << ySize_LowLayer[0] <<
" )\n";
709 cout <<
" Size_UpLayer[1](dx:dy) = ( " << xSize_UpLayer[1] <<
" : " << ySize_UpLayer[1] <<
" )\n";
710 cout <<
" Size_LowLayer[1](dx:dy) = ( " << xSize_LowLayer[1] <<
" : " << ySize_LowLayer[1] <<
" )\n";
714 cout <<
" LBorder_UpLayer[0](x:y) = ( " << xLBorder_UpLayer[0] <<
" : " << yLBorder_UpLayer[0] <<
" )\n";
715 cout <<
" RBorder_UpLayer[0](x:y) = ( " << xRBorder_UpLayer[0] <<
" : " << yRBorder_UpLayer[0] <<
" )\n";
717 cout <<
" LBorder_LowLayer[0](x:y) = ( " << xLBorder_LowLayer[0] <<
" : " << yLBorder_LowLayer[0]
719 cout <<
" RBorder_LowLayer[0](x:y) = ( " << xRBorder_LowLayer[0] <<
" : " << yRBorder_LowLayer[0]
723 cout <<
" LBorder_UpLayer[1](x:y) = ( " << xLBorder_UpLayer[1] <<
" : " << yLBorder_UpLayer[1] <<
" )\n";
724 cout <<
" RBorder_UpLayer[1](x:y) = ( " << xRBorder_UpLayer[1] <<
" : " << yRBorder_UpLayer[1] <<
" )\n";
726 cout <<
" LBorder_LowLayer[1](x:y) = ( " << xLBorder_LowLayer[1] <<
" : " << yLBorder_LowLayer[1]
728 cout <<
" RBorder_LowLayer[1](x:y) = ( " << xRBorder_LowLayer[1] <<
" : " << yRBorder_LowLayer[1]
733 cout <<
" DeadZone[0]:\n";
734 cout <<
" p0(x:y) = ( " << xDeadZone[0][0] <<
" : " << yDeadZone[0][0] <<
" )\n";
735 cout <<
" p1(x:y) = ( " << xDeadZone[0][1] <<
" : " << yDeadZone[0][1] <<
" )\n";
736 cout <<
" p2(x:y) = ( " << xDeadZone[0][2] <<
" : " << yDeadZone[0][2] <<
" )\n";
739 cout <<
" DeadZone[1]:\n";
740 cout <<
" p0(x:y) = ( " << xDeadZone[1][0] <<
" : " << yDeadZone[1][0] <<
" )\n";
741 cout <<
" p1(x:y) = ( " << xDeadZone[1][1] <<
" : " << yDeadZone[1][1] <<
" )\n";
742 cout <<
" p2(x:y) = ( " << xDeadZone[1][2] <<
" : " << yDeadZone[1][2] <<
" )\n";
746 cout <<
" stripDirection[0] = ";
748 cout <<
"LeftToRight\n";
750 cout <<
"RightToLeft\n";
751 cout <<
" stripDirection[1] = ";
753 cout <<
"LeftToRight\n";
755 cout <<
"RightToLeft\n";
759 cout <<
" pitchValue[0] = " << pitchValue[0] <<
"\n";
760 cout <<
" pitchValue[1] = " << pitchValue[1] <<
"\n";
764 cout <<
" stripAngle[0] = " << stripAngle[0] <<
"\n";
765 cout <<
" stripAngle[1] = " << stripAngle[1] <<
"\n";
769 cout <<
" firstStripNumber_UpLayer[0] = " << firstStripNumber_UpLayer[0] <<
"\n";
770 cout <<
" firstStripNumber_LowLayer[0] = " << firstStripNumber_LowLayer[0] <<
"\n";
771 cout <<
" firstStripNumber_UpLayer[1] = " << firstStripNumber_UpLayer[1] <<
"\n";
772 cout <<
" firstStripNumber_LowLayer[1] = " << firstStripNumber_LowLayer[1] <<
"\n";
780 SiFileOut <<
"\t\t\t<Layer";
781 SiFileOut <<
" zoneID=\"" <<
"0" <<
"\"";
782 SiFileOut <<
" type=\"" <<
"lower" <<
"\"";
783 SiFileOut <<
" firstStripNumber=\"" << firstStripNumber_UpLayer[1] <<
"\"";
784 SiFileOut <<
" stripAngle=\"" << stripAngle[1] <<
"\"";
785 SiFileOut <<
" pitch=\"" << pitchValue[1] <<
"\"";
786 SiFileOut <<
" xorig=\"" << xOrig_UpLayer[1] <<
"\"";
787 SiFileOut <<
" yorig=\"" << yOrig_UpLayer[1] <<
"\"";
788 SiFileOut <<
" xsize=\"" << xSize_UpLayer[1] <<
"\"";
789 SiFileOut <<
" ysize=\"" << ySize_UpLayer[1] <<
"\"";
790 SiFileOut <<
" stripDirection=\"";
792 SiFileOut <<
"LeftToRight\"";
794 SiFileOut <<
"RightToLeft\"";
795 SiFileOut <<
" lxborder=\"" << xLBorder_UpLayer[1] <<
"\"";
796 SiFileOut <<
" lyborder=\"" << yLBorder_UpLayer[1] <<
"\"";
797 SiFileOut <<
" rxborder=\"" << xRBorder_UpLayer[1] <<
"\"";
798 SiFileOut <<
" ryborder=\"" << yRBorder_UpLayer[1] <<
"\"";
801 if (isDeadZone_UpLayer ==
true) {
803 SiFileOut <<
"\t\t\t\t<DeadZone>\n";
804 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
805 SiFileOut <<
"\t\t\t\t\t<DeadPoint";
806 SiFileOut <<
" x=\"" << xDeadZone[1][ipoint] <<
"\"";
807 SiFileOut <<
" y=\"" << yDeadZone[1][ipoint] <<
"\"";
808 SiFileOut <<
" />\n";
810 SiFileOut <<
"\t\t\t\t</DeadZone>\n\t\t\t";
812 SiFileOut <<
"</Layer>\n";
816 SiFileOut <<
"\t\t\t<Layer";
817 SiFileOut <<
" zoneID=\"" <<
"0" <<
"\"";
818 SiFileOut <<
" type=\"" <<
"lower" <<
"\"";
819 SiFileOut <<
" firstStripNumber=\"" << firstStripNumber_LowLayer[1] <<
"\"";
820 SiFileOut <<
" stripAngle=\"" << stripAngle[1] <<
"\"";
821 SiFileOut <<
" pitch=\"" << pitchValue[1] <<
"\"";
822 SiFileOut <<
" xorig=\"" << xOrig_LowLayer[1] <<
"\"";
823 SiFileOut <<
" yorig=\"" << yOrig_LowLayer[1] <<
"\"";
824 SiFileOut <<
" xsize=\"" << xSize_LowLayer[1] <<
"\"";
825 SiFileOut <<
" ysize=\"" << ySize_LowLayer[1] <<
"\"";
826 SiFileOut <<
" stripDirection=\"";
828 SiFileOut <<
"LeftToRight\"";
830 SiFileOut <<
"RightToLeft\"";
831 SiFileOut <<
" lxborder=\"" << xLBorder_LowLayer[1] <<
"\"";
832 SiFileOut <<
" lyborder=\"" << yLBorder_LowLayer[1] <<
"\"";
833 SiFileOut <<
" rxborder=\"" << xRBorder_LowLayer[1] <<
"\"";
834 SiFileOut <<
" ryborder=\"" << yRBorder_LowLayer[1] <<
"\"";
837 if (isDeadZone_LowLayer ==
true) {
839 SiFileOut <<
"\t\t\t\t<DeadZone>\n";
840 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
841 SiFileOut <<
"\t\t\t\t\t<DeadPoint";
842 SiFileOut <<
" x=\"" << xDeadZone[1][ipoint] <<
"\"";
843 SiFileOut <<
" y=\"" << yDeadZone[1][ipoint] <<
"\"";
844 SiFileOut <<
" />\n";
846 SiFileOut <<
"\t\t\t\t</DeadZone>\n\t\t\t";
848 SiFileOut <<
"</Layer>\n";
852 SiFileOut <<
"\t\t\t<Layer";
853 SiFileOut <<
" zoneID=\"" <<
"1" <<
"\"";
854 SiFileOut <<
" type=\"" <<
"upper" <<
"\"";
855 SiFileOut <<
" firstStripNumber=\"" << firstStripNumber_UpLayer[0] <<
"\"";
856 SiFileOut <<
" stripAngle=\"" << stripAngle[0] <<
"\"";
857 SiFileOut <<
" pitch=\"" << pitchValue[0] <<
"\"";
858 SiFileOut <<
" xorig=\"" << xOrig_UpLayer[0] <<
"\"";
859 SiFileOut <<
" yorig=\"" << yOrig_UpLayer[0] <<
"\"";
860 SiFileOut <<
" xsize=\"" << xSize_UpLayer[0] <<
"\"";
861 SiFileOut <<
" ysize=\"" << ySize_UpLayer[0] <<
"\"";
862 SiFileOut <<
" stripDirection=\"";
864 SiFileOut <<
"LeftToRight\"";
866 SiFileOut <<
"RightToLeft\"";
867 SiFileOut <<
" lxborder=\"" << xLBorder_UpLayer[0] <<
"\"";
868 SiFileOut <<
" lyborder=\"" << yLBorder_UpLayer[0] <<
"\"";
869 SiFileOut <<
" rxborder=\"" << xRBorder_UpLayer[0] <<
"\"";
870 SiFileOut <<
" ryborder=\"" << yRBorder_UpLayer[0] <<
"\"";
873 if (isDeadZone_UpLayer ==
true) {
875 SiFileOut <<
"\t\t\t\t<DeadZone>\n";
876 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
877 SiFileOut <<
"\t\t\t\t\t<DeadPoint";
878 SiFileOut <<
" x=\"" << xDeadZone[0][ipoint] <<
"\"";
879 SiFileOut <<
" y=\"" << yDeadZone[0][ipoint] <<
"\"";
880 SiFileOut <<
" />\n";
882 SiFileOut <<
"\t\t\t\t</DeadZone>\n\t\t\t";
884 SiFileOut <<
"</Layer>\n";
888 SiFileOut <<
"\t\t\t<Layer";
889 SiFileOut <<
" zoneID=\"" <<
"1" <<
"\"";
890 SiFileOut <<
" type=\"" <<
"upper" <<
"\"";
891 SiFileOut <<
" firstStripNumber=\"" << firstStripNumber_LowLayer[0] <<
"\"";
892 SiFileOut <<
" stripAngle=\"" << stripAngle[0] <<
"\"";
893 SiFileOut <<
" pitch=\"" << pitchValue[0] <<
"\"";
894 SiFileOut <<
" xorig=\"" << xOrig_LowLayer[0] <<
"\"";
895 SiFileOut <<
" yorig=\"" << yOrig_LowLayer[0] <<
"\"";
896 SiFileOut <<
" xsize=\"" << xSize_LowLayer[0] <<
"\"";
897 SiFileOut <<
" ysize=\"" << ySize_LowLayer[0] <<
"\"";
898 SiFileOut <<
" stripDirection=\"";
900 SiFileOut <<
"LeftToRight\"";
902 SiFileOut <<
"RightToLeft\"";
903 SiFileOut <<
" lxborder=\"" << xLBorder_LowLayer[0] <<
"\"";
904 SiFileOut <<
" lyborder=\"" << yLBorder_LowLayer[0] <<
"\"";
905 SiFileOut <<
" rxborder=\"" << xRBorder_LowLayer[0] <<
"\"";
906 SiFileOut <<
" ryborder=\"" << yRBorder_LowLayer[0] <<
"\"";
909 if (isDeadZone_LowLayer ==
true) {
911 SiFileOut <<
"\t\t\t\t<DeadZone>\n";
912 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
913 SiFileOut <<
"\t\t\t\t\t<DeadPoint";
914 SiFileOut <<
" x=\"" << xDeadZone[0][ipoint] <<
"\"";
915 SiFileOut <<
" y=\"" << yDeadZone[0][ipoint] <<
"\"";
916 SiFileOut <<
" />\n";
918 SiFileOut <<
"\t\t\t\t</DeadZone>\n\t\t\t";
920 SiFileOut <<
"</Layer>\n";
923 SiFileOut <<
"\t\t</Module>\n";
942 xOrig[0] = xOrig_LowLayer[0];
943 xOrig[1] = xOrig_LowLayer[1];
944 yOrig[0] = yOrig_LowLayer[0];
945 yOrig[1] = yOrig_LowLayer[1];
946 xSize[0] = xSize_LowLayer[0];
947 xSize[1] = xSize_LowLayer[1];
948 ySize[0] = ySize_LowLayer[0];
949 ySize[1] = ySize_LowLayer[1];
950 xLBorder[0] = xLBorder_LowLayer[0];
951 xLBorder[1] = xLBorder_LowLayer[1];
952 yLBorder[0] = yLBorder_LowLayer[0];
953 yLBorder[1] = yLBorder_LowLayer[1];
954 xRBorder[0] = xRBorder_LowLayer[0];
955 xRBorder[1] = xRBorder_LowLayer[1];
956 yRBorder[0] = yRBorder_LowLayer[0];
957 yRBorder[1] = yRBorder_LowLayer[1];
958 isDeadZone = isDeadZone_LowLayer;
961 xOrig[0] = xOrig_UpLayer[0];
962 xOrig[1] = xOrig_UpLayer[1];
963 yOrig[0] = yOrig_UpLayer[0];
964 yOrig[1] = yOrig_UpLayer[1];
965 xSize[0] = xSize_UpLayer[0];
966 xSize[1] = xSize_UpLayer[1];
967 ySize[0] = ySize_UpLayer[0];
968 ySize[1] = ySize_UpLayer[1];
969 xLBorder[0] = xLBorder_UpLayer[0];
970 xLBorder[1] = xLBorder_UpLayer[1];
971 yLBorder[0] = yLBorder_UpLayer[0];
972 yLBorder[1] = yLBorder_UpLayer[1];
973 xRBorder[0] = xRBorder_UpLayer[0];
974 xRBorder[1] = xRBorder_UpLayer[1];
975 yRBorder[0] = yRBorder_UpLayer[0];
976 yRBorder[1] = yRBorder_UpLayer[1];
977 isDeadZone = isDeadZone_UpLayer;
981 SiFileOut <<
"\t\t\t<Layer";
982 SiFileOut <<
" zoneID=\"" <<
"0" <<
"\"";
983 SiFileOut <<
" type=\"" <<
"lower" <<
"\"";
984 SiFileOut <<
" firstStripNumber=\"" << 0 <<
"\"";
985 SiFileOut <<
" stripAngle=\"" << stripAngle[1] <<
"\"";
986 SiFileOut <<
" pitch=\"" << pitchValue[1] <<
"\"";
987 SiFileOut <<
" xorig=\"" << xOrig[1] <<
"\"";
988 SiFileOut <<
" yorig=\"" << yOrig[1] <<
"\"";
989 SiFileOut <<
" xsize=\"" << xSize[1] <<
"\"";
990 SiFileOut <<
" ysize=\"" << ySize[1] <<
"\"";
991 SiFileOut <<
" stripDirection=\"";
993 SiFileOut <<
"LeftToRight\"";
995 SiFileOut <<
"RightToLeft\"";
996 SiFileOut <<
" lxborder=\"" << xLBorder[1] <<
"\"";
997 SiFileOut <<
" lyborder=\"" << yLBorder[1] <<
"\"";
998 SiFileOut <<
" rxborder=\"" << xRBorder[1] <<
"\"";
999 SiFileOut <<
" ryborder=\"" << yRBorder[1] <<
"\"";
1002 if (isDeadZone ==
true) {
1004 SiFileOut <<
"\t\t\t\t<DeadZone>\n";
1005 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
1006 SiFileOut <<
"\t\t\t\t\t<DeadPoint";
1007 SiFileOut <<
" x=\"" << xDeadZone[1][ipoint] <<
"\"";
1008 SiFileOut <<
" y=\"" << yDeadZone[1][ipoint] <<
"\"";
1009 SiFileOut <<
" />\n";
1011 SiFileOut <<
"\t\t\t\t</DeadZone>\n\t\t\t";
1013 SiFileOut <<
"</Layer>\n";
1017 SiFileOut <<
"\t\t\t<Layer";
1018 SiFileOut <<
" zoneID=\"" <<
"1" <<
"\"";
1019 SiFileOut <<
" type=\"" <<
"upper" <<
"\"";
1020 SiFileOut <<
" firstStripNumber=\"" << 0 <<
"\"";
1021 SiFileOut <<
" stripAngle=\"" << stripAngle[0] <<
"\"";
1022 SiFileOut <<
" pitch=\"" << pitchValue[0] <<
"\"";
1023 SiFileOut <<
" xorig=\"" << xOrig[0] <<
"\"";
1024 SiFileOut <<
" yorig=\"" << yOrig[0] <<
"\"";
1025 SiFileOut <<
" xsize=\"" << xSize[0] <<
"\"";
1026 SiFileOut <<
" ysize=\"" << ySize[0] <<
"\"";
1027 SiFileOut <<
" stripDirection=\"";
1029 SiFileOut <<
"LeftToRight\"";
1031 SiFileOut <<
"RightToLeft\"";
1032 SiFileOut <<
" lxborder=\"" << xLBorder[0] <<
"\"";
1033 SiFileOut <<
" lyborder=\"" << yLBorder[0] <<
"\"";
1034 SiFileOut <<
" rxborder=\"" << xRBorder[0] <<
"\"";
1035 SiFileOut <<
" ryborder=\"" << yRBorder[0] <<
"\"";
1038 if (isDeadZone ==
true) {
1040 SiFileOut <<
"\t\t\t\t<DeadZone>\n";
1041 for (
Int_t ipoint = 0; ipoint < 3; ++ipoint) {
1042 SiFileOut <<
"\t\t\t\t\t<DeadPoint";
1043 SiFileOut <<
" x=\"" << xDeadZone[0][ipoint] <<
"\"";
1044 SiFileOut <<
" y=\"" << yDeadZone[0][ipoint] <<
"\"";
1045 SiFileOut <<
" />\n";
1047 SiFileOut <<
"\t\t\t\t</DeadZone>\n\t\t\t";
1049 SiFileOut <<
"</Layer>\n";
1052 SiFileOut <<
"\t\t</Module>\n";
1057 SiFileOut <<
"\t</Station>\n";
1060 cout <<
"------------------------------------------------------------\n";
1063 SiFileOut <<
"</StationSet>\n";