TABLE OF CONTENTS
- 1. /energyCalc
- 1.1. energyCalc/accuracy
- 1.2. energyCalc/updateEnergies
- 1.3. energyCalc/energyDetermination
- 1.3.1. energyDetermination/MesonHistFailures
- 1.3.2. energyDetermination/vary_mass_offshell
- 1.3.3. energyDetermination/newton
- 1.3.4. energyDetermination/bisection
- 1.3.5. energyDetermination/plot_f
- 1.3.6. energyDetermination/errorMessage
- 1.3.7. energyDetermination/m_eff_sqr
- 1.4. energyCalc/energyCorrection
- 1.4.1. energyCorrection/setFinalState
- 1.4.2. energyCorrection/deltaSrts
/energyCalc [ Modules ]
NAME
module energyCalc
PURPOSE
Incorporates routines to evaluate the one-particle energy of a given particle and a routine for making a so called energy correction to a given final state.
energyCalc/accuracy [ Global module-variables ]
[ Top ] [ energyCalc ] [ Global module-variables ]
PURPOSE
Determines accuracy of energy determination in the determination of the one particle energy. Units : GeV.
SOURCE
real, parameter :: accuracy=0.0005
energyCalc/updateEnergies [ Subroutines ]
[ Top ] [ energyCalc ] [ Subroutines ]
NAME
subroutine updateEnergies(part,check_in)
PURPOSE
Routine updates energies of the particles
INPUTS
- type(particle), dimension(:) :: part -- particle array
- logical, OPTIONAL :: check_in -- flag for 'energyDetermination'
OUTPUT
energyCalc/energyDetermination [ Subroutines ]
[ Top ] [ energyCalc ] [ Subroutines ]
NAME
subroutine energyDetermination(part,betaToCF,countMax,error_out, check,warn,ForbidCoulomb,skipTestE0)
PURPOSE
This subroutine determines the one-particle energy E with a momentum-dependent scalar potential that is defined in the local rest frame.
NOTES
- We keep p(1:3) and m constant.
- To solve: p**2=E**2-p(1:3)**2=(m+s(E))**2
- The scalar potential s is only defined in the LRF.
- First we try to find the solution f(E)=0 via a the newton method, f(E)=m_eff**2-p**2=m_eff**2+p(1:3)**2-E**2 with m_eff=m+s(E) by the iteration E(i+2)=E(i+1)-f(i+1)*(E(i+1)-E(i))/(f(i+1)-f(i)).
- If the newton method fails, we try it again via a bisection method
- At the end, the Coulomb potential is added.
INPUTS
- type(particle) :: part -- Particle to be considered.
- real,dimension (1:3), OPTIONAL :: betaToCF -- Velocity of "Calculation Frame" in the frame where the particle's momentum is defined.
- integer, OPTIONAL :: countMax -- maximal number of cycles to find a solution (default=10000)
- logical, OPTIONAL :: check -- check for energy conservation (Default: .false.)
- logical, OPTIONAL :: warn -- if true, a warning message is issued, if the incomming momentum is too large (otherwise, this is skipped silently). (Default: .true.)
- logical, OPTIONAL :: ForbidCoulomb -- if true, the Coulomb potential is NOT added to p0 (needed by 'propagate', where the coulomb force is treated seperately) (Default: .false.)
- logical, OPTIONAL :: skipTestE0 -- if true, the input value of E will not be tested to be a already a good solution
- logical, OPTIONAL :: verbose -- if false, be totally quiet
OUTPUT
- type(particle) :: part
- real, OPTIONAL :: error_out -- approximate error of E = sqrt(f(e))
- real, OPTIONAL :: flagOK -- .true., if success
energyDetermination/MesonHistFailures [ Subroutines ]
[ Top ] [ energyDetermination ] [ Subroutines ]
NAME
subroutine MesonHistFailures(iTyp)
PURPOSE
Do statistics of failures connected with mesons and off-shellness
energyDetermination/vary_mass_offshell [ Functions ]
[ Top ] [ energyDetermination ] [ Functions ]
NAME
logical function vary_mass_offshell()
PURPOSE
Try maximizing p_0 such that equation is still fulfilled
energyDetermination/newton [ Functions ]
[ Top ] [ energyDetermination ] [ Functions ]
NAME
logical function newton()
PURPOSE
solve f(E)=0 by Newton Method
energyDetermination/bisection [ Functions ]
[ Top ] [ energyDetermination ] [ Functions ]
NAME
logical function bisection(E1,E2)
PURPOSE
solve f(E)=0 by Bisection Method
energyDetermination/plot_f [ Subroutines ]
[ Top ] [ energyDetermination ] [ Subroutines ]
NAME
subroutine plot_f(part_in)
PURPOSE
This subroutine plots the function
m_eff**2(part,ener)-(Energy**2-Sum(p**2)) as a
function of energy. Zoomes into the region where the function is zero. Useful for debugging!!
energyDetermination/errorMessage [ Subroutines ]
[ Top ] [ energyDetermination ] [ Subroutines ]
NAME
subroutine errorMessage
PURPOSE
Print some info about particle
energyDetermination/m_eff_sqr [ Functions ]
[ Top ] [ energyDetermination ] [ Functions ]
NAME
real function m_eff_sqr(partIN,density,enerOut)
PURPOSE
Evaluate m_eff**2=(m+S)**2 of a given particle by boosting to the LRF-Frame, where S is the scalar potential.
energyCalc/energyCorrection [ Subroutines ]
[ Top ] [ energyCalc ] [ Subroutines ]
NAME
subroutine energyCorrection(srqts, betaToCM, finalState, successFlag, potentialFailure, verbose)
PURPOSE
Gets the finalState particles with vacuum kinematics in the CM Frame. Also the real srts of the final state is handed over to the routine. Then this routine tries to solve energy and momentum conservation by the ansatz described in the cross section documentation. . Therefore it evaluates the scaling factor "x" which is used to scale the CM-momenta of the final states. This is done by a Regula-Falsi-Method. We search of a zero of the function "deltaSrts" which depends on this scaling factor x.
IMPORTANT : Output are the final state particles in the calculation frame!
INPUTS
- real, intent(in) :: srtS
- real, intent(in), dimension(1:3) :: betaToCM -- velocity of CM frame in calculation frame
- type(particle), dimension(:), intent(INOUT) :: finalState -- in CM frame
- logical, OPTIONAL :: verbose -- flag print messages on/off (default: on)
OUTPUT
- type(particle), dimension(:), intent(INOUT) :: finalState -- in calc frame
- logical, intent(out) :: successFlag
- logical, optional :: potentialFailure -- .true. if it fails due to neglecting perturbative potentials
NOTES
If the iteration fails, successFlag is set to .false. as output.
Now is used also in the RMF mode (only function deltaSrts is modified).
energyCorrection/setFinalState [ Subroutines ]
[ Top ] [ energyCorrection ] [ Subroutines ]
NAME
subroutine setFinalState
PURPOSE
boost the particles and set them into 'finalState'
energyCorrection/deltaSrts [ Functions ]
[ Top ] [ energyCorrection ] [ Functions ]
NAME
real function deltaSrts(x)
PURPOSE
Evaluates sqrt(s)-Sum(Energies in CM frame). This value is the size of the energy non-conservation. The sum depends on the scaling factor for the three momenta