From 28507dc6f6880aea6200e9684b3959b2628ff40a Mon Sep 17 00:00:00 2001 From: Sven Dildick Date: Tue, 10 Dec 2019 17:45:12 +0100 Subject: [PATCH 1/2] Add Run-3 CLCT patterns --- .../interface/CSCPatternBank.h | 8 ++++ .../src/CSCPatternBank.cc | 45 +++++++++++++++++++ 2 files changed, 53 insertions(+) diff --git a/L1Trigger/CSCTriggerPrimitives/interface/CSCPatternBank.h b/L1Trigger/CSCTriggerPrimitives/interface/CSCPatternBank.h index b096cd6abfe67..ff4e52c658eb6 100644 --- a/L1Trigger/CSCTriggerPrimitives/interface/CSCPatternBank.h +++ b/L1Trigger/CSCTriggerPrimitives/interface/CSCPatternBank.h @@ -2,6 +2,7 @@ #define L1Trigger_CSCTriggerPrimitives_CSCPatternBank_h #include "L1Trigger/CSCCommonTrigger/interface/CSCConstants.h" +#include // // Class with only static members that contains the ALCT and CLCT trigger patterns @@ -9,6 +10,10 @@ class CSCPatternBank { public: + typedef std::vector > > CLCTPatterns; + + typedef int ALCTPatterns[CSCConstants::NUM_ALCT_PATTERNS][CSCConstants::MAX_WIRES_IN_PATTERN]; + /** Pre-defined ALCT patterns. */ // This is the pattern envelope, which is used to define the collision @@ -35,6 +40,9 @@ class CSCPatternBank { // Pattern[i][CSCConstants::MAX_HALFSTRIPS_IN_PATTERN+1] contains pattern maximum width static const int clct_pattern[CSCConstants::NUM_CLCT_PATTERNS][CSCConstants::MAX_HALFSTRIPS_IN_PATTERN + 2]; + // New patterns for Run-3 + static const CLCTPatterns clct_pattern_run3_; + // half strip offsets per layer for each half strip in the pattern envelope static const int clct_pattern_offset[CSCConstants::MAX_HALFSTRIPS_IN_PATTERN]; }; diff --git a/L1Trigger/CSCTriggerPrimitives/src/CSCPatternBank.cc b/L1Trigger/CSCTriggerPrimitives/src/CSCPatternBank.cc index 7153164e6d465..87fe8a4680b3d 100644 --- a/L1Trigger/CSCTriggerPrimitives/src/CSCPatternBank.cc +++ b/L1Trigger/CSCTriggerPrimitives/src/CSCPatternBank.cc @@ -91,3 +91,48 @@ const int CSCPatternBank::clct_pattern[CSCConstants::NUM_CLCT_PATTERNS][CSCConst 999, 999, 5, 5, 5, 999, 999, 999, 999, 0, 3} // pid's=B-F are not yet defined }; + +const CSCPatternBank::CLCTPatterns CSCPatternBank::clct_pattern_run3_ = { + // pid 0 + { + {0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1}, + {0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0}, + {0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0}, + {0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0}, + {0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0}, + {1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11}, + }, + // pid 1 + { + {1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0}, + {0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0}, + {0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0}, + {0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0}, + {0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0}, + {0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 11}, + }, + // pid 2 + { + {0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0}, + {0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0}, + {0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0}, + {0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0}, + {0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0}, + {0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 7}, + }, + // pid 3 + { + {0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0}, + {0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0}, + {0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0}, + {0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0}, + {0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0}, + {0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 7}, + }, + // pid 4 + {{0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0}, + {0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0}, + {0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0}, + {0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0}, + {0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0}, + {0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 3}}}; From be643b3ca7c525ce907ab5dc37ade0e07ddcfafe Mon Sep 17 00:00:00 2001 From: Sven Dildick Date: Tue, 10 Dec 2019 17:47:08 +0100 Subject: [PATCH 2/2] Code format --- .../src/CSCPatternBank.cc | 86 +++++++++---------- 1 file changed, 43 insertions(+), 43 deletions(-) diff --git a/L1Trigger/CSCTriggerPrimitives/src/CSCPatternBank.cc b/L1Trigger/CSCTriggerPrimitives/src/CSCPatternBank.cc index 87fe8a4680b3d..4b7a497388aef 100644 --- a/L1Trigger/CSCTriggerPrimitives/src/CSCPatternBank.cc +++ b/L1Trigger/CSCTriggerPrimitives/src/CSCPatternBank.cc @@ -93,46 +93,46 @@ const int CSCPatternBank::clct_pattern[CSCConstants::NUM_CLCT_PATTERNS][CSCConst }; const CSCPatternBank::CLCTPatterns CSCPatternBank::clct_pattern_run3_ = { - // pid 0 - { - {0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1}, - {0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0}, - {0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0}, - {0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0}, - {0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0}, - {1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11}, - }, - // pid 1 - { - {1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0}, - {0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0}, - {0, 0, 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