# Category hadr-qgsm History

See `CONTRIBUTING.rst` for details of **required** info/format for each entry,
which **must** added in reverse chronological order (newest at the top).
It must **not** be used as a substitute for writing good git commit messages!

-------------------------------------------------------------------------------

## 2023-03-09 Vladimir Ivanchenko (hadr-qgsm-V11-01-01)
- G4BaryonSplitter, G4MesonSplitter, G4QGSMSplittableHadron, G4SPBaryon -
    attempt make code more uniform in order to reduce probability of warnings
    observed in CMS, when LTO option is enabled

## 2023-02-06 Gabriele Cosmo (hadr-qgsm-V11-01-00)
- Fixed potential uninitialised variables in G4QGSMSplitableHadron::GetValenceQuarkFlavors().

## 2022-10-07 Gabriele Cosmo (hadr-qgsm-V11-00-03)
- Fixed compilation warning on Intel/icx compiler for variables set
  but not used in G4QGSMSplitableHadron and G4QGSParticipants.

## 2022-05-06 Vladimir Ivanchenko (hadr-qgsm-V11-00-02)
- G4QGSParticipants - do not print warning in the case of precision loss;
    a confusing exception message was observed in CMS simulation, the problem
    happens in high energy gamma-nuclear interaction

## 2022-02-09 Gabriele Cosmo (hadr-qgsm-V11-00-01)
- Fixed compilation warning on Intel compilers for unused variables.

## 2021-12-10 Ben Morgan (hadr-qgsm-V11-00-00)
- Change to new Markdown History format.

---

# History entries prior to 11.0

13-Jul-2021 Alberto Ribon (hadr-qgsm-V10-07-02)
- G4QGSParticipants : improved initialization in the constructors,
  as suggested by Coverity.

16-Apr-2021 Ben Morgan (hadr-qgsm-V10-07-01)
- Migrate build to modular CMake API

13-Apr-2021 A. Ribon                     (hadr-qgsm-V10-07-00)
- GNUmakefile, sources.cmake : removed the subdirectories
  hadronic/models/management and hadronic/models/util
  (that have been now deleted, with their classes moved to
   hadronic/util and hadronic/management).
  Removed also the useless dependency to hadronic/process.

17-Oct-2020 V.Ivanchenko                 (hadr-qgsm-V10-06-06)
-  G4QGSParticipants - added protection for G4Exp (fixing outstanding
     precision lost in gamma+proton interactions)

28-Jul-2020 A. Ribon                     (hadr-qgsm-V10-06-05)
-  G4BaryonSplitter : removed inexisting in Geant4 excited hyperon states
   (Sigma* and Xi*).

24-Jul-2020 A. Ribon                     (hadr-qgsm-V10-06-04)
-  G4BaryonSplitter, G4SPBaryon : extension to charmed and bottom
   baryons and anti-baryons.
-  G4SingleDiffractiveExcitation, G4QGSDiffractiveExcitation,
   G4QuarkExchange : in the ExciteParticipants method of these classe,
   extension to charmed and bottom hadrons by assuming a minimum
   projectile diffractive mass equal to the PDG mass plus 250 MeV;
   in G4QuarkExchange, assumed also 50% for the probability of
   projectile diffraction.
-  G4Reggeons : in the constructor, replaced Omega_cc (PDG code 4432)
   with Omega_c (PDG code 4332); added comments.

06-Jul-2020 A. Ribon                     (hadr-qgsm-V10-06-03)
-  G4QGSParticipants : rolled back the change in the average
   transverse momentum of partons in a hadron.

10-Jun-2020 A. Ribon                     (hadr-qgsm-V10-06-02)
Two, unrelated changes made by Vladimir Uzhinsky :
-  G4QuarkExchange : improved treatment of antibaryon interactions in QGS.
   The reggeon exchanges are now treated as annihilation and creation of
   quark-antiquark pairs (to reflect in inelastic processes the non-vacuum
   reggeon exchanges present in antiparticle-particle elastic scattering
   amplitudes).
-  G4QGSParticipants : the average transverse momentum of partons
   in a hadron is set to zero (according to the study of transverse
   momentum distributions of hadrons produced in hadronic
   interactions, in particular the study of Xf - Pt correlations
   presented by the NA49 Collaboration).

08-Mar-2020 V.Ivanchenko                 (hadr-qgsm-V10-06-01)
-  G4QGSModel - clean-up: removed unused methods, delete
     operators, use C++11 keywords, moved icc implementation to src

16-Jan-2020 A. Ribon                     (hadr-qgsm-V10-06-00)
-  G4SPBaryonTable : changed the return type of the method 'length()' from
   'double' to 'size_t' (to avoid warnings seen on Windows).

19-Nov-2019 A. Ribon                     (hadr-qgsm-V10-05-02)
-  G4VAnnihilationCrossSection, G4AnnihilationCrossSection,
   G4GammaAnnCrossSection, G4ASCCrossSection, G4QGSMParameters :
   deleted unused classes.

24-Oct-2019 A. Ribon                     (hadr-qgsm-V10-05-01)
-  G4Reggeons: Vladimir Uzhinsky extension of the class for charmed and
   bottom hadrons following ideas of Grichine's implementation of
   Glauber-Gribov heavy hadron - nucleon cross sections.

02-Apr-2019 A. Ribon                     (hadr-qgsm-V10-05-00)
-  G4QGSParticipants : bug-fix (made by Vladimir Uzhinsky) in the
   computation of the transverse mass in the method
   G4QGSParticipants::DeterminePartonMomenta() .

20-Nov-2018 A. Ribon                     (hadr-qgsm-V10-04-08)
-  Minor clean-up and indentation: no changes in the random sequence.

05-Nov-2018 V. Uzhinsky                  (hadr-qgsm-V10-04-07)
-  Actions needed at bad situation in QGSM when it cannot generate strings
   are introduced. See "Uzhi Nov. 2018".

25-Oct-2018 V. Uzhinsky                  (hadr-qgsm-V10-04-06)
-  G4Reggeons.cc : Cross sections of K-meson - nucleon interactions are
   improved. Pomeron and 2 non-vacuum exchanges are accounted. Initial
   parameters for Kaons are taken from Kaidalov's paper (1976).

   Gamma-nucleon cross sections are improved due to simple tunning of
   parameters.

12-Oct-2018 A. Ribon                     (hadr-qgsm-V10-04-05)
-  G4Reggeons : Coverity fix of uninitialized variables.

05-Feb-2018 A. Ribon                     (hadr-qgsm-V10-04-04)
-  G4QGSParticipants : introduced protection against negative squared mass
   in method PutOnMassShell(), which was causing some rare crashes.
   If a negative squared mass occurs, a "JustWarning" exception is thrown
   and the squared mass is set to 0, before calling the square root (which
   is now computed only once).

18-Jan-2018 A. Ribon                     (hadr-qgsm-V10-04-03)
-  Proposing a new tag - although exactly the same as the previous one -
   after fixing the irreproducibility seen in gamma-nuclear (handled
   by QGS) with a tag in hadronization.

19-Dec-2017 V. Uzhinsky                  (hadr-qgsm-V10-04-02)
-  Improved QGSM.

19-Dec-2017 G. Cosmo                     (hadr-qgsm-V10-04-01)
- Fixed self-consistency in G4SPPartonInfo header (missing #include).
  Thanks to Raphael Isemann for reporting this.

07-Dec-2017 A. Ribon                     (hadr-qgsm-V10-04-00)
-  Brought back the development version of QGS
   (as it was in hadr-qgsm-V10-03-04).

26-Oct-2017 A. Ribon                     (hadr-qgsm-V10-03-05)
- Brought back the stable, production QGS (as in 10.3).

27-Jun-2017 G. Folger                    (hadr-qgsm-V10-03-04)
-  Fixed leak in G4QGSParticipants::GetList() for targets not deleted
   after interaction.

19-Jan-2017 A. Ribon                     (hadr-qgsm-V10-03-03)
-  Small fix in G4QGSParticipants to avoid a strange crash seen only
   in optimized mode (a 4-vector with negative square mass).

14-Dec-2016 A. Ribon                     (hadr-qgsm-V10-03-02)
-  After the release G4 10.3, with "stable" version, this tag brings back
   the "development" version, similar (although not identical because
   of some code clean-up and a bug fix included in the (internal) tag
   hadr-qgsm-V10-03-01, see below) to G4 10.2.ref10.

11-Nov-2016 V. Uzhinsky                  (hadr-qgsm-V10-03-01)
-  Bug is fixed in G4QGSParticipants with nucleon state counter (SetStatus(?)).

02-Nov-2016 A. Ribon                     (hadr-qgsm-V10-03-00)
-  Fixed warning message in G4QuarkExchange .

28-Oct-2016 A. Ribon                     (hadr-qgsm-V10-02-07)
-  Fixed warning message .

27-Oct-2016 A. Ribon                     (hadr-qgsm-V10-02-06)
-  Fixed trivial error in source.cmake .

27-Oct-2016 A. Ribon                     (hadr-qgsm-V10-02-05)
-  Fixed trivial error (forgotten deleted class) in source.cmake and
   G4QGSModel.

27 Oct. 2016 V. Uzhinsky                 (hadr-qgsm-V10-02-04)
-  Essential improvement of QGSM. ======
   First of all, Pomeron parameters were set up according to A. Kaidalov and M. Poghosyan (2009-2010).
   Non-vacuum reggeons - f and omega, were included in the calculations using parameters
   by A. Kaidalov and M. Poghosyan (2009-2010).
   New class G4Reggeons was created for calculations of X-sections.

   Cutted non-vacuum regeons are interpreted as a creation of a single string, or as
   a single string creation and one "stable" hadron. Such processes are described by
   RRR diagram of Reggeon phenomenology. For implementation of the processes, a new class -
   G4QuarkExchange, was created.

   Main changes are in G4QGSParticipants.cc.

   10-20 Implementation of Quark exchange simulation.
   7-9 Oct. Creation and testing G4Reggeons.
   6 Oct. Cleaned and improved G4SingleDiffractiveExcitation.cc and G4QGSDiffractiveExcitation.
   4 Oct. G4SingleDiffractiveExcitation.cc was corrected to treat h+N and Gamma + N diffraction.
   3 Oct. G4MesonSplitter prob. UUbar DDbar (0.5, 0.5) were changed to (0.8, 0.2) for gamma projectile.

19 Sept 2016 V. Uzhinsky                 (hadr-qgsm-V10-02-03)
-  Saving of the initial state of QGSM

18 May 2016 Alberto Ribon                (hadr-qgsm-V10-02-02)
-  G4PomeronCrossSection : added class originally in the management/
   directory.

14 April 2016 Alberto Ribon              (hadr-qgsm-V10-02-01)
   G4QGSMSplitableHadron : fixed bug in the case of gamma projectile
   with P_minus = 0.

04 December 2015 Alberto Ribon           (hadr-qgsm-V10-02-00)
   Resumed the tag hadr-qgsm-V10-01-14, i.e. the new QGS model.
   The files that are changed are: G4QGSDiffractiveExcitation.hh,
   G4QGSMSplitableHadron.hh, G4QGSModel.icc, G4QGSParticipants.hh,
   G4QGSMSplitableHadron.cc, G4GammaParticipants.cc, G4QGSParticipants.cc,
   G4SingleDiffractiveExcitation.cc, G4QGSDiffractiveExcitation.cc and
   G4SPBaryon.cc .

26 October 2015 Alberto Ribon            (hadr-qgsm-V10-01-16)
   After bringing the QGS string formation as it was in G4 10.1 (and before)
   in the previous tag, check of 'while' loops and deploy the
   fast math functions (G4Exp, G4Log and G4Pow).

23 October 2015 Alberto Ribon            (hadr-qgsm-V10-01-15)
   Reversed (temporarily, just for the coming release G4 10.2) the
   improvements made after 10.1.ref05, in such a way to leave the
   QGS string formation as it was in G4 10.1 (and before).
   The files that are changed are: G4QGSDiffractiveExcitation.hh,
   G4QGSMSplitableHadron.hh, G4QGSModel.icc, G4QGSParticipants.hh,
   G4QGSMSplitableHadron.cc, G4GammaParticipants.cc, G4QGSParticipants.cc,
   G4SingleDiffractiveExcitation.cc, G4QGSDiffractiveExcitation.cc and
   G4SPBaryon.cc .
   After the release G4 10.2, the tag hadr-qgsm-V10-01-14 will be resumed.

13 August 2015 Alberto Ribon             (hadr-qgsm-V10-01-14)
   G4GammaParticipants, G4QGSParticipants : Coverity fixes.

07 August 2015 Alberto Ribon             (hadr-qgsm-V10-01-13)
   G4QGSModel, G4QGSMSplitableHadron, G4GammaParticipants, G4QGSParticipants,
   G4SingleDiffractiveExcitation and G4QGSDiffractiveExcitation :
   checking of 'while' loops.

05 August 2015 Alberto Ribon             (hadr-qgsm-V10-01-12)
   G4ASCCrossSection, G4QGSMSplitableHadron, G4QGSParticipants,
   G4SingleDiffractiveExcitation and G4QGSDiffractiveExcitation:
   replaced std::exp, std::log and std::pow with the faster
   G4Exp, G4Log and G4Pow, respectively.
   This changes the random number sequence.

12 June 2015 Alberto Ribon               (hadr-qgsm-V10-01-11)
   G4QGSParticipants: fixed a memory leak.

10 June 2015 Alberto Ribon               (hadr-qgsm-V10-01-10)
   G4QGSParticipants: commented one forgotten debugging print out statement.

 4 June 2015 V. Uzhinsky                 (hadr-qgsm-V10-01-09)
   G4QGSMSplitableHadron - iterator deque used as data member is
   replaced by "unsigned int" data member. I hope it avoid segmentation
   fault.

28 May 2015 Alberto Ribon                (hadr-qgsm-V10-01-08)
   G4QGSParticipants : improved the kinematics treatment in the method
   SamplingNucleonKinematics.

27 May 2015 Vladimir Uzhinsky            (hadr-qgsm-V10-01-07)
   A bug lead to Segmentation fault is erased. It was connected with G4Nucleus -> GetNextNucleon()
   used at gamma projectile which gave pointer outside nucleon vector.
   After that wrong counting of see parton pairs was obtained, and at iteration of the partons
   GetNextParton went out of the parton vector.
   The changes are:
   G4VSplitableHadron* G4GammaParticipants::SelectInteractions

   theNucleus->StartLoop();
   G4Nucleon * pNucleon =0; // theNucleus->GetNextNucleon();   // Uzhi 27.05.2015

   while( (pNucleon = theNucleus->GetNextNucleon()) )
   ....

22 May 2015 Vladimir Uzhinsky            (hadr-qgsm-V10-01-06)
   A bug is fixed for gamma projectile. In G4QGSParticipants::BuildInteractions
   for gamma instead of GetList SelectInteractions(theProjectile) is called.

21 May 2015 Vladimir Uzhinsky            (hadr-qgsm-V10-01-05)
   Class G4GammaParticipants is adjusted to new QGSM.

20 May 2015 Vladimir Uzhinsky            (hadr-qgsm-V10-01-04)
   A bug is fixed in G4QGSParticipants for gamma projectile.

19 May 2015 Vladimir Uzhinsky            (hadr-qgsm-V10-01-03)
   To avoid double deletion erasing of TheInvolvedNucleonsOfTarget and
   TheInvolvedNucleonsOfProjectile was closed in G4QGSParticipants::~G4QGSParticipants().

15 May 2015 Vladimir Uzhinsky            (hadr-qgsm-V10-01-02)
   A bug was erased in G4SPBaryon.cc: setting of Delta0 isobar splitting
   into quark and diquark was wring.

   Energy-momentum conservation was improved, especially in the case when
   diffraction interactions happend.

12 May 2015 Vladimir Uzhinsky            (hadr-qgsm-V10-01-01)
   Bug is erased with double delition of splitable hadrons.

30 April 2015 Vladimir Uzhinsky           (hadr-qgsm-V10-01-00)
-  Essential improvement of QGSM:
     Reggeon cascading was implemented.
     "Fermi motion" connected with the reggeon cascading was implemented.
     New algorithm of parton kinematical properties determination was implemented.
     Calculation of residual nucleus properties was implemented.
   Most of the changes were made in G4QGSParticipants.cc

02 May 2013 Alberto Ribon       (hadr-qgsm-V09-06-00)
--------------------------------------------------
-  For thread safety, replaced CLHEP::RandFlat with G4RandFlat in
   G4QGSMSplitableHadron.cc.

20 November 2012 V. Uzhinsky    (hadr-qgsm-V09-05-04)
--------------------------------------------------
-  An interface for a manipulation with nucleus-nucleus interactions was
   introduced, especially for treating remnants of projectile nuclei.

27 September 2012, Gabriele Cosmo
--------------------------------------------------
- Explicitly use inclusion of headers for system of units and physical
  constants, in plan to remove implicit inclusion from globals.hh.

17 June 2012, Gunter Folger     (hadr-qgsm-V09-05-03)
--------------------------------------------------
- Fixes for coverity in G4QGSModel concerning copy ctor and operator = .

12 June 2012, Gunter Folger     (hadr-qgsm-V09-05-02)
--------------------------------------------------
- Correct shadowing warnings

31 May 2012, Gunter Folger      (hadr-qgsm-V09-05-01)
--------------------------------------------------
- Improve indentation;
- make copy ctor, =, ==, != operators private without implementation

25 May 2012, Gunter Folger      (hadr-qgsm-V09-05-00)
--------------------------------------------------
-  Add ModelDescription() to QGS

5 Aug 2011, M. Kelsey		(hadr-qgsm-V09-04-04)
-----------------------------------------------------
- G4GammaParticipants.cc:  Follow change in return value of
   G4V3DNucleus::GetNucleons(), use const_cast<> to allow setting Hit().
- G4QGSParticipants.hh:  Add G4V3DNucleus.hh (should move implementations to
   .cc file).

  Requires consistent changes in other packages:
  	hadr-modman-V09-04-01
  	hadr-mod-util-V09-04-02
	had-partonstring-mgt-V09-04-01
  	hadr-qgsm-V09-04-04
  	had-theo-HE-V09-04-01

14 Jul 2011, G.Folger		(hadr-qgsm-V09-04-03)
-----------------------------------------------------
- Fix coverity warnings in G4QGSParticipants.cc and G4SPBaryon.cc
    (none was a real problem)

01 Jun 2011, G.Folger		(hadr-qgsm-V09-04-02)
-----------------------------------------------------
- G4QGSParticipants: reduce energy of participant nucleons by binding energy.
   This increases excitation energy, as calculated by initial-final. Without
   this, excitation E often is close to 0, or negative.

01 Jun 2011, G.Folger		(hadr-qgsm-V09-04-01)
-----------------------------------------------------
-  Fix compilation warnings, gcc4.6, on alost unused variables. Move
    "debug" variables into #ifdef

17 Mar 2011, G.Folger		(hadr-qgsm-V09-04-00)
-----------------------------------------------------
-  set limits for E/p checking

8 Sep 2010, G.Folger		(hadr-qgsm-V09-03-01)
-----------------------------------------------------
- G4QGSModel.icc: use integer (A,Z) interface of nucleus

12-Mar-2010, G.Folger		(hadr-qgsm-V09-03-00)
-  remove G4PartonStringAnnihilator.{hh,cc} not used anywhere

19 May 2009, G.Folger		(hadr-qgsm-V09-02-02)
-----------------------------------------------------
- fix in G4SPBaryon: for antibaryon, a  diquark & quark was given instead of
      anti-diquark & antiquark; note the reverse order, too.
    Fixes problems with incident anti baryons, e.g. antiproton, manifesting
    in problems with forming hadrons.

29 Apr 2009 m. Kosov       (hadr-qgsm-V09-02-01)
------------------------------------------------
Very important bug fix in G4QGSParticipants.cc to let QGSC working from E=0
Added by GF (19-May-09):
- this very important "bug" fix modifies G4G4QGSParticipants.cc and
   G4GammaParticipants.cc:
     changing the value of Threshold from 0.45 GeV to 0.GeV,
     and disables an Exception if s < sqr(total mass + Threshold)

15 Sep 2008 G.Folger       (hadr-qgsm-V09-01-01)
------------------------------------------------
- Fix for bug found on windows in G4QGSParticipants.cc, bug 1018:
   decrement of iterator fails, improve logic to not decrement.

31 Mar 2008 Dennis Wright (hadr-qgsm-V09-01-00)
-----------------------------------------------
-  fix gcc-4.3 compiler warnings at lines 293, 395 of G4QGSMSplittableHadron.cc

24 Apr 2007 Gunter Folger  (hadr-qgsm-V08-02-02)
------------------------------------------------
-  merge in change done by ftf dev; ie. in G4QGSParticipants, theDiffExcitaton
   is constructed with default arguments.

25 Jan 2007 Gunter Folger  (hadr-qgsm-V08-02-01)
------------------------------------------------
- G4SoftStringBuilder.cc: Correct typo in #ifdef

24 Jan 2007 Gunter Folger  (hadr-qgsm-V08-02-00)
------------------------------------------------
-  Correct E-p non-conservation in QGS. In 4QGSMSplitableHadron.cc the smaller
   of the lightcone momenta Q+/Q- was ignored.
-  G4QGSMSplitableHadron correct divide by 0 in SampleX()
-  Add debugging output to several classes

30 Nov 2005 Gabriele Cosmo (hadr-qgsm-V07-01-00)
-----------------------------------------------
- Trivial fix in G4QGSParticipants and for support of CLHEP-2.0.X series.
- Created History file.
