dbjergaard/rivet-fast-jet-substructure — pull request #1 by karlnordstrom (2012-11-13 15:19:09+00:00)
Title: ACF/ASF code, updated N-subjettiness

Functions added for calculating the ACF/ASF and finding peaks in the ASF.
Short usage:

(assuming fj is a FastJets object)

to access all the peaks in the ASF function, use:
vector ACFpeak peaks = fj.ASFPeaks( constituents, 0, 0 );

To access peaks with prominence > h:
vector ACFpeak peaks = fj.ASFPeaks( constituents, 0, h);

To access the n most prominent peaks:
vector ACFpeak peaks = fj.ASFPeaks( constituents, n, 0);

To access the n most prominent peaks, with a minimum prominence of h (returns less than n peaks if there are not enough peaks over h):
vector ACFpeak peaks = fj.ASFPeaks( constituents, n, h);

The ACFpeak data struct lets the user access the peak's Rval, prominence, partial mass, etc.
Note: when both n and h are != 0, the peaks are returned in order of prominence (most prominent one is peaks[0]). Otherwise they are returned in order of increasing value of \delta R.

For the purposes of plotting a single ASF/ACF function you can access the values by using:
vector ACFfunction ACF = fj.ACFValues( constituents);
vector ACFfunction ASF = fj.ASFValues( constituents);

The ACFfunction data struct lets the user access the Rval and (function) value (the x and y value, respecticely).

-------------------------

UpdateAxes changed to work on a reference to already existing axes, rather than creating a new set of axes. This should be easier to use and since the algorithm always finds a (local) minimum there is no point in saving the previous iterations.

Before:
vector PseudoJet newaxes = fj.UpdateAxes( beta, constituents, oldaxes);

Now:
fj.UpdateAxes( beta, constituents, axes);