fastjet 2.4.5
AreaDefinition.cc
Go to the documentation of this file.
00001 //STARTHEADER
00002 // $Id: AreaDefinition.cc 632 2007-05-10 15:17:00Z salam $
00003 //
00004 // Copyright (c) 2005-2007, Matteo Cacciari, Gavin Salam and Gregory Soyez
00005 //
00006 //----------------------------------------------------------------------
00007 // This file is part of FastJet.
00008 //
00009 //  FastJet is free software; you can redistribute it and/or modify
00010 //  it under the terms of the GNU General Public License as published by
00011 //  the Free Software Foundation; either version 2 of the License, or
00012 //  (at your option) any later version.
00013 //
00014 //  The algorithms that underlie FastJet have required considerable
00015 //  development and are described in hep-ph/0512210. If you use
00016 //  FastJet as part of work towards a scientific publication, please
00017 //  include a citation to the FastJet paper.
00018 //
00019 //  FastJet is distributed in the hope that it will be useful,
00020 //  but WITHOUT ANY WARRANTY; without even the implied warranty of
00021 //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00022 //  GNU General Public License for more details.
00023 //
00024 //  You should have received a copy of the GNU General Public License
00025 //  along with FastJet; if not, write to the Free Software
00026 //  Foundation, Inc.:
00027 //      59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00028 //----------------------------------------------------------------------
00029 //ENDHEADER
00030 
00031 #include "fastjet/AreaDefinition.hh"
00032 #include<sstream>
00033 #include<string>
00034 
00035 using namespace std;
00036 
00037 FASTJET_BEGIN_NAMESPACE      // defined in fastjet/internal/base.hh
00038 
00039 string VoronoiAreaSpec::description() const {
00040   ostringstream ostr;
00041   ostr << "Voronoi area with effective_Rfact = " << effective_Rfact() ;
00042   return ostr.str();
00043 }
00044 
00045 
00046 //----------------------------------------------------------------------
00048 string AreaDefinition::description() const {
00049   ostringstream ostr;
00050 
00051   switch(area_type()) {
00052   case active_area:
00053     ostr << "Active area (hidden ghosts) with " ;
00054     ostr << ghost_spec().description();
00055     break;
00056   case active_area_explicit_ghosts:
00057     ostr << "Active area (explicit ghosts) with " ;
00058     ostr << ghost_spec().description();
00059     break;
00060   case one_ghost_passive_area:
00061     ostr << "Passive area (one ghost at a time) with " ;
00062     ostr << ghost_spec().description();
00063     break;
00064   case passive_area:
00065     ostr << "Passive area (optimal alg. based on jet.def.), where relevant with " ;
00066     ostr << ghost_spec().description()  ;
00067     break;
00068   case voronoi_area:
00069     ostr << voronoi_spec().description();
00070     break;
00071   default:
00072     cerr << "Error: unrecognized area_type in AreaDefinition::description():" 
00073          << area_type() << endl;
00074     exit(-1);
00075   }
00076   return ostr.str();
00077 }
00078 
00079 FASTJET_END_NAMESPACE      // defined in fastjet/internal/base.hh
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines