|
close
Warning:
Can't synchronize with repository "(default)" ("(default)" is not readable or not a Git repository.). Look in the Trac log for more information.
- Timestamp:
-
Jan 6, 2017, 4:08:35 PM (8 years ago)
- Author:
-
Clarence Wret
- Comment:
-
--
Legend:
- Unmodified
- Added
- Removed
- Modified
-
v47
|
v48
|
|
215 | 215 | The data and covariance matrix are available in a ROOT file for the sample, so I used `Measurement1D::SetDataFromFile` to set up the data and `Measurement1D::SetCovarFromDataFile` to set up the covariances. |
216 | 216 | |
| 217 | `fName` and the other `std::string`s were set to reasonable names and `fScaleFactor` was |
| 218 | |
217 | 219 | The `constructor` for the class now looks like: |
218 | 220 | |
… |
… |
|
229 | 231 | fPlotTitles = "; p_{#mu} (GeV/c); d#sigma/dp_{#mu} (cm^{2}/(GeV/c)/nucleon)"; |
230 | 232 | EnuMin = 0.; |
231 | | EnuMax = 10.; |
| 233 | EnuMax = 100.; |
232 | 234 | Measurement1D::SetupMeasurement(inputfile, type, rw, fakeDataFile); |
233 | 235 | |
… |
… |
|
325 | 327 | }}} |
326 | 328 | |
327 | | We should now write a helper function in the `FitUtils` namespace to get `E^rec^,,nu,,` from the muon, pion and neutrino `TLorentzVector`s. [arxiv 1605.07964v2.pdf The paper] specifies the exact form in equation 1. The `FitUtils` implementation lives in `src/Utils/FitUtils.cxx`. |
| 329 | We should now write a helper function in the `FitUtils` namespace to get `E^rec^,,nu,,` from the muon, pion and neutrino `TLorentzVector`s. [https://arxiv.org/pdf/1605.07964v2.pdf The paper] specifies the exact form in equation 1. The `FitUtils` implementation lives in `src/Utils/FitUtils.cxx`. |
328 | 330 | |
329 | 331 | {{{ |
… |
… |
|
373 | 375 | The base class function `MeasurementBase::Reconfigure()` specifies `isSignal(FitEvent *)` which is what we will implement in our class. Since we plan on re-using the signal definition for multiple distributions, we should include it in the `src/T2K/T2K_SignalDef.cxx` implementation, as mentioned [#point_signal earlier]. |
374 | 376 | |
375 | | Reading the [arxiv 1605.07964v2.pdf paper], we see the requirement: |
| 377 | Reading the [https://arxiv.org/pdf/1605.07964v2.pdf paper], we see the requirement: |
376 | 378 | |
377 | 379 | "The analysis presented restricts the kinematic phase-space to the region defined by p,,µ,, > 200 MeV/c, p,,π,,^+^ > 200 MeV/c, cos(θ,,µ,,) > 0.3 and cos(θ,,π+,, ) > 0.3." |
378 | 380 | |
379 | | |
| 381 | so our signal definition needs to extract these quantities from the `FitEvent` object. |
| 382 | |
| 383 | We prefer a clear unambiguous naming scheme, so let's name the namespace function `isCC1pip_T2K_H2O`. The function will need to take the `FitEvent` object along with the `EnuMin` and `EnuMax` defined in the experiment signal definition. |
| 384 | |
| 385 | In the signal definition we can use already declared functions of the namespace `SignalDef`. These live in `src/Utils/SignalDef.cxx`. We can see a `SignalDef::isCC1pi(FitEvent *, int nuPDG, int piPDG, double EnuMin, double EnuMax)`. This helper function searches for: |
| 386 | |
| 387 | * 1 single lepton of type `nuPDG-1` |
| 388 | * 1 single pion of type `piPDG` |
| 389 | * makes sure the neutrino energy is between `EnuMin` and `EnuMax` |
| 390 | |
| 391 | We can then add our kinematic requirements on the muon and pion in our `SignalDef::isCC1pip_T2K_H2O(FitEvent *event, double EnuMin, double EnuMax` implementation in `src/T2K/T2K_SignalDef.cxx`. |
| 392 | |
| 393 | In summary, we get for `src/T2K/T2K_SignalDef.cxx`: |
| 394 | |
| 395 | {{{ |
| 396 | namespace SignalDef { |
| 397 | |
| 398 | // T2K H2O signal definition |
| 399 | bool isCC1pip_T2K_H2O(FitEvent *event, double EnuMin, |
| 400 | double EnuMax) { |
| 401 | |
| 402 | if (!isCC1pi(event, 14, 211, EnuMin, EnuMax)) return false; |
| 403 | |
| 404 | TLorentzVector Pnu = event->GetHMISParticle(14)->fP; // Can also use FitEvent::GetNeutrinoIn() |
| 405 | TLorentzVector Pmu = event->GetHMFSParticle(13)->fP; |
| 406 | TLorentzVector Ppip = event->GetHMFSParticle(211)->fP; |
| 407 | |
| 408 | double p_mu = FitUtils::p(Pmu) * 1000; |
| 409 | double p_pi = FitUtils::p(Ppip) * 1000; |
| 410 | double cos_th_mu = cos(FitUtils::th(Pnu, Pmu)); |
| 411 | double cos_th_pi = cos(FitUtils::th(Pnu, Ppip)); |
| 412 | |
| 413 | if (p_mu <= 200 || p_pi <= 200 || cos_th_mu <= 0.3 || cos_th_pi <= 0.3) { |
| 414 | return false; |
| 415 | } |
| 416 | |
| 417 | return true; |
| 418 | }; |
| 419 | |
| 420 | } |
| 421 | |
| 422 | }}} |
| 423 | |
| 424 | Then back in `src/T2K/T2K_CC1pip_H2O_XSec_1Dpmu_nu.cxx` we simply do: |
| 425 | |
| 426 | {{{ |
| 427 | //******************************************************************** |
| 428 | // Beware: The H2O analysis has different signal definition to the CH analysis! |
| 429 | bool T2K_CC1pip_H2O_XSec_1Dpmu_nu::isSignal(FitEvent *event) { |
| 430 | //******************************************************************** |
| 431 | return SignalDef::isCC1pip_T2K_H2O(event, EnuMin, EnuMax); |
| 432 | } |
| 433 | }}} |
| 434 | |
| 435 | making sure our [#point_header header file] has `#include "T2K_SignalDef.h"`. |
380 | 436 | |
381 | 437 | |
382 | 438 | = The final implementation = |
| 439 | |
| 440 | Here's a summary of the implementation for reference: |
| 441 | |
383 | 442 | `T2K_CC1pip_H2O_XSec_1Dpmu_nu.cxx`: |
384 | 443 | |
… |
… |
|
460 | 519 | }}} |
461 | 520 | |
| 521 | |
| 522 | |
462 | 523 | = Make NUISANCE aware of the sample = |
463 | 524 | FCN/SampleList |
|