31 #include <fastjet/CompositeJetStructure.hh>
33 FASTJET_BEGIN_NAMESPACE
46 CompositeJetStructure::CompositeJetStructure(
const std::vector<PseudoJet> & initial_pieces,
48 : _pieces(initial_pieces){
54 bool has_area_local =
true;
55 for (vector<PseudoJet>::const_iterator pit=
_pieces.begin(); pit!=
_pieces.end(); pit++){
56 if (!pit->has_area()){
57 has_area_local =
false;
64 for (
unsigned int i=0; i<
_pieces.size(); i++){
84 string str =
"Composite PseudoJet";
107 vector<PseudoJet> all_constituents;
108 for (
unsigned i = 0; i <
_pieces.size(); i++) {
110 vector<PseudoJet> constits =
_pieces[i].constituents();
111 copy(constits.begin(), constits.end(), back_inserter(all_constituents));
113 all_constituents.push_back(
_pieces[i]);
117 return all_constituents;
136 throw Error(
"One or more of this composite jet's pieces does not support area");
139 for (
unsigned i = 0; i <
_pieces.size(); i++)
151 throw Error(
"One or more of this composite jet's pieces does not support area");
154 for (
unsigned i = 0; i <
_pieces.size(); i++)
163 throw Error(
"One or more of this composite jet's pieces does not support area");
172 for (
unsigned i = 0; i <
_pieces.size(); i++)
181 FASTJET_END_NAMESPACE