cepgen is hosted by Hepforge, IPPP Durham
CepGen N/A
Central exclusive processes event generator
ParticleProperties.h
Go to the documentation of this file.
1/*
2 * CepGen: a central exclusive processes event generator
3 * Copyright (C) 2017-2025 Laurent Forthomme
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, either version 3 of the License, or
8 * any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 */
18
19#ifndef CepGen_Physics_ParticleProperties_h
20#define CepGen_Physics_ParticleProperties_h
21
23
24namespace cepgen {
25 using pdgid_t = unsigned long long;
26 using pdgids_t = std::vector<pdgid_t>;
27 using spdgid_t = long long;
28 using spdgids_t = std::vector<spdgid_t>;
30 struct ParticleProperties final : SteeredObject<ParticleProperties> {
32 explicit ParticleProperties(pdgid_t pdgid = 0ull, // PDG::invalid
33 const std::string& name = "",
34 const std::string& description = "",
35 int colours = -1,
36 double mass = -1.,
37 double width = -1.,
38 const std::vector<int>& charges = {},
39 bool fermion = false);
40
42
43 friend std::ostream& operator<<(std::ostream&, const ParticleProperties&);
44
45 short integerCharge() const;
46
47 pdgid_t pdgid{0ull};
48 std::string name{};
49 std::string human_name{};
50 int colours{0};
51 double mass{0.};
52 double width{0.};
53 std::vector<int> charges{};
54 bool fermion{false};
55 };
56} // namespace cepgen
57
58#endif
A description object for parameters collection.
Base user-steerable object.
Common namespace for this Monte Carlo generator.
Definition Handler.h:26
long long spdgid_t
Alias for a signed particle PDG id (adding charge information)
unsigned long long pdgid_t
Alias for the integer-like particle PDG id.
std::vector< spdgid_t > spdgids_t
Alias for a collection of particles signed PDG ids A collection of physics constants associated to a ...
std::vector< pdgid_t > pdgids_t
Alias for a collection of particles PDG ids.
ParticleProperties(const ParametersList &)
double mass
Mass, in GeV/c .
std::string human_name
Human-readable name.
friend std::ostream & operator<<(std::ostream &, const ParticleProperties &)
pdgid_t pdgid
PDG identifier.
std::vector< int > charges
Electric charges, in /3.
static ParametersDescription description()
std::string name
Particle name.
short integerCharge() const
Integer charge, in /3.
double width
Decay width, in GeV/c .
bool fermion
Is the particle a fermion?
ParticleProperties(pdgid_t pdgid=0ull, const std::string &name="", const std::string &description="", int colours=-1, double mass=-1., double width=-1., const std::vector< int > &charges={}, bool fermion=false)