next up previous contents
Next: Recording and Accessing Event Up: Overview Previous: The Problem   Contents

The Solution

The solution, as implemented by TCA, is to sequentially read a time-ordered n-tuple file and look for correlations by try to associate pairs of events within a sliding time gate. Currently TCA can only process a single n-tuple file - to concatenate file for now you will have to use the PAW command NTUPLE/HMERGE. Possible future developments in this area include:-

You have to describe to TCA:-

TCA proceeds as follows:-

  1. It reads the first event from the input n-tuple into a buffer.

  2. It reads and buffers further events so that, relative to the first event, the time gate is full.

  3. It looks for associations between the first event as a primary, and other events in the buffer as secondaries.

  4. Each time an association is found an output n-tuple entry is generated.

  5. Once all possible associations with the first event have been tested, it moves on to the second event and updates the buffer.

  6. The process repeats, with old events dropping out of the buffer and fresh ones entering so as to maintain the time gate, until all events are processed.

To illustrate the way TCA is used, suppose you have an n-tuple with the following 5 variables:-

TIME
The current absolute time. Actually we need 4 words to describe this but we will return to this point in 7.2

NHIT
Number of PMT hits.

X, Y, Z
Fitted X, Y, Z.

and further suppose you are looking for a process with the following characteristics:-

Most of this specification is recorded in a TCAR (TCA Request) bank which has a form that is identical to the NTPR. However, unlike the NTPR, there can only be one TCAR active at any time. The TCAR serves two purposes:-

A TCA request to look for the type of process described above could be:-

nhits1    equals             nhits_1:          60. 999999.;     
nhits2    equals             nhits_2:          20. 999999.;     
_dist     distance           x_1, x_2:          0.    100.;     
time1     equals             time_1;

There are several points to note:-

So far we have not placed the most important restriction on the association, namely the time gate. This is done with the command:-
$TCA_TIME_GATE -100000 500000
which requires the secondary to be no more than 100000 nsec before to 500000 nsec after the primary. You might be wondering why the time constraint is not applied in the same way as the space constraint i.e. with something like:-
_del_time1     difference     time_1,time_2: -100000 500000 ;
for an answer you will have to wait until section 7.2

Careful use of lines that help define primaries and secondaries can save both time and buffer space. For example, if an event fails the primary tests, TCA won't waste time checking associations in which that event plays the role of primary. If an event fails as both a primary and a secondary, TCA saves buffer space by not storing it at all.

TCA operation requires two types of bank: TCAR which holds requests and TCAC which controls the way TCA operates. The contents of TCAR has already been briefly described. The TCAC bank provides default for the way TCA operates and can be overridden by symbolic commands. For example, the command $TCA_TIME_GATE updates words in the TCAC bank.

Currently TCA only combines pairs of events. However the notation was chosen to make it easy to extend to higher multiplicities and this will be done if there is sufficient demand.


next up previous contents
Next: Recording and Accessing Event Up: Overview Previous: The Problem   Contents
sno Guest Acct 2009-09-09