Performance of the LHCb muon system

The performance of the LHCb Muon system and its stability across the full 2010 data taking with LHC running at ps = 7 TeV energy is studied. The optimization of the detector setting and the time calibration performed with the first collisions delivered by LHC is described. Particle rates, measured for the wide range of luminosities and beam operation conditions experienced during the run, are compared with the values expected from simulation. The space and time alignment of the detectors, chamber efficiency, time resolution and cluster size are evaluated. The detector performance is found to be as expected from specifications or better. Notably the overall efficiency is well above the design requirements


Introduction
LHCb is an experiment dedicated to heavy flavour physics at the LHC pp collider. Its primary goal is to look for indirect evidence of new physics in CP violation and rare decays of beauty and charm hadrons.
The LHCb apparatus [1] is a single-arm forward spectrometer, consisting of a series of subdetectors aligned along the beam axis. A silicon-strip Vertex Locator (VELO) centered on the interaction point allows for precise vertex reconstruction. A dipole magnet with an integrated field of 4 Tm provides the bending for momentum measurement. Four multi-layer stations, one placed upstream and three downstream the magnet, ensure the tracking. Silicon strips are used in the upstream station (TT) and in the downstream inner tracker (IT) while straw tubes are used in the -1 -downstream outer tracker (OT). Particle identification is provided by two ring imaging Cherenkov (RICH) detectors, by an electromagnetic and hadron calorimeter system (ECAL and HCAL) and by the Muon Detector.
The calorimeters and the muon detector with their readout electronics are designed to send information to the first level hardware trigger (L0) unambiguously identifying collision events of an LHC bunch crossing in a time window of 25 ns. A second level software trigger (HLT) performs an almost complete event reconstruction using the information of the tracking detectors and selects specific channels of interest for the LHCb physics program [2].
The muon system consists of 5 detector stations with a total area of 435 m 2 , 1380 chambers of 20 different types for a total of 122k channels [1]. In 2009 a first setting of the detector was performed using cosmic rays [3]. In 2010 the large data sample made available by the first LHC pp collisions at √ s = 7 TeV, allowed for a rapid improvement of the detector working conditions and events were collected for a total of ∼ 37 pb −1 .
In this paper we describe the actions taken to optimize the detector performance, in particular the time calibration. We then report a detailed study of the detector behaviour through the wide range of beam operation conditions spanned during the 2010 data taking. Due to the continuous progress of the LHC, the luminosity spanned from 10 27 to 1.5 × 10 32 s −1 cm −2 with an average number µ of interactions per bunch crossing increasing up to µ∼ 2, while the nominal design values of LHCb were a luminosity of 2 × 10 32 s −1 cm −2 and a µ∼ 0.4. Particle rates were measured across the five orders of magnitude of the experienced luminosities. The detector performance in terms of space and time alignment of the detectors, chamber efficiency, time resolution, noise level and cluster size was evaluated and compared with expectations. The system behaviour resulted to be in agreement with the design specifications or better as in the case of the muon detection efficiency in the required 25 ns time window.
Since the end of the 2010 run period considered here, LHCb has taken almost two orders of magnitude more data, with even higher instantaneous luminosities. The detector performance has remained very similar.

The LHCb muon system
The muon detector system is designed to send binary information to the data acquisition (DAQ) and to the hardware processors of the muon trigger (L0MU) which, together with the calorimeter trigger, constitutes the bulk of the first level trigger.
The detector is composed of five stations (M1-M5) of rectangular shape, placed along the beam axis as shown in figure 1. Each station is equipped with 276 multi-wire proportional chambers (MWPCs) with the exception of the inner part of the first station, subject to the highest radiation, which is equipped with 12 GEM detectors [4]. Each station consists of two mechanically independent halves, called A and C sides, that can be horizontally moved to access the beam pipe and the detector chambers for installation and maintenance. Stations M2 to M5 are placed downstream the calorimeters and are interleaved with 80 cm thick iron absorbers. Their information is used to identify and trace penetrating muons both in the online and offline analysis. Station M1 is instead located in front of the calorimeters and it is only used in the first level trigger. The L0MU trigger processors [5] perform a stand-alone muon track reconstruction which requires to find hits in all the 5 stations and calculate the transverse momentum p T of the tracks. Muon candidates are accepted if their p T is above a given threshold. 1 The hit alignment along a track is first verified in the four stations M2-M5 searching for hits inside suitable fields of interest (FOI) projective to the interaction point. If this alignment is found, the hits of M2 and M3 stations are used to predict the track hit position in M1. If the M1 hit nearest to the prediction is found inside a suitable FOI, this hit and the one in M2 are used to define the track after the magnet deflection. The direction of such a track, its impact point at the magnet centre and the average pp interaction point, provide a rough fast measurement of the magnet deflection and the p T used by L0MU. The information of M1 station, placed in front of the calorimeter material, improves the p T resolution from ∼ 35 % to ∼ 25 %, with respect to what could be obtained using only the 4 downstream stations. The M1 information is however not helpful in the high level trigger or offline where a direct matching of the tracks reconstructed making use of the full spectrometer (T-tracks) with the muon track segment detected in M2-M5 can be performed. The momentum of the matched T-track, having a typical resolution ranging from 0.35 to 0.55 %, is assigned to the muon.
The geometry of the five stations is projective. The transverse dimensions of the stations scale with their distance from the interaction point. The chambers are positioned to form, across the stations, adjacent projective towers pointing to the beam crossing position.
The chambers are partitioned into physical channels whose size is constrained by constructional reasons, or by requirements on their electrical capacitance and rate capability that influence the noise level and dead time of the front end (FE) electronics. Appropriate combinations of phys-1 The L0MU trigger is the logical "or" of a single-muon trigger with a p T threshold of 1.5 Gev/c and a di-muon trigger where a minimal value of 1.3 Gev/c is required for the geometrical mean of the first largest and the second largest muon p T found in the event. ical channels are performed to build up rectangular logical pads having the x and y sizes required to obtain the desired performance of muon trigger and offline muon identification. Each station is divided into four regions with increasing distance from the beam axis as shown in figure 1(b). The linear dimensions of the regions R1, R2, R3, R4, and the size of their logical pads, scale in the ratio 1:2:4:8 (see figure 2). Since the dipole magnet provides bending in the horizontal plane, the logical pad segmentation of muon chambers is finer in the horizontal direction x than in the vertical direction y, to allow a good estimate of the momentum. Stations M1, M2 and M3, used by the trigger to determine the track direction and the p T of the candidate muon, have a higher x granularity than stations M4 and M5, whose main purpose is the identification of penetrating particles. In the inner region of the first station M1, the logical pad size is 1 cm in x and 2.5 cm in y. In the other stations the vertical size y just scales projectively with their distance from the interaction point; the x granularity instead is two times finer in stations M2, M3 and two times larger in M4, M5. The total number of logical pads is 55296.
Since the L0MU trigger requires a five-fold coincidence among all the stations, the efficiency of each station must be ≥ 99%, within a time window smaller than 25 ns, to obtain a trigger efficiency of at least 95%. To comply with this stringent requirement, excellent time resolution and redundancy of the detector are needed. The desired performance is obtained with an optimized charge-collection geometry and using a fast gas mixture. 2 Moreover the chambers are multi-gap detectors. In stations M2 to M5 the MWPCs consist of two coupled bi-gap detectors with two independent readouts. In station M1, R2 to R4 the MWPC's have only two gas gaps with independent readout to minimize the material in front of the electromagnetic calorimeter. In region M1R1 two superimposed triple-GEM chambers are used. In all cases, in standard running conditions, the two independent readout layers are connected to a logical "or" in the FE.
Since constructional constraints, as well as requirements on spatial resolution and rate capability, strongly vary in different stations and regions of the detector, different readout techniques were employed. In the high granularity regions M2/3 R1/2 a double readout was adopted for the chambers: the physical channels are narrow vertical anode strips defining the x resolution and larger cathode pads defining the y resolution. Both signals are readout via FE channels and directly sent to the trigger and DAQ through optical links. Logical pads are then obtained as a logical "and" between anode and cathode pads. In all the other stations and regions a single readout was adopted: the chambers are segmented into anode or into cathode pads generally smaller than the required logical pad. These pads are subsequently combined to build larger logical channels that are sent to the trigger and DAQ. In the large low resolution external regions R4, anode pads are formed by soldering an appropriate number of adjacent wires. In the other regions, both in MWPCs and in GEM chambers, cathode pads are obtained with a segmented printed circuit board. A total of 122112 physical channels enter the front end electronics.
The FE boards house two custom made 8-channels ASICs called CARIOCA [6] that can process both the negative and positive polarity signals from wires and cathode pads. Each channel consists of a fast low-impedance charge-sensitive preamplifier, a main amplifier-shaper with baseline restorer and single-threshold discriminator. The response has a peaking time of 10 ns and a width not exceeding 60 ns to minimize the dead time. The CARIOCA output channels are routed to flexible logical units performing the logical "or" of a variable number of channels. Up to four adjacent physical pads are connected to build a logical pad. In the M1 station, where the channel occupancy is high, the signals from the logical pads are directly sent to the trigger and DAQ. In most of the other low occupancy regions, M2/3 R3/4 and M4/5 R2/3/4, several contiguous logical pads are further connected to build larger logical channels in the form of vertical and horizontal strips, with the aim of reducing the number of optical links to the trigger and DAQ. The logical "or" is fully performed by logic units (DIALOG [7]) sitting on the FE boards only in part of the detector, while is completed on special intermediate boards in regions where the logical channel spans more than one FE board.
A total of 25920 logical channels are built and finally routed to the Off Detector Electronics (ODE) [8], where signals are tagged with the identification number of the bunch crossing (BXID) and sent to the trigger processors via optical links without zero suppression. In the ODE boards the fine time information inside the 25 ns gate, measured by a 4-bit TDC ASIC [9], is added to the data to be sent to the DAQ. The trasmission from the ODE to the acquisition system goes through the TELL1 boards [10] where the data are zero suppressed and suitably packed.
A distributed system, based on a CAN-bus network and 600 microcontrollers accessing single physical channels, performs the setting of the operating conditions and the monitoring of the detector [11] 3 Detector setting The operating conditions of the chambers were optimized through a procedure described elsewhere [12,13] which aims at reaching a low and stable noise rate while minimizing ageing effects -5 -and cluster size. These conditions were satisfied by setting the thresholds to 6 noise r.m.s. and by choosing the minimal high voltage value allowing to obtain the required 99% efficiency.
Although all the MWPCs have the same gas gap of 5 mm, different HV (from 2.53 to 2.65 kV) were required in different regions, depending on the pad size and the readout technique. The chamber setting was kept constant during the whole 2010 run, except for region M5R2 were voltage was reduced by 90 V when a large increase in luminosity produced a jump of the HV trip rate. Thresholds were lowered correspondingly to maintain high efficiency at the price of a slight increase of the noise level.
The triple GEM detectors of M1R1 were operated with voltages of 435/425/415 V for the first part of the run. Voltages were later reduced twice by 5 V per gap for safer operations following the increasing luminosity.

Detector operation performance in 2010
During 2010 the detector was operated to acquire some special calibration runs and many physics runs with pp collisions events at √ s = 7 TeV. Due to the continuous progress of the LHC, the 2010 data span a wide range of luminosity values, from 10 27 to 1.5 × 10 32 s −1 cm −2 . The machine operations were accordingly evolving with time, from the single colliding bunch per orbit of the first runs, to the 150 ns spaced bunch trains of the highest intensity runs with 344 colliding bunches per orbit, equivalent to a 3.9 MHz collision rate, and the first tests with 50 ns spaced bunches. Overall an integrated luminosity of ∼ 37 pb −1 was collected.
As a first illustration of the muon detector operation performance, we show in figure 3 a typical hit map of the five stations during a physics run. The few holes present on the maps correspond to dead channels. Most of them were due to hardware problems in the readout chain known since the beginning of the data taking. 3 They affected only 129 of the 55296 logical pads (0.2%). The detector failures occurred during the run, were mostly due to HV trips of single detector gaps and were recovered after some conditioning procedure.
The overall effect of dead channels on the muon tracking efficiency over the full 2010 run has been estimated [14] by counting the fraction of muon tracks with momentum larger than 6 GeV/c crossing one of the dead channels in Monte Carlo minimum bias events. It resulted to be below 1%. For the stations M2-M5, due to the large redundancy given by the four independent gaps per chamber, the effect of gap failures on the overall system efficiency was negligible (< 0.1%). In the case of M1, gap failures are more dangerous since there are only 2 gaps per chamber. However, as it has been explained in section 2, this station is only used by the L0MU trigger and not by the high level trigger and offline reconstruction. If a detector of M1 is faulty, the L0MU trigger can be set to ignore the information of the trigger sector 4 containing the M1 dead channels and calculate p T with M2 and M3 hits. This results in a poorer resolution of the p T measurement and consequently a slight degradation of the trigger performance in the small affected region. This procedure was used only in one case for a chamber in M1R1, when both its triple GEM detectors became very inefficient. This resulted in a negligible trigger efficiency loss at the Pt threshold, while this dead zone would have otherwise generated an overall inefficiency of the order of 3% in the stand alone trigger tracking.
The noise in the detector should be below 1 kHz per physical channel in order to have a negligible rate (below 1 Hz) of fake muon triggers [15]. Even lower rates are desirable to suppress the noise contribution to muon misidentification in the offline reconstruction. The level of detector noise was checked regularly with dedicated runs of random triggers in absence of beam and the noise rate per physical channel was computed for each detector region from the multiplicity of firing logical channels or logical pads. The fraction of channels having a noise rate larger than 10 kHz is typically lower than 0.1%. Such values are well below the noise level causing a measurable rate of accidental triggers.

Data samples and track reconstruction
In order to test the muon detector response in the wide range of conditions experienced during 2010, an appropriate set of sample runs over the full period was chosen and analysed.
For time calibration and time performance study, some special runs were taken: • events for time alignment (TAE) were recorded in a larger time gate of 125 ns, instead of the standard 25 ns, around the triggered bunch crossing.
For the measurement of particle rates, cluster size and time resolution, events triggered by some minimum bias condition, independently of the muon detector response, were used: • minimum bias trigger (L0MB), requiring the total energy released in the HCAL to be more than 320 MeV; • "microbias" single track trigger (microbias), requiring some hits compatible with a track in the VELO or first tracking stations.
For spatial alignment studies (section 9) and detector efficiency measurements (section 10), when the statistics of muon tracks in the minimum bias samples was not adequate, events collected with standard physics triggers were used. The samples chosen and the procedures adopted to avoid the bias introduced by the trigger will be described there.
Monte Carlo simulation was used to compare the observed detector performance with the expectation, and to verify the analysis procedures. Standard samples of LHCb Monte Carlo events simulating minimum bias pp interactions and production of prompt J/ψ decaying to µ + µ − were used. Other special samples used for particular needs will be described on the next sections. The events were generated using PYTHIA 6.4 [16] to describe the pp collisions and GEANT4 [17] for the LHCb detector simulation.
Regarding track reconstruction, in the present analysis, standalone muon tracks (M-tracks) are reconstructed with an algorithm similar to the one used in the muon high level trigger [18]. Tracks are reconstructed starting from the firing logical pads. If adjacent fired pads are found, they are clusterized, both in x and y, to obtain track hits. Clusters are allowed to extend across adjacent chambers even belonging to different regions. The x and y of the cluster barycenter and the z of the station midplane are assumed as the track hit coordinates. Hits aligned with the average position of the pp collision point are selected by a combinatorial algorithm. Track hits are fitted to a straight line and quality cuts are applied depending on the measured quantities. M-tracks are usually reconstructed using the information of all the stations unless required by the specific analysis.
M-tracks are required to match with one track reconstructed in the tracking detectors (T-track) only when this is needed to reduce background or to have a good muon momentum measurement. The matching is performed on the basis of the comparison, in one or more muon stations, of the Mtrack hit coordinates with the T-track extrapolations at the corresponding z positions. The compatibility of the M-track and T-track slopes is also required. This procedure is similar to the one used in HLT and offline. In all cases the muon momentum is measured from the matched T-track, forgetting the poor resolution momentum that could be extracted from the M-track as in the L0MU trigger.

Rates
The rate capability was one of the key request for the choice of the technology and the design of the muon detector. Detailed simulations were developed [19] to evaluate the particle rates and radiation doses expected for the nominal LHCb operations at an energy of √ s = 14 TeV and a luminosity of 2 × 10 32 s −1 cm −2 . With respect to the radiation hardness, the detector was designed to stand, for the 10 years of planned LHCb operation, rates larger than a factor 3 in stations M2-M5 and a factor 2 in station M1 as compared with these simulations. The main reasons for the large safety factors were the uncertainies on the track multiplicity in pp collisions predicted by PYTHIA [16], and the uncertainties on the simulation of low energy particles from showers around the beam pipe and particle backscattering from the material surrounding the detector.
From 2010 data we measured the actual rates at √ s = 7 TeV for a wide range of luminosities and compared them with expectations [14]. From the number of hits seen by triggered events we can extract the average number of hits per visible interaction and evaluate the contribution due to the current interactions and the one not due to the triggered collision. The first contribution is by definition independent of luminosity. The second one is expected to be dependent on the beam operation conditions. It can be due to beam background, residual detector noise or, more importantly, to late hits originating from collisions in previous bunches (spillover). Particle back scattering from the cavern or from heavy objects surrounding the beam pipe is expected to give a significant contribution to spillover. Also detector effects like late cross-talk or afterpulses can contribute.
Let's consider the firing logical pads, also called hits in this study, no matter if they clusterize or not. Given an unbiased trigger T , the number of hits per unit surface and per triggered event was computed for each chamber, and the average number of hits in each detector region was calculated after removing the few chambers with channels affected by some pathology. The microbias trigger provided the least biased trigger suitable for the measurement. For each sample, the average number µ of interactions visible in the LHCb detector per beam crossing was evaluated from the fraction f 0 of beam crossing events not producing a trigger where P is the Poisson distribution. The pile-up factor, i.e. the average number of interactions in triggered events, is and the rate of microbias triggered events at a luminosity L is where σ is the cross-section evaluated to be 65 mb with 10% uncertainty, from the first luminosity studies. Starting from the measured values of the number of firing pads per triggered event (equation (6.1) for microbias triggers), the hit rates for each sample are extrapolated to the nominal luminosity of 2 × 10 32 Hz/cm 2 , obtaining the normalized rates  The result is shown in figure 4.
A satisfactory scaling of the rates is verified across five order of magnitudes in luminosity, indicating that contributions not due to the triggered collisions are small with the only important exception of the outer regions of the last station M5 where a significant effect from back scattering is expected due to the limited shielding behind the detector. The contribution of back scattering depends on the beam conditions (µ and bunch spacing) and will be further discussed later in this section.
-10 - In figure 5 the values of the normalized rates R, measured in each region for a high luminosity run are compared with the Monte Carlo data sample produced in the 2010 configuration at √ s = 7 TeV. It must be however taken into account that spillover was not simulated in this sample. The Monte Carlo reproduces the rates of the large outer regions R4 for M2, M3, M4 stations while a lower rate predicted for the outer region of M5 can be attributed to the missing spillover simulation (see later for a further discussion). On the contrary the Monte Carlo rates for M1 and all the inner regions are lower by up to a factor 2. This indicates that the track multiplicity predicted by PYTHIA [16], and the contribution of low energy particles from showers around the beam pipe were underestimated in the simulation. The highest rates measured are however within the safety factor assumed in the detector design phase.
The spillover contribution was estimated from TAE data by using the bunch crossing identification number (BXID) and the fine time information of the 4-bit TDC in the ODE boards. The L0MB events were used, since the microbias triggers were not available in the TAE mode. A typical time distribution showing spillover is reported in figure 6.
The space distribution of any-time signals (125 ns gate) normalized to the in-time (within the standard 25 ns gate) signal distribution, is shown in figure 7. The plots show excess of late hits, clearly not related to the amount of the in-time ones, notably in the up and down edges of the more downstream stations. The effect is impressive in the last station M5 where the too small iron wall behind the detector (see figure 1) provides insufficient shielding from backscattered particles. It is worth to note that the effect of late hits is enhanced in regions where the rate of in-time hits is small and is suppressed where the in-time particle flux is large. This effect is visible for instance in the left and right edges of M5, not fully shielded from in-time particles by calorimeters and upstream muon stations.
In the M5R4 region the total rate of hits in TAE events increases by a factor 10 with respect to the in-time hit rate (from 1.5 to 15 Hz/cm 2 ). The increase for the other regions can be seen in -11 - figure 8. The large effect measured for the downstream stations is essentially due to late backscattered particles. The smaller increase seen for station M1, instead, is mostly due to late cross-talk signals from in-time particles. 5 The overall spillover effect is somewhat large in terms of relative rate increase, but not worrying in terms of absolute occupancy level. It must be added that spillover hits, being mostly seen in the 25 ns following the bunch crossing, do not affect significantly the measured rates when beams are operated with 50 ns bunch crossing spacing. Finally, a check for possible sources of particles outside collision events was performed comparing the rates measured in events randomly triggered by the machine 40 MHz clock, in time or out of time with passing beams. In figure 9 the number of hits per unit surface (equation (6.1)) measured in a run with 150 ns spaced bunch trains, is reported. Events triggered in coincidence with beam-beam collisions (bb) are compared with empty-beam (eb) and empty-empty (ee) events.  The hit rate seen in empty-beam events, triggered in coincidence with the passage of non-colliding bunches, is due to beam-gas interactions and receives little contribution from beam-beam collisions that are at least 150 ns away. The hit rate of empty-empty events, triggered out of time with passing beams, is instead dominated by the delayed hits from collisions occurring 25 or 50 ns before the triggered clock. Except for the low-rate external regions of M5, rates outside collisions are less than 10% of the collision rates. The hit rate measured far from LHC bunch trains is compatible with the residual detector noise.

Cluster size
The average cluster size of muon track hits is an essential parameter of the detector response, since it monitors the correct operation conditions of the chambers and affects the muon trigger performance. In section 5 it has been described how the firing logical pads are clusterized and the track hits defined. The cluster size can be measured in terms of the average number of firing adjacent -13 - Figure 10. Average cluster size along x in a low luminosity run for each detector region. Events are triggered by microbias or L0MB triggers. Cluster selections are described in the text. pads. A cross-talk between adjacent pads due to charge signal induction and to some capacitive coupling is expected. The cluster size values for standard operating conditions were in the past measured on test benches, for particles impinging perpendicularly to the chamber plane, and used to feed Monte Carlo simulations.
The average cluster size in the y coordinate is near to 1, while in x, due to the finer segmentation of chambers in the bending coordinate, is significantly larger than 1. The cluster size along x, and its dependence on the detector geometry of each region, was studied.
It is worth to note that the average cluster size of muon track hits is smaller than the one for all the hits in the detector, as can be seen in figure 10. This effect is large in regions where most of the radiation is due to low energy particles. If clusters associated to a track are also required to be isolated, 6 the cluster size is further reduced demonstrating an effect of hit coalescence. This effect is run dependent, being correlated with event pile-up. The isolation cut reduces the effect of pile-up though not fully suppressing it [14]. For this reason a run with a small µ value must be used to make a comparison with the cluster size measured on test benches.
The purely geometrical effect due to the muon trajectory inside chambers was measured by plotting the average x cluster size as a function of the angle between the track projection on the bending plane and the perpendicular to the chamber plane. A correction for this effect was performed by extrapolating to 0 angle, as shown in figure 11. The resulting average cluster sizes are reported in figure 12 and compared with the values obtained in the simulation. The relative behaviour in the different regions is quite well reproduced and the cluster size in the real data is in several cases smaller, indicating a better tuning of the chamber working conditions since the time of the test benches. The cluster sizes never exceed 1.35, a value well within the L0 trigger requirements [15].
The time behaviour of cross-talk hits was studied using TAE data. While the time distribution of the first pad in time in a cluster is almost fully contained in a 25 ns time window, so ensuring a high trigger efficiency, the other pads in the cluster can arrive significantly later as it is shown in Figure 11. Average x cluster size for isolated track hits as a function of the track angle (in rad) for M2R1 (smallest logical pad region) and M5R4 (largest logical pad region). A linear fit is used to evaluate the cluster size for perpendicularly impinging tracks. Figure 12. Average x cluster size at 0 angle in experimental data and simulation (MC 2010). To suppress the effect of pile-up, only isolated clusters and low-luminosity data are used. figure 13. As a consequence, the cluster size (as the hit rate) measured in a 125 ns time window is larger with respect to the one measured in the 25 ns window. The importance of the effect is region dependent and is quantified in figure 8 for clusters associated to muon tracks. The late cross-talk signals are not normally acquired and thus do not affect the trigger performance, though contributing to background for future beam operations with 25 ns bunch spacing.

Timing
The L0MU trigger requires muon hits to be recorded in each of the five stations within the 25 ns LHC gate associated to a beam-beam crossing. This timing constraint is the most stringent requirement for achieving the design 95% muon detection efficiency. In fact the tails in the chamber time -15 - response are expected to be one of the main sources of detector inefficiency. To reach the goal, the detectors were conceived to have a time resolution better than 4 ns at their nominal settings, while the 122k readout channels have to be time-aligned at the 1 ns r.m.s. level.
The time alignment of the detector has been achieved in several steps. Test signals produced by a custom pulser system [11] were used for a first timing. Cosmic data collected in 2009 allowed to refine the channel equalization using physical signals. These two steps are described in detail in [3] and [20]. After the calibration with cosmic data, a satisfactory time resolution was already reached for all regions except the most inner ones where the statistics was a limit. The precise timing of the first beam particles allowed to quickly intercalibrate the channels of the highly illuminated inner regions. For the other regions, only a few channels exhibiting an anomalous shift in the time response, due to some hardware interventions, were identified and fixed.
The detector efficiency could then be optimized by a fine tuning of the channels time offset with respect to the 40 MHz LHCb clock. The single channel time distribution exhibits an asymmetric shape, with a longer tail for late times. This is due to the intrinsic chamber response (dependent on drift time and time walk with pulse height), to the effect of delayed cross-talk hits and to the effect of the longer path of low momentum tracks. This implies that, in order to minimize the fraction of signals falling outside the 25 ns gate, the average time should not be centered on the middle of the DAQ gate, but slightly before. The optimal offset is region dependent as is the shape of the time spectrum. Moreover, small shifts among regions were already introduced by the optimization of the HV and threshold settings The offset optimization was then independently performed for each detector region. Special runs were acquired with L0MB triggered events in TAE mode, varying the global time offset in steps of 1 ns. For each data sample, standalone muon tracks were reconstructed requiring hits in all five stations. The optimal offset was chosen by maximizing the timing efficiency, defined as the probability that at least one of the track hits in a given station is found within the central 25 ns gate.

Time performance
The detector time performance for each detector region was estimated [14] by analysing two TAE event samples: -16 - Figure 14. Time distribution of the most time centered hit, measured in M5R2 for L0MB events acquired in TAE mode, reported in linear (left) and logarithmic (right) scale. The vertical lines at ± 12.5 ns delimit the "efficient" hits assigned with the BXID number of the trigger. The result of a gaussian fit performed around the maximum of the distribution to evaluate the core time resolution is also shown.
• the first sample was acquired at the beginning of the physics data taking (before applying the final intercalibration for region M1R1) with events triggered by L0MB; • the second sample was acquired at the very end of physics data taking. At that time the L0MB triggers were downscaled by a factor 100 and the need of an adequate statistics required the use of the physics L0 triggers based on calorimeters (electron, photon, hadron triggers).
TAE events were fully reconstructed so that M-tracks could be required to have a good matching with a T-track having a momentum larger than 8 GeV/c to ensure muons to reach the M5 station. Ttracks were required to cross the muon detector at a safety distance from the inner and outer edges to avoid border effects. Clusters inside the few chambers with pathologic behaviour mentioned in section 4, were not considered for the timing efficiency calculation. The time resolution and, most importantly, the timing efficiency is evaluated from the distributions obtained with the BXID and the 4-bit TDC mesurement for the most time centered hit in the track clusters. If such hit is not assigned with the correct BXID , even if the detector is firing, we have an inefficiency due to the timing. As an example, the distribution obtained with the second TAE sample for the M5R2 region is reported in figure 14. From these distributions, the core time resolution was also evaluated from a gaussian fit in the interval (-6, +4) ns around the maximum and its error estimated by shifting the fit interval by ± 2ns.
The average timing efficiency of the five stations and each of the 20 regions, obtained for the TAE sample acquired at the end of data taking, is reported in table 1.
It can be noted that efficiency values in M1 are lower than in the other stations. This is expected considering that M1 is equipped with bi-gap instead of quadri-gap MWPCs and the GEM detectors in the inner region M1R1 have an intrinsic poorer time resolution. Also in the high granularity regions M2/3 R1/2 larger inefficiencies can be expected due to the presence of double readout chambers where the logical "and" of two signals is required. Nevertheless the probability for a muon track reconstructed in TAE events to have hits "in time" in all the 5 stations (overall timing efficiency) is measured to be 98.83 ± 0.09%, a value well beyond requirements. The -17 - On the other hand, the statistics of the available data samples does not allow to tighten the cuts, further improving the muon track sample purity. This is particularly evident for the crowded regions R1 where the statistics of tracks in TAE events, essentially containing low momentum muons from π decays, is limited. Moreover a further reduction of the sample is due to a fiducial volume cut removing tracks near the beam pipe. This cut is needed to reduce the probability of reconstructing tracks with accidental background hits that are characterized by a much wider time distribution. The core resolutions and the timing efficiencies obtained for the two TAE samples are compared in figure 15. Despite the different triggers used in the two samples, resulting in a different momentum spectrum and space distribution of the tracks, the results were found to be in very good agreement, the hint of difference for region M1R1 can be attributed to a more accurate time calibration used for the second sample. This result demonstrates the excellent stability of the muon system along the 2010 run.

Stability of the time response
The stability of the absolute time scale in the long term is expected to be limited by two effects: • the LHCb clock drifts with temperature; variations were compensated manually during the run in order to be stable within ± 0.5 ns; • the variations of temperature and atmospheric pressure affect the chamber gain and variations of signal pulse height produce time walk effects. The largest effect is expected from pressure variations, and is estimated to be equivalent to a ∼ ± 20 V change in HV [21], corresponding to ∼ ± 0.4 ns.
The average time of track hits, measured in the sample runs acquired across the 2010, is shown in figure 16 for various detector regions as a function of the data taking time. The behaviour is consistent with the mentioned effects. Variations are at the level of ± 1 ns and are clearly correlated -18 -

Spatial alignment
The spatial alignment of the muon detector must guarantee the design performance of trigger and offline muon identification. As explained in section 2, the L0MU trigger requires hits in all the 5 stations aligned on a muon track-segment having a p T above a given threshold. Offline muon identification is more flexible in the reconstruction of the muon track-segment but requires the matching with a track reconstructed in the tracking system through the whole spectrometer. The alignment accuracy needed in the system is driven by the trigger requirements in the stations M1, M2 and M3. For these three stations the FOI of the hit search window in the non-bending vertical coordinate, is defined by 1 pad only. As a consequence, a relative y misalignment between the stations would directly contribute to trigger inefficiency (∼2% for 1mm misalignment). In the bending coordinate x, the FOIs are composed of several pads and the main effect of a misalignment is a bias in the p T calculation, at the percent level for 1mm misalignment. However the bias can be removed if the trigger algorithms are suitably corrected using the true x positions. The alignment of stations M4 and M5 is less important because in their case the y FOI is as large as 3 pads and their hits are not used to calculate p T . The detector mechanics was designed with the aim of reaching a precision of the order of 1 mm in x and y directions. The alignment requirements along z are much less demanding due to the forward geometry of the experiment.
During the installation, the supporting walls were kept in the open position and the muon chambers mounted with an accuracy of ∼1 mm along x and y coordinates, centred on their nominal positions, relative to reference targets placed on top of each half station. The measured rotations were zero within the precision of 1 mrad. After chamber installation, the half stations were closed around the beam pipe leaving a small safety distance between the A and C side; the two half stations being ideally positioned left-right symmetric and projective to the interaction point. The closed stations were then surveyed with respect to the LHCb cavern using four reference targets on each side, and the values stored in the geometry database used by the offline reconstruction program to define the absolute hit coordinates. The values measured by the survey for the 2010 collision run are reported in figure 17. They show non negligible though small misalignments from the ideal position for the M1C half station. The misalignments of the other stations are negligible or unimportant.

Space alignment measured with muon tracks
A study of the muon system alignment was performed using muon tracks with the first purpose of checking the mechanical positioning and the survey measurements. In the same time a tool was prepared for alignment monitoring after each intervention requiring the opening of the stations, and eventually for correcting the geometry data base.
In this analysis M-tracks are defined by at least four clusters in four different stations that are compatible with a straight line. Candidates with too large clusters (number of pads>6) are eliminated to avoid mis-reconstruction problems. Moreover stations with more than 300 hits are excluded. The M-tracks are required to match a good quality T-track having a momentum p >6 GeV/c. The matching condition requires a good χ 2 between the parameters of M-track and T-track extrapolated to the M2 position. Matching segments are then merged together in a unique track that is required to have a good χ 2 .
-20 -  The alignment is performed following the standard procedure used in LHCb [22]. It makes use of the Kalman fit iterative method, that performs a minimization of the total χ 2 of an ensemble of tracks while adjusting the detector positions. Only the positions of the muon half stations were allowed to vary since the tracking detectors were previously independently aligned using the same procedure. The iterative process starts assuming the muon detector in the positions measured by the survey and stops when the convergence is reached (total χ 2 doesn't improve significantly) usually after 4-5 iterations. In table 2 are reported the misalignments relative to the survey, measured on a sample of ∼ 7000 tracks, with an analysis performed fitting only the translational degrees of freedom along x and y of each half station. The absolute positions in the LHCb reference system are shown in figure 17 together with the survey measurements.

JINST 8 P02022
The systematic errors have been estimated repeating the analysis with samples of tracks having different momenta, comparing subsamples of tracks hitting different detector regions, and using slightly different alignments for the tracking system. While the absolute positions of the stations show variations of the order of 1 mm both in x and y, their relative positions are more stable. The results obtained with the Kalman fit iterative method show significant, even though small, misalignments relative to the survey measurements (in particular for side C). The geometry data base was consequently updated. Studies on the additional degrees of freedom like rotations around y or x directions give results compatible with the survey. Due to the forward geometry of the experimental apparatus, shifts in z direction are as difficult to measure as unimportant, therefore the z values measured by the survey were assumed.

Detector efficiency
The overall performance of the muon detector is quantified by the detection efficiency of muon tracks when the system is operated in the standard data taking conditions. The inefficiency introduced by dead channels, or other hardware failures occurred in the 2010 detector operation, has been quantified in section 4. Here the intrinsic efficiency of the system is evaluated after applying strict fiducial volume cuts and eliminating the few small zones where known problems are present. An important contribution to inefficiency is expected to come from the time resolution and the time gate of 25 ns. These effects were already studied in section 8.1 and will be further discussed at the end of section 10.4. Other contributions can come from intrinsic chamber inefficiencies, or small geometrical losses due to the chamber-wise discrete structure of the muon detector.
The used procedure is described in detail in reference [14] and is here summarized: • different data sets are used for M1 and M2-M5 stations to select appropriate samples of trigger unbiased standalone muon tracks. To reach the needed purity of the sample, Mtracks are matched with a good quality, high momentum T-track and required to fulfill tight selection criteria (section 10.1).
• The presence of background hits affects the results and requires different procedures to correctly evaluate the true efficiency for M2-M5 stations and for M1 station where the occupancy is much higher (section 10.2).
• The efficiency for each station is estimated by searching clusters around the prediction defined by the M-track reconstructed using only the other 4 stations. The search of clusters around the prediction is repeated increasing the opening window from 1 up to 8 standard deviations, both in x and y. The value of σ being determined, region by region, by a gaussian fit to the central part of the distribution of the distance between the position predicted by the M-track and all clusters in that region. For M1 the prediction is defined by the T-track associated to the M-track in order to improve its quality. The values of σ for the twenty regions are reported in table 3.
If the full procedure is correct, the efficiency measured as a function of the search opening window will show a saturation behaviour permitting a reliable estimate of the detector efficiency.
-22 - Table 3. Resolution along x and y of the distance between the muon track and the muon cluster in each region of the muon detector. The muon track is reconstructed skipping the station whose resolution must be evaluated.

M1
M2 Particular care is required in the background subtraction that must be a stable and reliable procedure even when a search area as large as 16 σ x ×16 σ y is considered.

Muon samples and track selection
Different data samples are used for M1 and for M2-M5 stations: • for the efficiency of M2-M5 stations, data acquired in two fills, corresponding to an integrated luminosity of 1.2 nb −1 , were used. The first level trigger L0 required a high p T hadron or lepton detected in the calorimeter or in the muon system; the software trigger HLT required the logical "or" of several independent algorithms. To remove the bias introduced by the trigger in the efficiency calculation, events where both L0 and HLT were fired irrespectively of the muon system information were selected. With this data sample, the majority of the muons reaching the muon stations and used for the analysis, originate from decays in flight of π's or K's.
• For the M1 efficiency measurement, kaons decaying at the end of the tracking system can generate a good T-track giving a poor quality M1 prediction, not adequate to the large occupancy of the station. To have a sample of true muons, events with a reconstructed J/ψ → µ + µ − were used. This sample corresponds to almost all data acquired in 2010 (∼ 37 pb −1 ). To remove the L0 bias on the efficiency evaluation, in each µ + µ − pair from a J/ψ, the muon which fired the L0 trigger was not considered in the analysis. Notice that the use of the J/ψ sample for the analysis of the M1 station is possible because its information is not used in HLT and reconstruction, while it would not be possible for stations M2-M5 since their information is used to identifie and reconstruct both muons.
A tight selection is required to reach the purity of the M-track sample needed for a precise efficiency measurement and different conditions are required for the different stations. For every station, when its efficiency is being evaluated, the M-track is validated by requiring the matching with a T-track in the other four stations used for the fit. The matching requires that the distance from the T-track extrapolated to the station and the clusters associated to the M-track is within one standard deviation in both x and y projections. Such standard deviations are estimated by a gaussian fit to the central peak of the distance distributions.
-23 -A momentum cut of 12 GeV/c (15 GeV/c) is applied to the T-track when M2 (M3, M4, M5) station is analysed. If more than one T-track matches the M-track candidate and at least one of them has a momentum below the cut, the candidate is rejected. When evaluating the efficiency of M2 and M3, where the occupancy is relatively high and the fired hits are identified by crossing vertical and horizontal strips, further cuts on the local hit multiplicity are applied to avoid ghost combinations. Moreover, when analyzing the efficiency of M3 where the prediction resolution is poor due to the lower granularity of M4, a cluster size of 1 is required on M2 station. For the analysis of M1 station, the M-track sample selection starts from the T-track associated to a muon candidate from the J/ψ and a cut on momentum of 12 GeV/c is applied.

Background subtraction
The presence of background clusters affects the search results. The necessary background subtraction requires different procedures for M2-M5 and for M1 station where the occupancy is higher.
Assuming a Poissonian nature of the background, the average number of clusters due to the background and the efficiency in a given search window can be extracted by a fit to the distribution of the number of clusters found. If this method works, the background estimate in the neighbouring of the muon track takes automatically into account any possible correlation between muons and background, as in the case of delta rays or punch through in the calorimeter.
For stations M2-M5, a fully satisfactory result is obtained assuming a background with two Poissonian components; the probability of finding n clusters in the search window being where ε is the efficiency to be measured, B1 and B2 are the two Poissonian components of the background and r their ratio.
As an example, in figure 18 are reported the results of the fit in the case of an opening window of 8σ x and 8σ y for the station M3. It is worth to add that a fit with only one Poissonian component for the background does not give an equally good representation of the high multiplicity bins, but the fitted values of the efficiency do not show significant differences.
In the case of the more crowded station M1 where the J/ψ muon sample is used, the cluster multiplicities are not very well fitted assuming a background with two Poissonian components. Thus another fully independent method is also used to evaluate the background and the efficiency. It exploits the φ rotation invariance of the primary interactions and assumes that the background correlated with the muon track is negligible. The background is estimated by counting the average number of clusters in the same search window but in the opposite quadrant, with respect to the track prediction. The soundness of the method is confirmed by comparing the number of clusters found in the opposite quadrant with the number of clusters in the track prediction quadrant having subtracted one cluster attributed to the muon track, as shown in figure 19.
The true efficiency ε t is then estimated by the formula: where ε a is the apparent efficiency calculated as N Nclus>0 /N Preds , being N Nclus>0 the number of tracks where at least one cluster has been found and N Preds the total number of tracks predicted to -24 -  fall in the search window; P bg = N NclusOQ>0 /N Preds is the probability to find at least one cluster in the search window in the opposite quadrant (OQ).
-25 - The efficiency values obtained with this method do not show any significant difference with the values obtained with the previous one.

Check of the procedure with simulation
To evaluate if the whole procedure of track selection, background subtraction and efficiency determination is robust and unbiased, a test has been made using events simulated with a Monte Carlo where all background components, like spillover hits and detector noise, are described and detector effects, such as cross-talk and chamber time jitter, are included.
The efficiency values computed on Monte Carlo events are well in agreement with the simulation parameters assumed and close to the results obtained with real data. However, to test the validity of the method, it is not so important to reproduce the absolute values found in data as to compare the efficiencies measured with Minimum Bias (for M2-M5) and J/ψ (for M1) Monte Carlo events with the ones obtained applying the same procedure to another Monte Carlo sample of ideal muon tracks, the so-called Particle Gun (PG) muons. These muons are generated as starting from the interaction point with a predefined momentum and angular distribution. Since those events are practically background free and do not suffer from fakes in track reconstruction and selection, they allow to cleanly extract the detector efficiency with the present method. Then, independently of the absolute values found, a satisfactory agreement between the two samples would be an overall check of the correctness of the procedure. The efficiency values were found to agree within the errors for the stations M1-M4, while for R3 and R4 regions of the M5 station the efficiency extracted from the Minimum Bias is lower than the corresponding PG efficiency as shown in table 4. This difference is explained with a lack of purity of the Minimum Bias track sample: part of the selected tracks are muons produced in the showers inside the calorimeter that are aligned and matched with the hadron track initiating the shower. These muons have sometimes low momentum and are absorbed between M4 and M5. This effect is region dependent 7 and can cause an artificial inefficiency in M5. Removing the muons with momentum below 6 GeV/c, the efficiencies reach values in agreement with the PG sample as can be seen in table 4. To take into account such effect, the real data results will be corrected for the ratio between the efficiencies with and without the 6 GeV/c cut, as extracted by the Minimum Bias Monte Carlo sample.

Measured efficiencies
The behaviour of the efficiency as a function of the number of σ 's of the opening window has been analysed for each region of the muon system. In all cases a correct saturation is observed at 3-4σ demonstrating the reliability of the method. However the final value taken for the efficiency is the one at 8σ to allow for the presence of non gaussian tails in the prediction point. Figure 20 shows the behaviour of the efficiency as a function of the number of σ for the four regions of M2 station.
In figure 21 the same quantity is shown for the station M1, with the efficiencies obtained with equation (10.2).
The efficiency for M1 was at the end evaluated as the average of the efficiencies obtained with the two methods corresponding to equations (10.1) and (10.2), which turn out to be in excellent agreement.
In table 5 the measured efficiencies with the statistical and systematic errors are reported. For M2-M5 the systematic errors due to background modeling have been estimated by changing the fit function from two poissonians to a single one. The efficiency varies less than 0.01% in all regions of M2-M5. For M1 where two independent methods of estimating the background have been used, a systematic uncertainty of half the difference between the two results has been assumed. Since the choice of evaluating the final efficiency at 8σ has a certain degree of arbitrariness, a systematic error of half the difference between the efficiency value calculated at 4σ and 8σ has been assumed. The uncertainty, due to MC limited statistics, of the correction applied on the M5 efficiency to take into account the absorption of muons between M4 and M5, is included in the systematics. The different sources give comparable systematic uncertainties that have been added in quadrature.   Table 5. Efficiency values (%) of all the twenty regions with their statistical and systematic errors. Statistical errors have been evaluated with an approximated binomial 68% confidence interval. Systematic errors are calculated as the sum in quadrature of various contributions -see text for details. to be compatible or only slightly better than the overall efficiency. This indicates that the bulk of the detector inefficiency comes from signals falling outside the 25 ns LHC gate and the intrinsic chamber inefficiencies, or the small geometrical losses give minor contributions.

Conclusions
The muon detector was successfully operated since the first year of LHC physics. Its performance has been studied across the five orders of magnitude of luminosity experienced during 2010 and compared with expectation. The whole system demonstrated an excellent reliability and stability. Detector requirements in terms of cluster size, time resolution and efficiency are fullfilled.
During 2010 a small number of dead channels accounted for an overall inefficiency in the muon detection 1%. Most of these channels were cured in the LHC shutdown after the 2010 data taking. Thanks to a good monitoring system and maintenance work, temporary failures occurring during the run, mainly HV trips of single chamber gaps, accounted for per mil effects in the efficiency. A careful setting of the chamber working point and a precise timing intercalibration allowed to reach a muon detection efficiency, mainly determined by the chamber time resolution, well above the design requirement of 99% in all the 5 muon stations.