|
musrfit 1.10.0
|
Class for handling standard μSR asymmetry fits. More...
#include <PRunAsymmetry.h>


Public Member Functions | |
| PRunAsymmetry () | |
| Default constructor. | |
| PRunAsymmetry (PMsrHandler *msrInfo, PRunDataHandler *rawData, UInt_t runNo, EPMusrHandleTag tag, Bool_t theoAsData) | |
| Main constructor for μSR asymmetry fitting. | |
| virtual | ~PRunAsymmetry () |
| Destructor. | |
| virtual Double_t | CalcChiSquare (const std::vector< Double_t > &par) |
| Calculates chi-square for the current parameter set. | |
| virtual Double_t | CalcChiSquareExpected (const std::vector< Double_t > &par) |
| Calculates expected chi-square (for statistical analysis). | |
| virtual Double_t | CalcMaxLikelihood (const std::vector< Double_t > &par) |
| Calculates maximum likelihood estimator. | |
| virtual void | CalcTheory () |
| Calculates theoretical asymmetry function. | |
| virtual UInt_t | GetNoOfFitBins () |
| Returns the number of bins used in the fit. | |
| virtual void | SetFitRangeBin (const TString fitRange) |
| Sets the fit range in bins. | |
| virtual Int_t | GetStartTimeBin () |
| Returns the first bin used in the fit. | |
| virtual Int_t | GetEndTimeBin () |
| Returns the last bin used in the fit. | |
| virtual Int_t | GetPacking () |
| Returns the packing factor. | |
| virtual void | CalcNoOfFitBins () |
| Calculates the number of bins to be fitted. | |
Public Member Functions inherited from PRunBase | |
| PRunBase () | |
| Default constructor. | |
| PRunBase (PMsrHandler *msrInfo, PRunDataHandler *rawData, UInt_t runNo, EPMusrHandleTag tag) | |
| Constructor initializing run from MSR file and raw data. | |
| virtual | ~PRunBase () |
| Virtual destructor. | |
| virtual void | SetFitRange (PDoublePairVector fitRange) |
| Sets the fit time range for this run. | |
| virtual UInt_t | GetRunNo () |
| Returns the run number (0-based index in MSR file). | |
| virtual PRunData * | GetData () |
| Returns pointer to processed data container. | |
| virtual void | CleanUp () |
| Cleans up internal data structures. | |
| virtual Bool_t | IsValid () |
| Returns validity status of this run object. | |
Protected Member Functions | |
| virtual Bool_t | PrepareData () |
| Prepares all data for fitting or viewing. | |
| virtual Bool_t | PrepareFitData () |
| Prepares data specifically for fitting. | |
| virtual Bool_t | PrepareViewData (PRawRunData *runData, UInt_t histoNo[2]) |
| Prepares data for viewing/plotting. | |
| virtual Bool_t | PrepareRRFViewData (PRawRunData *runData, UInt_t histoNo[2]) |
| Prepares rotating reference frame (RRF) data for viewing. | |
Protected Member Functions inherited from PRunBase | |
| virtual void | DeadTimeCorrection (std::vector< PDoubleVector > &histos, PUIntVector &histoNo) |
| carry out dead time correction | |
| virtual void | CalculateKaiserFilterCoeff (Double_t wc, Double_t A, Double_t dw) |
| Calculates Kaiser window FIR filter coefficients for RRF smoothing. | |
| virtual void | FilterTheo () |
| Applies Kaiser FIR filter to theory values for RRF fits. | |
Private Member Functions | |
| Bool_t | SubtractFixBkg () |
| Subtracts fixed background from histograms. | |
| Bool_t | SubtractEstimatedBkg () |
| Estimates and subtracts background from histograms. | |
| virtual Bool_t | GetProperT0 (PRawRunData *runData, PMsrGlobalBlock *globalBlock, PUIntVector &forwardHisto, PUIntVector &backwardHistoNo) |
| Retrieves proper t0 values for all histograms. | |
| virtual Bool_t | GetProperDataRange (PRawRunData *runData, UInt_t histoNo[2]) |
| Retrieves proper data range for histograms. | |
| virtual void | GetProperFitRange (PMsrGlobalBlock *globalBlock) |
| Determines the proper fit range from global block. | |
Private Attributes | |
| UInt_t | fAlphaBetaTag |
| Tag indicating α/β configuration: 1=both unity, 2=α free/β unity, 3=α unity/β free, 4=both free. | |
| UInt_t | fNoOfFitBins |
| Number of bins included in the fit. | |
| Int_t | fPacking |
| Bin packing factor from RUN or GLOBAL block. | |
| Bool_t | fTheoAsData |
| If true, theory calculated only at data points; if false, extra points for nicer Fourier transforms. | |
| PDoubleVector | fForward |
| Forward detector histogram data. | |
| PDoubleVector | fForwardErr |
| Forward detector histogram errors. | |
| PDoubleVector | fBackward |
| Backward detector histogram data. | |
| PDoubleVector | fBackwardErr |
| Backward detector histogram errors. | |
| Int_t | fGoodBins [4] |
| Good bin boundaries: [0]=forward first, [1]=forward last, [2]=backward first, [3]=backward last. | |
| Int_t | fStartTimeBin |
| First bin index for fitting. | |
| Int_t | fEndTimeBin |
| Last bin index for fitting. | |
Additional Inherited Members | |
Protected Attributes inherited from PRunBase | |
| Bool_t | fValid |
| Flag indicating if run object initialized successfully; false if any error occurred. | |
| EPMusrHandleTag | fHandleTag |
| Operation mode: kFit (fitting), kView (display only), kEmpty (uninitialized) | |
| Int_t | fRunNo |
| Run number (0-based index in MSR file RUN blocks) | |
| PMsrHandler * | fMsrInfo |
| Pointer to MSR file handler (owned externally, not deleted here) | |
| PMsrRunBlock * | fRunInfo |
| Pointer to this run's RUN block settings within fMsrInfo. | |
| PRunDataHandler * | fRawData |
| Pointer to raw data handler (owned externally, not deleted here) | |
| PRunData | fData |
| Processed data container: background-corrected, packed, with theory values. | |
| Double_t | fTimeResolution |
| Time resolution of raw histogram data in microseconds (μs), e.g., 0.01953125 μs for PSI GPS. | |
| PMetaData | fMetaData |
| Experimental metadata extracted from data file header (magnetic field, temperature, beam energy) | |
| PDoubleVector | fT0s |
| Time-zero bin values for all histograms in this run (forward, backward, etc.) | |
| std::vector< PDoubleVector > | fAddT0s |
| Time-zero bin values for additional runs to be added to main run. | |
| Double_t | fFitStartTime |
| Fit range start time in microseconds (μs) relative to t0. | |
| Double_t | fFitEndTime |
| Fit range end time in microseconds (μs) relative to t0. | |
| PDoubleVector | fFuncValues |
| Cached values of user-defined functions from FUNCTIONS block, evaluated at current parameters. | |
| std::unique_ptr< PTheory > | fTheory |
| Theory function evaluator (smart pointer, automatically deleted) | |
| PDoubleVector | fKaiserFilter |
| Kaiser window FIR filter coefficients for smoothing RRF theory curves. | |
Class for handling standard μSR asymmetry fits.
PRunAsymmetry implements asymmetry fitting for conventional μSR experiments, where the asymmetry is calculated from forward and backward detector histograms:
![\[ A(t) = \frac{F(t) - \alpha B(t)}{F(t) + \alpha B(t)} \]](form_3.png)
The class supports various configurations:
The α/β parameter configurations are:
Definition at line 61 of file PRunAsymmetry.h.
| PRunAsymmetry::PRunAsymmetry | ( | ) |
Default constructor.
Default constructor that initializes all member variables.
Sets all counters and indices to default/invalid values. This constructor creates an invalid instance that requires proper initialization via the main constructor.
Definition at line 60 of file PRunAsymmetry.cpp.
References fEndTimeBin, fGoodBins, fNoOfFitBins, fPacking, fStartTimeBin, fTheoAsData, and PRunBase::PRunBase().
| PRunAsymmetry::PRunAsymmetry | ( | PMsrHandler * | msrInfo, |
| PRunDataHandler * | rawData, | ||
| UInt_t | runNo, | ||
| EPMusrHandleTag | tag, | ||
| Bool_t | theoAsData ) |
Main constructor for μSR asymmetry fitting.
Main constructor that initializes μSR asymmetry fitting.
| msrInfo | Pointer to MSR file handler |
| rawData | Pointer to raw run data handler |
| runNo | Run number within the MSR file |
| tag | Operation mode (kFit for fitting, kView for viewing) |
| theoAsData | If true, calculate theory only at data points; if false, calculate additional points for Fourier |
Performs comprehensive initialization:
The α/β tag determines the asymmetry calculation method:
| msrInfo | Pointer to MSR file handler |
| rawData | Pointer to raw run data handler |
| runNo | Run number within the MSR file |
| tag | Operation mode (kFit or kView) |
| theoAsData | If true, calculate theory only at data points |
Definition at line 100 of file PRunAsymmetry.cpp.
References fEndTimeBin, fGoodBins, PRunBase::fMsrInfo, fPacking, PRunBase::fRunInfo, fStartTimeBin, fTheoAsData, PRunBase::fValid, PMsrHandler::GetMsrParamList(), if(), MSR_PARAM_FUN_OFFSET, and PRunBase::PRunBase().
|
virtual |
Destructor.
Destructor that cleans up histogram data.
Clears all four histogram vectors (forward/backward × data/errors) to free memory.
Definition at line 200 of file PRunAsymmetry.cpp.
References fBackward, fBackwardErr, fForward, and fForwardErr.
|
virtual |
Calculates chi-square for the current parameter set.
Calculates chi-square for μSR asymmetry fit.
| par | Parameter vector from MINUIT |
Computes χ² by comparing the measured asymmetry with theory: χ² = Σ[(A_data - A_theory)²/σ²]
The asymmetry calculation depends on fAlphaBetaTag:
Supports OpenMP parallelization for faster calculation.
| par | Parameter vector from MINUIT minimizer |
Implements PRunBase.
Definition at line 228 of file PRunAsymmetry.cpp.
References fAlphaBetaTag, PRunBase::fData, fEndTimeBin, PRunBase::fFuncValues, PRunBase::fMetaData, PRunBase::fMsrInfo, PRunBase::fRunInfo, fStartTimeBin, PRunBase::fTheory, and MSR_PARAM_FUN_OFFSET.
|
virtual |
Calculates expected chi-square (for statistical analysis).
Calculates expected chi-square value.
| par | Parameter vector from MINUIT |
This function is currently not implemented for asymmetry fits because the expected chi-square calculation for asymmetry data requires a more complex statistical treatment than for single histogram fits. The asymmetry is a ratio of count rates, and the proper expected value calculation is non-trivial.
| par | Parameter vector from MINUIT minimizer |
Implements PRunBase.
Definition at line 335 of file PRunAsymmetry.cpp.
|
virtual |
Calculates maximum likelihood estimator.
Calculates maximum likelihood estimator for asymmetry fit.
| par | Parameter vector from MINUIT |
Maximum likelihood estimation provides an alternative to χ² minimization and can be more appropriate for low-count data where Gaussian statistics do not apply. However, the proper likelihood function for μSR asymmetry data is complex and not yet implemented.
| par | Parameter vector from MINUIT minimizer |
Implements PRunBase.
Definition at line 355 of file PRunAsymmetry.cpp.
|
virtual |
Calculates the number of bins to be fitted.
Calculates the number of bins included in the current fit range.
Determines fNoOfFitBins based on the fit range and data availability.
Determines fStartTimeBin and fEndTimeBin from the fit time range (fFitStartTime, fFitEndTime) and data time grid. Ensures that bin indices remain within valid histogram bounds. The result is stored in fNoOfFitBins.
This calculation accounts for:
Definition at line 486 of file PRunAsymmetry.cpp.
References PRunBase::fData, fEndTimeBin, PRunBase::fFitEndTime, PRunBase::fFitStartTime, fNoOfFitBins, and fStartTimeBin.
Referenced by GetNoOfFitBins(), PrepareFitData(), and PrepareViewData().
|
virtual |
Calculates theoretical asymmetry function.
Calculates theoretical asymmetry values for the current parameters.
Computes the theory values for the μSR asymmetry based on the current parameters and fit function.
Computes the expected asymmetry A(t) for all data points based on the current parameter values and the user-defined theory function. The calculation depends on the α/β correction mode:
where f(t) is the raw theory function from the THEORY block.
The calculated values are stored in fData for plotting and comparison with measured data.
Implements PRunBase.
Definition at line 521 of file PRunAsymmetry.cpp.
References fAlphaBetaTag, PRunBase::fData, PRunBase::fFuncValues, PRunBase::fMetaData, PRunBase::fMsrInfo, PRunBase::fRunInfo, PRunBase::fTheory, and MSR_PARAM_FUN_OFFSET.
|
inlinevirtual |
Returns the last bin used in the fit.
Definition at line 131 of file PRunAsymmetry.h.
References fEndTimeBin.
|
virtual |
Returns the number of bins used in the fit.
Returns the number of bins included in the fit.
Calculates and returns the number of data bins that fall within the current fit range. This value is used for determining degrees of freedom and is recalculated when the fit range changes (e.g., via COMMAND block).
Definition at line 374 of file PRunAsymmetry.cpp.
References CalcNoOfFitBins(), and fNoOfFitBins.
|
inlinevirtual |
Returns the packing factor.
Definition at line 137 of file PRunAsymmetry.h.
References fPacking.
|
privatevirtual |
Retrieves proper data range for histograms.
Determines the valid data range (first/last good bins) for analysis.
Determines the "good bins" range for data analysis from:
The good bins define which portion of the histograms contains valid data, excluding noisy or problematic regions at the start/end.
| runData | Pointer to raw run data |
| histoNo | Array of histogram numbers [0]=forward, [1]=backward |
The data range defines which portion of the histograms contains usable data, excluding initial and final bins that may be noisy or affected by detector artifacts.
Determination hierarchy:
Performs validation checks:
The good bins are stored in fGoodBins as [forward_start, forward_end, backward_start, backward_end].
| runData | Pointer to raw run data for histogram size validation |
| histoNo | Array of histogram indices: [0]=forward, [1]=backward |
Definition at line 2018 of file PRunAsymmetry.cpp.
References fBackward, fForward, fGoodBins, PRunBase::fMsrInfo, PRunBase::fRunInfo, PRunBase::fT0s, PRunBase::fTimeResolution, and PRawRunData::GetDataBin().
Referenced by PrepareData().
|
privatevirtual |
Determines the proper fit range from global block.
Determines the fit range for χ² minimization.
Extracts fit range settings from the GLOBAL block if not specified in the RUN block. The fit range defines the time window used for χ² minimization, specified either in time units (μs) or bin numbers.
| globalBlock | Pointer to global MSR block containing default fit range |
The fit range defines the time window used for parameter fitting. It can be specified in two formats:
Determination sequence:
Bin-based format allows fine-tuning relative to good bin boundaries:
The resulting fit range is stored as time values in fFitStartTime and fFitEndTime.
| globalBlock | Pointer to GLOBAL block containing default fit range settings |
Definition at line 2172 of file PRunAsymmetry.cpp.
References PRunBase::fFitEndTime, PRunBase::fFitStartTime, fGoodBins, PRunBase::fRunInfo, PRunBase::fT0s, PRunBase::fTimeResolution, PMsrGlobalBlock::GetFitRange(), PMsrGlobalBlock::GetFitRangeOffset(), PMsrGlobalBlock::IsFitRangeInBin(), PMUSR_UNDEFINED, and PMsrGlobalBlock::SetFitRange().
Referenced by PrepareData().
|
privatevirtual |
Retrieves proper t0 values for all histograms.
Determines and validates t0 values for all forward and backward histograms.
Determines t0 (time zero) values for forward and backward histograms from:
Also handles addT0 corrections for runs to be added together. The t0 values are critical for proper alignment of histograms in time.
| runData | Pointer to raw run data containing histogram information |
| globalBlock | Pointer to global MSR block with default t0 values |
| forwardHisto | Vector of forward histogram indices |
| backwardHistoNo | Vector of backward histogram indices |
Time zero (t0) marks the arrival time of muons in the sample and is critical for proper time alignment. This method attempts to find t0 values from multiple sources with a well-defined fallback hierarchy:
Priority order:
The t0 vector is organized as [forward_0, backward_0, forward_1, backward_1, ...], accommodating different numbers of forward/backward histograms in grouped data.
Also handles addT0 values for runs being added together, ensuring proper time alignment when combining multiple datasets.
| runData | Pointer to raw run data containing file-based t0 information |
| globalBlock | Pointer to GLOBAL block with default t0 settings |
| forwardHistoNo | Vector of forward histogram indices (after red/green offset adjustment) |
| backwardHistoNo | Vector of backward histogram indices (after red/green offset adjustment) |
Definition at line 1830 of file PRunAsymmetry.cpp.
References PRunBase::fAddT0s, PRunBase::fRawData, PRunBase::fRunInfo, PRunBase::fT0s, PRawRunData::GetDataBin(), PMsrGlobalBlock::GetT0Bin(), PRawRunData::GetT0Bin(), PRawRunData::GetT0BinEstimated(), and PMsrGlobalBlock::GetT0BinSize().
Referenced by PrepareData().
|
inlinevirtual |
Returns the first bin used in the fit.
Definition at line 125 of file PRunAsymmetry.h.
References fStartTimeBin.
|
protectedvirtual |
Prepares all data for fitting or viewing.
Main data preparation routine for asymmetry fitting and viewing.
Main data preparation routine that handles background subtraction, packing, and asymmetry calculation from forward/backward histograms.
Performs comprehensive data preparation including:
The asymmetry is calculated as:
![\[ A_i = \frac{f_i^{\rm c} - b_i^{\rm c}}{f_i^{\rm c} + b_i^{\rm c}} \]](form_61.png)
Error propagation (assuming Poisson statistics):
![\[ \Delta A_i = \pm\frac{2}{(f_i^{\rm c}+b_i^{\rm c})^2}\sqrt{
(b_i^{\rm c})^2 (\Delta f_i^{\rm c})^2 +
(f_i^{\rm c})^2 (\Delta b_i^{\rm c})^2} \]](form_62.png)
where 

Implements PRunBase.
Definition at line 629 of file PRunAsymmetry.cpp.
References PRunBase::DeadTimeCorrection(), PRunBase::fAddT0s, fBackward, fForward, PRunBase::fHandleTag, PRunBase::fMetaData, PRunBase::fMsrInfo, PRunBase::fRawData, PRunBase::fRunInfo, PRunBase::fT0s, PRunBase::fTimeResolution, PRunBase::fValid, PRawRunData::GetDataBin(), PRawRunData::GetEnergy(), PRawRunData::GetField(), PRawRunData::GetNoOfTemperatures(), GetProperDataRange(), GetProperFitRange(), GetProperT0(), PRawRunData::GetTemperature(), PRawRunData::GetTimeResolution(), PRawRunData::IsPresent(), kFit, kView, PMUSR_UNDEFINED, PrepareFitData(), PrepareRRFViewData(), PrepareViewData(), status, SubtractEstimatedBkg(), and SubtractFixBkg().
|
protectedvirtual |
Prepares data specifically for fitting.
Processes pre-grouped data and calculates asymmetry for fitting.
Sets up data structures for the fitting process, including determining fit ranges and calculating the number of fit bins.
Takes forward/backward histograms (after grouping and addrun operations) and performs final processing steps for fitting:


Bin packing averages multiple bins to improve statistics:

Definition at line 1067 of file PRunAsymmetry.cpp.
References PRunData::AppendErrorValue(), PRunData::AppendValue(), CalcNoOfFitBins(), fBackward, fBackwardErr, PRunBase::fData, fForward, fForwardErr, fGoodBins, fPacking, PRunBase::fT0s, PRunBase::fTimeResolution, PRunData::GetError(), and PRunData::GetValue().
Referenced by PrepareData().
|
protectedvirtual |
Prepares rotating reference frame (RRF) data for viewing.
Prepares rotating reference frame (RRF) data for visualization.
| runData | Pointer to raw run data |
| histoNo | Array of histogram numbers [0]=forward, [1]=backward |
Special handling for RRF data where asymmetry is calculated in a rotating coordinate frame.
Transforms asymmetry data into a rotating reference frame for analyzing high-frequency oscillations. The RRF technique mixes the data with a reference frequency to shift oscillations down to lower frequencies, making them easier to visualize and analyze.
Processing sequence:




The RRF frequency ( 

| runData | Pointer to raw run data for validation |
| histoNo | Array of histogram indices: [0]=forward, [1]=backward |
Definition at line 1483 of file PRunAsymmetry.cpp.
References PRunBase::CalculateKaiserFilterCoeff(), fAlphaBetaTag, fBackward, fBackwardErr, PRunBase::fData, fForward, fForwardErr, PRunBase::fFuncValues, fGoodBins, PRunBase::FilterTheo(), PRunBase::fMetaData, PRunBase::fMsrInfo, PRunBase::fRunInfo, PRunBase::fT0s, PRunBase::fTheory, PRunBase::fTimeResolution, GAMMA_BAR_MUON, PRawRunData::GetDataBin(), MSR_PARAM_FUN_OFFSET, RRF_UNIT_G, RRF_UNIT_kHz, RRF_UNIT_Mcs, RRF_UNIT_MHz, and RRF_UNIT_T.
Referenced by PrepareData().
|
protectedvirtual |
Prepares data for viewing/plotting.
Prepares asymmetry data for plotting and visualization.
| runData | Pointer to raw run data |
| histoNo | Array of histogram numbers [0]=forward, [1]=backward |
Processes pre-grouped data for display in plots, with special handling for view packing and α/β corrections. Similar to PrepareFitData but includes theory calculation and supports separate view packing settings.
Processing steps:


| runData | Pointer to raw run data for validation and cross-checks |
| histoNo | Array of histogram indices: [0]=forward, [1]=backward |
Definition at line 1191 of file PRunAsymmetry.cpp.
References PRunData::AppendErrorValue(), PRunData::AppendValue(), CalcNoOfFitBins(), fAlphaBetaTag, fBackward, fBackwardErr, PRunBase::fData, fForward, fForwardErr, PRunBase::fFuncValues, fGoodBins, PRunBase::fMetaData, PRunBase::fMsrInfo, fPacking, PRunBase::fRunInfo, PRunBase::fT0s, fTheoAsData, PRunBase::fTheory, PRunBase::fTimeResolution, PRawRunData::GetDataBin(), PRunData::GetError(), PRunData::GetValue(), and MSR_PARAM_FUN_OFFSET.
Referenced by PrepareData().
|
virtual |
Sets the fit range in bins.
Dynamically changes the fit range in bin units.
| fitRange | Fit range string (format depends on configuration) |
Allows modification of the fit range at runtime, typically called from the COMMAND block. Supports bin-based fit ranges with optional offsets for fine-tuning.
Syntax formats:
Parameters:
Example: "FIT_RANGE 10+5 200-10" uses bins [15, 190] for fitting
| fitRange | String containing fit range specification |
Definition at line 406 of file PRunAsymmetry.cpp.
References PRunBase::fFitEndTime, PRunBase::fFitStartTime, fGoodBins, PRunBase::fRunNo, PRunBase::fT0s, and PRunBase::fTimeResolution.
|
private |
Estimates and subtracts background from histograms.
Calculates background from a specified bin range (typically before t0) and subtracts it from forward and backward histograms. The background range is adjusted to align with accelerator beam cycles when applicable (PSI, RAL, TRIUMF).
Background calculation:
![\[ \mathrm{bkg} = \frac{1}{N}\sum_{i=0}^N f_i \]](form_8.png)
Error propagation:
![\[ \Delta f_i^{\rm c} = \pm\sqrt{(\Delta f_i)^2 + (\Delta \mathrm{bkg})^2} = \pm\sqrt{f_i + (\Delta \mathrm{bkg})^2} \]](form_9.png)
where 
![\[ \Delta \mathrm{bkg} = \pm\frac{1}{N}\sqrt{\sum_{i=0}^N f_i} \]](form_11.png)
Subtracts the background which is estimated from a given interval (typically before t0).
The background corrected histogramms are: 




![\[ \Delta f_i^{\rm c} = \pm \sqrt{ (\Delta f_i)^2 + (\Delta \mathrm{bkg})^2 } =
\pm \sqrt{f_i + (\Delta \mathrm{bkg})^2} \]](form_54.png)
The background error 
![\[ \Delta \mathrm{bkg} = \pm\frac{1}{N}\left[\sum_{i=0}^N (\Delta f_i)^2\right]^{1/2} =
\pm\frac{1}{N}\left[\sum_{i=0}^N f_i \right]^{1/2},\]](form_56.png)
where 
return:
Definition at line 942 of file PRunAsymmetry.cpp.
References ACCEL_PERIOD_PSI, ACCEL_PERIOD_RAL, ACCEL_PERIOD_TRIUMF, fBackward, fBackwardErr, fForward, fForwardErr, fPacking, PRunBase::fRunInfo, and PRunBase::fTimeResolution.
Referenced by PrepareData().
|
private |
Subtracts fixed background from histograms.
Subtracts user-specified fixed background values from forward and backward histograms. Background values are read from the MSR file (e.g., "backgr.fix 2 3" for forward/backward).
Error propagation:
![\[ \Delta f_i^{\rm c} = \pm\sqrt{(\Delta f_i)^2 + (\Delta \mathrm{bkg})^2} = \pm\sqrt{f_i + \mathrm{bkg}} \]](form_4.png)
where 


Subtracts a fixed background from the raw data. The background is given in units of (1/bin); for the Asymmetry representation (1/ns) doesn't make too much sense. The error propagation is done the following way: it is assumed that the error of the background is Poisson like, i.e. 
Error propagation:
![\[ \Delta f_i^{\rm c} = \pm\left[ (\Delta f_i)^2 + (\Delta \mathrm{bkg})^2 \right]^{1/2} =
\pm\left[ f_i + \mathrm{bkg} \right]^{1/2}, \]](form_52.png)
where 


return:
Definition at line 884 of file PRunAsymmetry.cpp.
References fBackward, fBackwardErr, fForward, fForwardErr, PRunBase::fRunInfo, and PMUSR_UNDEFINED.
Referenced by PrepareData().
|
private |
Tag indicating α/β configuration: 1=both unity, 2=α free/β unity, 3=α unity/β free, 4=both free.
Definition at line 185 of file PRunAsymmetry.h.
Referenced by CalcChiSquare(), CalcTheory(), PrepareRRFViewData(), and PrepareViewData().
|
private |
Backward detector histogram data.
Definition at line 192 of file PRunAsymmetry.h.
Referenced by GetProperDataRange(), PrepareData(), PrepareFitData(), PrepareRRFViewData(), PrepareViewData(), SubtractEstimatedBkg(), SubtractFixBkg(), and ~PRunAsymmetry().
|
private |
Backward detector histogram errors.
Definition at line 193 of file PRunAsymmetry.h.
Referenced by PrepareFitData(), PrepareRRFViewData(), PrepareViewData(), SubtractEstimatedBkg(), SubtractFixBkg(), and ~PRunAsymmetry().
|
private |
Last bin index for fitting.
Definition at line 198 of file PRunAsymmetry.h.
Referenced by CalcChiSquare(), CalcNoOfFitBins(), GetEndTimeBin(), PRunAsymmetry(), and PRunAsymmetry().
|
private |
Forward detector histogram data.
Definition at line 190 of file PRunAsymmetry.h.
Referenced by GetProperDataRange(), PrepareData(), PrepareFitData(), PrepareRRFViewData(), PrepareViewData(), SubtractEstimatedBkg(), SubtractFixBkg(), and ~PRunAsymmetry().
|
private |
Forward detector histogram errors.
Definition at line 191 of file PRunAsymmetry.h.
Referenced by PrepareFitData(), PrepareRRFViewData(), PrepareViewData(), SubtractEstimatedBkg(), SubtractFixBkg(), and ~PRunAsymmetry().
|
private |
Good bin boundaries: [0]=forward first, [1]=forward last, [2]=backward first, [3]=backward last.
Definition at line 195 of file PRunAsymmetry.h.
Referenced by GetProperDataRange(), GetProperFitRange(), PrepareFitData(), PrepareRRFViewData(), PrepareViewData(), PRunAsymmetry(), PRunAsymmetry(), and SetFitRangeBin().
|
private |
Number of bins included in the fit.
Definition at line 186 of file PRunAsymmetry.h.
Referenced by CalcNoOfFitBins(), GetNoOfFitBins(), and PRunAsymmetry().
|
private |
Bin packing factor from RUN or GLOBAL block.
Definition at line 187 of file PRunAsymmetry.h.
Referenced by GetPacking(), PrepareFitData(), PrepareViewData(), PRunAsymmetry(), PRunAsymmetry(), and SubtractEstimatedBkg().
|
private |
First bin index for fitting.
Definition at line 197 of file PRunAsymmetry.h.
Referenced by CalcChiSquare(), CalcNoOfFitBins(), GetStartTimeBin(), PRunAsymmetry(), and PRunAsymmetry().
|
private |
If true, theory calculated only at data points; if false, extra points for nicer Fourier transforms.
Definition at line 188 of file PRunAsymmetry.h.
Referenced by PrepareViewData(), PRunAsymmetry(), and PRunAsymmetry().