34 lines
1.1 KiB
C++
Executable File
34 lines
1.1 KiB
C++
Executable File
#ifndef CLUSTER_FORMATION_H
|
|
#define CLUSTER_FORMATION_H
|
|
|
|
#include <functional>
|
|
#include "simulation/interaction.h"
|
|
|
|
// defined in "simulation/species.h"
|
|
namespace species {
|
|
class Specie;
|
|
};
|
|
|
|
namespace interaction {
|
|
|
|
// class for cluster formation interactions (A + B --> AB)
|
|
class ClusterFormation : public Interaction {
|
|
public:
|
|
// Constructor: takes the function describing the cross section (dependent on the energy of the incident particle)
|
|
// and a shared_ptr to the Species that is the target in the interaction
|
|
// and a shared_ptr to the TrackedSpecie that is the product of the interaction
|
|
ClusterFormation(std::function<double(double)> cross_section,
|
|
std::shared_ptr<species::Specie> target,
|
|
std::shared_ptr<species::TrackedSpecie> product);
|
|
// return an InteractionOutput object with the results of the interaction
|
|
InteractionOutput performInteraction(particle::Particle& particle,
|
|
RandomNumbers* generator);
|
|
|
|
private:
|
|
std::shared_ptr<species::TrackedSpecie> product_;
|
|
};
|
|
|
|
}; // namespace interaction
|
|
|
|
#endif /* CLUSTER_FORMATION_H */
|