16#include "TSortedList.h"
31 TNucleus(
int charge,
int neutrons,
double mass,
const char* symbol);
32 TNucleus(
int charge,
int neutrons,
const char* MassFile =
nullptr);
40 static
void ParseName(const
char* name, std::
string& symbol,
int& number, std::
string& element)
42 return ParseName(std::string(name), symbol, number, element);
44 static void ParseName(std::string name, std::string& symbol,
int& number, std::string& element);
47 std::string tmp(input);
50 static std::string
SortName(std::string input);
58 void AddTransition(Double_t energy, Double_t intensity, Double_t energy_uncertainty = 0.0, Double_t intensity_uncertainty = 0.0);
81 void Print(Option_t* opt =
"")
const override;
93 void SetName(
const char* name =
"")
override;
int GetZ() const
Gets the Z (# of protons) of the nucleus.
void SetMass()
Sets the mass based on the A and mass excess of nucleus (in MeV)
TSortedList fTransitionListByIntensity
int GetA() const
Gets the A (Z + N) of the nucleus.
void SetName(const char *name="") override
double fMassExcess
Mass excess (in MeV)
Int_t NTransitions() const
void SetZ(int)
Sets the Z (# of protons) of the nucleus.
void AddTransition(Double_t energy, Double_t intensity, Double_t energy_uncertainty=0.0, Double_t intensity_uncertainty=0.0)
TTransition * GetTransitionByIntensity(Int_t idx)
void Print(Option_t *opt="") const override
double fMass
Mass (in MeV)
TNucleus()=default
Should not be used, here so we can write things to a root file.
double GetEnergyFromBeta(double beta) const
const TSortedList * GetTransitionListByEnergy() const
bool LoadTransitionFile()
bool operator==(const TNucleus &rhs) const
double GetBetaFromEnergy(double energy_MeV) const
int GetN() const
Gets the N (# of neutrons) of the nucleus.
int fN
Number of neutrons (N)
TNucleus(const TNucleus &)=delete
int fZ
Number of protons (Z)
void SetN(int)
Sets the N (# of neutrons) of the nucleus.
const TSortedList * GetTransitionListByIntensity() const
void SetSymbol(const char *)
Sets the atomic symbol for the nucleus.
Int_t GetNTransitions() const
TTransition * GetTransitionByEnergy(Int_t idx)
double GetMass() const
Gets the mass of the nucleus (in MeV)
static std::string & Massfile()
Returns the massfile to be used, which includes Z, N, atomic symbol, and mass excess.
static void ParseName(const char *name, std::string &symbol, int &number, std::string &element)
TNucleus(TNucleus &&) noexcept=delete
void WriteSourceFile(const std::string &outfilename="")
static std::string SortName(const char *input)
int fA
Number of nucleons (Z + N)
TTransition * GetTransition(Int_t idx)
const TSortedList * GetTransitionList() const
TSortedList fTransitionListByEnergy
double GetMassExcess() const
Gets the mass excess of the nucleus (in MeV)
void SetMassExcess(double)
Sets the mass excess of the nucleus (in MeV)
std::string fSymbol
Atomic symbol (ex. Ba, C, O, N)
const char * GetSymbol() const
Gets the atomic symbol of the nucleus.
bool operator!=(const TNucleus &rhs) const
int GetZfromSymbol(char *)