SNR with pileup3: PHA detector statistics with pileup
This post continues the discussion of my paper “Signal to noise ratio of energy selective xray photon counting systems with pileup”
[1], which is available for free download
here. Following the road map described in my
last post, I am deriving and validating formulas for the statistics of photon counting detectors with pileup. In this post, I describe formulas for the expected value and covariance of pulse height analysis data with pileup and present software to verify the formulas with Monte Carlo simulations.
I have derived the formulas for PHA statistics with pileup in several previous posts. The best way to read them is in my ebook, which you can get by
emailing me. The derivation is split into several posts, which are in Part IV of the ebook but also accessible online.

The theory for recorded counts with dead time is derived in this post.

The formulas for the recorded energy spectrum are derived here.

The theory for the expected values and covariance of PHA data is derived in this post.

A Monte Carlo validation is described here.
In this post, I summarize the formulas for PHA with pileup and validate them with a Monte Carlo simulation. I will repeat the previous validation using random data generated with the PileupPulses function from the
first post in the series on the SNR paper. I think this is easier to understand than the version used previously.
PHA formulas
The formulas for PHA with pileup are summarized in the following tables repeated here from
this post. They were derived in the posts listed in the previous section.
The expected value, variance and covariance of the recorded counts for bin k, M_{k}, are
expected value

⟨M_{k}⟩ = ⟨M⟩p_{k}

variance

var(M_{k}) = ⟨M⟩p_{k} + (var(M) − ⟨M⟩)p^{2}_{k}

covariance

cov(M_{j}, M_{k}) = p_{j}p_{k}(var(M) − ⟨M⟩)

The variables in these formulas are defined in this table:
dead time

τ

mean incident count rate

λ

integration time

T

mean incident counts

N_{0} = ∫S(E)dE = λT

expected total recorded counts

⟨M⟩ = (λT)/(1 + λτ)

variance of recorded counts

var(M) = (λT)/((1 + λτ)^{3})

normalized incident spectrum

s(E) = (S(E))/(N_{0})

bin fraction

p_{k} = (∫^{Ek}_{Ek − 1}S_{deadtime}(E)dE)/(∫S_{deadtime}(E)dE)

spectrum with pulse pileup

S_{deadtime}(E) = N_{0}∑^{∞}_{k = 0}((λτ)^{k})/(k!)e^{ − λτ}(s^{(k)}*s)

Validate PHA formulas with Monte Carlo simulation
These formulas were validated with a Monte Carlo simulation in
this post.
The random data were generated with the same code used for the NQ simulation in my
last post. This code uses the PileupPulses function introduced in the
first post of this series. The bin counts were generated from the recorded energies data in the
egys_rec variable with the Matlab histogram bin counts function
histc as shown in the code snippet below:
1[npulses_record, egys_rec] = PileupPulses(dt_pulse,deadtime, ...
2 t_integrate,’specinv’,spinv);
3 % PHA data
4counts = histc(egys_rec,egy_bin_edges);
5phacnts(kdead, ktrial, :) = counts(1:(end1));
Two bin PHA was used with an interbin energy specified by specdat.Ethreshold. This required the following bin edges values as input for histc:
1egy_bin_edges = [0 specdat.Ethreshold inf];
A length three array is required because of a peculiarity in the design of histc. The last value in the counts array is the number of input values that are equal to the last value in the egy_bin_edges array. By setting the end value equal to infinity, we guarantee that all recorded events with energy greater than the threshold are in the second bin and all energies less than the threshold are in the first bin.
Comparison of Monte Carlo statistics with theoretical formulas
The next code block implements the theoretical formulas in the tables with the parameters used to generate the random data. These theoretical results are plotted along with the Monte Carlo results in the remaining part of the code block. The plots are shown below:
Conclusion
The formulas are validated by the Monte Carlo simulation for the values tested.
Bob Alvarez
Last edited Jan 05, 2015
Copyright © 2014 by Robert E. Alvarez
Linking is allowed but reposting or mirroring is expressly forbidden.
References
[1] Robert E. Alvarez: “Signal to noise ratio of energy selective xray photon counting systems with pileup”, Med. Phys., pp. , 2014.