jetty

Implementations of common inclusive jet clustering algorithms.

In the current version, the following distance measures are implemented:

This crate uses a naive clustering implementation. For state-of-the-art implementations of many more jet algorithms, have a look at the excellent fastjet library.

Examples

Cluster a number of partons into jets using the anti-kt algorithm with radius 0.4:

```rust use jetty::{antiktf, cluster, clusterif, pseudojetf};

let partons = vec![ pseudojetf(0.2626773221934335, -0.08809521946454194, -0.1141608706693822, -0.2195584284654444), pseudojetf(2.21902459329915, -0.7529973704809976, -0.9658189214109036, -1.850475321845671) ];

// get all jets let alljets = cluster(partons.clone(), &antiktf(0.4)); asserteq!(all_jets.len(), 1);

// get all jets with at least 40 GeV let jets40gev = clusterif( partons.clone(), &antiktf(0.4), |jet| jet.pt2() > 40. * 40. ); asserteq!(jets40gev.len(), 0); ```

License: GPL-3.0-or-later