Newer
Older
// Class to sum up any number of generic amplitudes and build observables.
// Amplitudes are loaded up in a vector and summed incoherently
//
// Author: Daniel Winney (2020)
// Affiliation: Joint Physics Analysis Center (JPAC)
// Email: dwinney@iu.edu
// ---------------------------------------------------------------------------
#ifndef _SUM_
#define _SUM_
#include "amplitudes/amplitude.hpp"
// ---------------------------------------------------------------------------
// The amplitude_sum class can take a vector of the above amplitude objects
// and add them together to get observables!
// ---------------------------------------------------------------------------
dwinney
committed
namespace jpacPhoto
dwinney
committed
class amplitude_sum : public amplitude
dwinney
committed
private:
// Store a vector of all the amplitudes you want to sum incoherently
dwinney
committed
public:
// Empty constructor
amplitude_sum(reaction_kinematics * xkinem, std::string identifer = "amplitude_sum")
dwinney
committed
{};
// Constructor with a vector already set up
amplitude_sum(reaction_kinematics * xkinem, std::vector<amplitude*> vec, std::string identifer = "amplitude_sum")
dwinney
committed
{};
// Add a new amplitude to the vector
void add_amplitude(amplitude * new_amp)
dwinney
committed
};
dwinney
committed
// Add all the members of an existing sum to a new sum
dwinney
committed
{
dwinney
committed
{
dwinney
committed
}
};
// empty allowedJP, leave the checks to the individual amps instead
inline std::vector<std::array<int,2>> allowedJP()
{
return {};
};
dwinney
committed
// TODO: Add a set_params which timesi in one vector and allocates approriaten number of
// params to each sub amplitude
dwinney
committed
// Evaluate the sum for given set of helicites, energy, and cos
std::complex<double> helicity_amplitude(std::array<int, 4> helicities, double s, double t);
dwinney
committed
};
};
#endif