Version: SMASH-3.4
smash::CollisionBranch Class Reference

#include <processbranch.h>

CollisionBranch is a derivative of ProcessBranch, which is used to represent particular final-state channels in a collision.

Definition at line 275 of file processbranch.h.

Inheritance diagram for smash::CollisionBranch:
[legend]
Collaboration diagram for smash::CollisionBranch:
[legend]

Public Member Functions

 CollisionBranch (double w, ProcessType p_type)
 Construct collision branch with empty final state. More...
 
 CollisionBranch (const ParticleType &type, double w, ProcessType p_type)
 Construct collision branch with 1 particle in final state. More...
 
 CollisionBranch (const ParticleType &type_a, const ParticleType &type_b, double w, ProcessType p_type)
 Construct collision branch with 2 particles in final state. More...
 
 CollisionBranch (const ParticleType &type_a, const ParticleType &type_b, const ParticleType &type_c, double w, ProcessType p_type)
 Construct collision branch with 3 particles in final state. More...
 
 CollisionBranch (const ParticleType &type_a, const ParticleType &type_b, const ParticleType &type_c, const ParticleType &type_d, double w, ProcessType p_type)
 Construct collision branch with 4 particles in final state. More...
 
 CollisionBranch (const ParticleType &type_a, const ParticleType &type_b, const ParticleType &type_c, const ParticleType &type_d, const ParticleType &type_e, double w, ProcessType p_type)
 Construct collision branch with 5 particles in final state. More...
 
 CollisionBranch (ParticleTypePtrList new_types, double w, ProcessType p_type)
 Construct collision branch with a list of particles in final state. More...
 
 CollisionBranch (CollisionBranch &&rhs)
 The move constructor efficiently moves the particle-type list member. More...
 
const ParticleTypePtrList & particle_types () const override
 
void set_type (ProcessType p_type)
 Set the process type. More...
 
ProcessType get_type () const override
 
unsigned int particle_number () const override
 
- Public Member Functions inherited from smash::ProcessBranch
 ProcessBranch ()
 Create a ProcessBranch without final states and weight. More...
 
 ProcessBranch (double w)
 Create a ProcessBranch with with weight but without final states. More...
 
 ProcessBranch (const ProcessBranch &)=delete
 Copying is disabled. Use std::move or create a new object. More...
 
virtual ~ProcessBranch ()=default
 Virtual Destructor. More...
 
void set_weight (double process_weight)
 Set the weight of the branch. More...
 
ParticleList particle_list () const
 
double weight () const
 
double threshold () const
 

Private Attributes

ParticleTypePtrList particle_types_
 List of particles appearing in this process outcome. More...
 
ProcessType process_type_
 Process type are used to distinguish different types of processes, e.g. More...
 

Additional Inherited Members

- Protected Attributes inherited from smash::ProcessBranch
double branch_weight_
 Weight of the branch, typically a cross section or a branching ratio. More...
 
double threshold_ = -1.
 Threshold of the branch. More...
 

Constructor & Destructor Documentation

◆ CollisionBranch() [1/8]

smash::CollisionBranch::CollisionBranch ( double  w,
ProcessType  p_type 
)
inline

Construct collision branch with empty final state.

Parameters
[in]wWeight of created branch.
[in]p_typeProcess type of created branch.

Definition at line 282 of file processbranch.h.

283  : ProcessBranch(w), process_type_(p_type) {}
ProcessType process_type_
Process type are used to distinguish different types of processes, e.g.
ProcessBranch()
Create a ProcessBranch without final states and weight.

◆ CollisionBranch() [2/8]

smash::CollisionBranch::CollisionBranch ( const ParticleType type,
double  w,
ProcessType  p_type 
)
inline

Construct collision branch with 1 particle in final state.

Parameters
[in]typeParticle type of final state particle.
[in]wWeight of created branch.
[in]p_typeProcess type of created branch.

Definition at line 290 of file processbranch.h.

291  : ProcessBranch(w), process_type_(p_type) {
292  particle_types_.reserve(1);
293  particle_types_.push_back(&type);
294  }
ParticleTypePtrList particle_types_
List of particles appearing in this process outcome.

◆ CollisionBranch() [3/8]

smash::CollisionBranch::CollisionBranch ( const ParticleType type_a,
const ParticleType type_b,
double  w,
ProcessType  p_type 
)
inline

Construct collision branch with 2 particles in final state.

Parameters
[in]type_aParticle types of one final state particle.
[in]type_bParticle types of other final state particle.
[in]wWeight of created branch.
[in]p_typeProcess type of created branch.

Definition at line 302 of file processbranch.h.

304  : ProcessBranch(w), process_type_(p_type) {
305  particle_types_.reserve(2);
306  particle_types_.push_back(&type_a);
307  particle_types_.push_back(&type_b);
308  }

◆ CollisionBranch() [4/8]

smash::CollisionBranch::CollisionBranch ( const ParticleType type_a,
const ParticleType type_b,
const ParticleType type_c,
double  w,
ProcessType  p_type 
)
inline

Construct collision branch with 3 particles in final state.

Parameters
[in]type_aParticle type of first final state particle.
[in]type_bParticle type of second final state particle.
[in]type_cParticle type of third final state particle.
[in]wWeight of created branch.
[in]p_typeProcess type of created branch.

Definition at line 318 of file processbranch.h.

320  : ProcessBranch(w), process_type_(p_type) {
321  particle_types_.reserve(3);
322  particle_types_.push_back(&type_a);
323  particle_types_.push_back(&type_b);
324  particle_types_.push_back(&type_c);
325  }

◆ CollisionBranch() [5/8]

smash::CollisionBranch::CollisionBranch ( const ParticleType type_a,
const ParticleType type_b,
const ParticleType type_c,
const ParticleType type_d,
double  w,
ProcessType  p_type 
)
inline

Construct collision branch with 4 particles in final state.

Parameters
[in]type_aParticle type of first final state particle.
[in]type_bParticle type of second final state particle.
[in]type_cParticle type of third final state particle.
[in]type_dParticle type of fourth final state particle.
[in]wWeight of created branch.
[in]p_typeProcess type of created branch.

Definition at line 336 of file processbranch.h.

339  : ProcessBranch(w), process_type_(p_type) {
340  particle_types_.reserve(4);
341  particle_types_.push_back(&type_a);
342  particle_types_.push_back(&type_b);
343  particle_types_.push_back(&type_c);
344  particle_types_.push_back(&type_d);
345  }

◆ CollisionBranch() [6/8]

smash::CollisionBranch::CollisionBranch ( const ParticleType type_a,
const ParticleType type_b,
const ParticleType type_c,
const ParticleType type_d,
const ParticleType type_e,
double  w,
ProcessType  p_type 
)
inline

Construct collision branch with 5 particles in final state.

Parameters
[in]type_aParticle type of first final state particle.
[in]type_bParticle type of second final state particle.
[in]type_cParticle type of third final state particle.
[in]type_dParticle type of fourth final state particle.
[in]type_eParticle type of fith final state particle.
[in]wWeight of created branch.
[in]p_typeProcess type of created branch.

Definition at line 357 of file processbranch.h.

360  : ProcessBranch(w), process_type_(p_type) {
361  particle_types_.reserve(5);
362  particle_types_.push_back(&type_a);
363  particle_types_.push_back(&type_b);
364  particle_types_.push_back(&type_c);
365  particle_types_.push_back(&type_d);
366  particle_types_.push_back(&type_e);
367  }

◆ CollisionBranch() [7/8]

smash::CollisionBranch::CollisionBranch ( ParticleTypePtrList  new_types,
double  w,
ProcessType  p_type 
)
inline

Construct collision branch with a list of particles in final state.

Parameters
[in]new_typesList of particle types of final state particles.
[in]wWeight of created branch.
[in]p_typeProcess type of created branch.

Definition at line 375 of file processbranch.h.

376  : ProcessBranch(w),
377  particle_types_(std::move(new_types)),
378  process_type_(p_type) {}

◆ CollisionBranch() [8/8]

smash::CollisionBranch::CollisionBranch ( CollisionBranch &&  rhs)
inline

The move constructor efficiently moves the particle-type list member.

Definition at line 380 of file processbranch.h.

381  : ProcessBranch(rhs.branch_weight_),
382  particle_types_(std::move(rhs.particle_types_)),
383  process_type_(rhs.process_type_) {}

Member Function Documentation

◆ particle_types()

const ParticleTypePtrList& smash::CollisionBranch::particle_types ( ) const
inlineoverridevirtual
Returns
the particle types associated with this branch.

Implements smash::ProcessBranch.

Definition at line 384 of file processbranch.h.

384  {
385  return particle_types_;
386  }
Here is the caller graph for this function:

◆ set_type()

void smash::CollisionBranch::set_type ( ProcessType  p_type)
inline

Set the process type.

Parameters
[in]p_typeThe new value of the process type

Definition at line 392 of file processbranch.h.

392 { process_type_ = p_type; }

◆ get_type()

ProcessType smash::CollisionBranch::get_type ( ) const
inlineoverridevirtual
Returns
type of the process

Implements smash::ProcessBranch.

Definition at line 394 of file processbranch.h.

394 { return process_type_; }
Here is the caller graph for this function:

◆ particle_number()

unsigned int smash::CollisionBranch::particle_number ( ) const
inlineoverridevirtual
Returns
number of particles involved in the process

Implements smash::ProcessBranch.

Definition at line 396 of file processbranch.h.

396  {
397  return particle_types_.size();
398  }

Member Data Documentation

◆ particle_types_

ParticleTypePtrList smash::CollisionBranch::particle_types_
private

List of particles appearing in this process outcome.

Definition at line 402 of file processbranch.h.

◆ process_type_

ProcessType smash::CollisionBranch::process_type_
private

Process type are used to distinguish different types of processes, e.g.

string formation, resonance formation, elastic scattering and so on.

Definition at line 408 of file processbranch.h.


The documentation for this class was generated from the following file: