TABLE OF CONTENTS
- 1. /densitymodule
- 1.1. densitymodule/densitySwitch
- 1.2. densitymodule/linearInterpolation
- 1.3. densitymodule/gridSize
- 1.4. densitymodule/gridPoints
- 1.5. densitymodule/gridSpacing
- 1.6. densitymodule/densityInput_proton
- 1.7. densitymodule/densityInput_neutron
- 1.8. densitymodule/setnewsmearing
- 1.9. densitymodule/newsmearing
- 1.10. densitymodule/nLargePoints
- 1.11. densitymodule/DiracMass
- 1.12. densitymodule/getGridIndex
- 1.13. densitymodule/getFieldRMF
- 1.14. densitymodule/energyDeterminationRMF
- 1.15. densitymodule/SelfEnergy_scalar
- 1.16. densitymodule/init
- 1.17. densitymodule/initDensity
- 1.18. densitymodule/acceptGrid
- 1.19. densitymodule/getBaryonDensity
- 1.20. densitymodule/densityAt
- 1.21. densitymodule/updateDensity
- 1.21.1. updateDensity/initDensityWeights
- 1.21.2. updateDensity/FillStaticDensity
- 1.21.3. updateDensity/updateDensityBox
- 1.22. densitymodule/storeFieldsRMF
- 1.23. densitymodule/updateRMF
- 1.24. densitymodule/TensorRMF
- 1.25. densitymodule/TensorRMF_fields
- 1.26. densitymodule/TotalEnergyRMF
- 1.27. densitymodule/Particle4MomentumRMF
- 1.28. densitymodule/true4MomentumRMF
- 1.29. densitymodule/SelfEnergy_vector
- 1.30. densitymodule/SelfEnergy_vector_old
- 1.31. densitymodule/getDensitySwitch
- 1.32. densitymodule/getGridSpacing0
- 1.33. densitymodule/getGridSpacing
- 1.34. densitymodule/getGridPoints
- 1.35. densitymodule/boostToLRF
- 1.36. densitymodule/fermiMomentum_sym
- 1.37. densitymodule/fermiMomentum_noIsospin
- 1.38. densitymodule/FermiMomAt
- 1.39. densitymodule/writeDensityPlane
- 1.40. densitymodule/set_pF_Box
- 1.41. densitymodule/distMomBox
/densitymodule [ Modules ]
NAME
module densitymodule
PURPOSE
Administrates the calculation of the density.
densitymodule/densitySwitch [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
integer, save :: densitySwitch=1
PURPOSE
This switch decides whether the density is static or dynamic during the run. ("Static" makes sense only for fixed target scenarios!)
One can use a static density if the nucleus stays roughly in its ground state during the collision.
possible values:
- 0: Density is set to 0.
- 1: Dynamic density according to test-particle distribution.
- 2: Static density (not for heavy-ion collisions).
- 3: Resting matter: Density is given by the two input parameters "densityInput_neutron" and "densityInput_proton".
- 4: Dynamic density in a box. Assumes the same density everywhere, but also calculates the momentum distribution
densitymodule/linearInterpolation [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
logical, save :: linearInterpolation = .true.
PURPOSE
If this switch is 'true', then the dynamic-density mode uses linear interpolation to determine the density in between the gridpoints.
densitymodule/gridSize [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
real, dimension(1:3), save, public :: gridSize = (/12.,12.,12./)
PURPOSE
Size of density grid in fm.
densitymodule/gridPoints [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
integer, dimension(1:3), save, public :: gridPoints = (/30,30,30/)
PURPOSE
Number of gridpoints in each space direction.
densitymodule/gridSpacing [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
real, dimension(1:3), save, public :: gridSpacing = 1.
PURPOSE
Spacing of the grid in each dimension, determined by gridSize/gridPoints.
densitymodule/densityInput_proton [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
real, save :: densityInput_proton=0.084
PURPOSE
Assumed proton density if densitySwitch=3
densitymodule/densityInput_neutron [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
real, save :: densityInput_neutron=0.084
PURPOSE
Assumed neutron density if densitySwitch=3
densitymodule/setnewsmearing [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
logical, save :: setnewsmearing=.false.
PURPOSE
Readjust the smearing to a different width if .true.
densitymodule/newsmearing [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
real, save :: newsmearing=1.
PURPOSE
Use a smearing width as in a grid wtih newsmearing times the gridspacing
densitymodule/nLargePoints [ Global module-variables ]
[ Top ] [ densitymodule ] [ Global module-variables ]
SOURCE
integer, save, public :: nLargePoints=2
PURPOSE
Number of points which are considered to the left and right to smear density on
densitymodule/DiracMass [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
real function DiracMass(Part) real function DiracMass(i1,i2,i3,barMass,id,charge,antiFlag)
PURPOSE
calculates the effective (Dirac) mass of a particle
INPUTS
- type(particle) :: Part
or:
- integer :: i1,i2,i3 -- index in spatial grid
- real :: barMass -- bare mass of the particle
- logical :: antiFlag -- antiparticle
OUTPUT
returns m^* = m + S
NOTES
returns m^* = m, if particle outside of grid or wrong particle id
densitymodule/getGridIndex [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
logical function getGridIndex(pos,index) logical function getGridIndex(pos,index,add) logical function getGridIndex(pos,index,iSmall,small)
PURPOSE
Returns .false. if the point is outside the grid (then 'index' is invalid). 'index' is the index of the corresponding coordinate. It is even calculated if the vale '.false.' is returned. Then the validity of the results has to be checked elsewhere.
One may use the optional parameter 'add' to shift the test according being inside by a number of bins.
The third variant also calculates the index for a 'small' grid
INPUTS
- real, dimension(1:3) :: pos
- integer, optional :: add
OUTPUT
- integer, dimension(1:3) :: index
- integer, dimension(1:3) :: iSmall
- integer, optional :: small
- return value signaling "inside the grid"
NOTES
- The first tests according the real grid size is necessary, since it may give integer overfloats, if one only checks the integer values.
- Usually, we do not need the output of iSmall directly, but only small- The interface policy does not allow a distinction between 'add' and 'small', so we add the redundant 'iSmall' to the function interface.
densitymodule/getFieldRMF [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine getFieldRMF(pos, sigma,omega,rho) subroutine getFieldRMF(ix,iy,iz, sigma,omega,rho)
PURPOSE
return the value of some fileds at the given position
INPUTS
OUTPUT
- real, OPTIONAL :: sigma :: value of sigma field
- real, dimension(0:3), OPTIONAL :: omega :: value of omega field
- real, dimension(0:3), OPTIONAL :: rho :: value of rho field
NOTES
- if index is given as coordinates, no check whether inside/outside is performed
densitymodule/energyDeterminationRMF [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine energyDeterminationRMF(Part) subroutine energyDeterminationRMF(Parts)
PURPOSE
This subroutine determines the one-particle energy E^*, which is the zeroth component of the kinetic four-momentum in the frame, where the space components of the kinetic four-momentum are given.
INPUTS
- type(particle),intent(inOut) :: Part -- Particle whose energy should be calculated.
or:
- type((particle),dimension(:,:),intent(inOut) :: Parts -- Particles whose energy should be calculated.
NOTES
Should be used in RMF-mode. Please note, that not the full single-particle energy is computed here. The vector field contribution is missed in E^*.
densitymodule/SelfEnergy_scalar [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
real function SelfEnergy_scalar(Part) real function SelfEnergy_scalar(i1,i2,i3,id,antiFlag)
PURPOSE
calculates the scalar component of the RMF selfenergy of a particle
INPUTS
- type(particle) :: Part
or:
- integer :: i1,i2,i3 -- index in the grid
- integer :: id -- id of the particle
- logical :: antiFlag -- antiparticle or not
NOTES
- for kaons selfenergy_scalar includes the Sigma_KN term only!
- gs_kaon = Sigma_KN / f_pi^2
densitymodule/init [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine init
PURPOSE
read the namelist, initalize (parts of) the module
densitymodule/initDensity [ Namelists ]
[ Top ] [ densitymodule ] [ Namelists ]
NAME
NAMELIST /initDensity/
PURPOSE
Includes the input switches and variables:
- densitySwitch
- linearInterpolation
- densityInput_proton
- densityInput_neutron
- gridSize
- gridPoints
- setnewsmearing
- newsmearing
- nLargePoints
densitymodule/acceptGrid [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine acceptGrid(GridSpacing_x,GridSpacing_y,GridSpacing_z)
PURPOSE
Accepts the grid spacings and recalculates the numbers of points in each direction. Needed for relativistic HIC, when initial nuclei are Lorentz-contracted. Called from the module initHeavyIon.
densitymodule/getBaryonDensity [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
real function getBaryonDensity(pos)
PURPOSE
Evaluate the baryon density at a certain position.
densitymodule/densityAt [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
type(dichte) function densityAt(r)
PURPOSE
Evaluate density at some space-point r.
INPUTS
- real, dimension(1:3) :: r --- position where density should be calculated
densitymodule/updateDensity [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
subroutine updateDensity(parts)
PURPOSE
Updates the vector densField which is used by densityAt and stores the density of the testparticles.
INPUTS
- type(particle), dimension(:,:) :: parts
NOTE This routine does not gets faster when using OpenMP.
updateDensity/initDensityWeights [ Functions ]
[ Top ] [ updateDensity ] [ Functions ]
NAME
subroutine initDensityWeights
PURPOSE
- Initializes weights which are used to evaluate the densities at the gridpoints.
- Each particle has some coordinate off the gridpoints. Therefore it is needed to define weights which tell how much a particle at position r contributes to the ith grid point. The particle are smeared with a gaussian distribution.
- The width is chosen such that it is equal to the maximum of the gridspacings.
INPUTS
- type(particle) Parts(:,:)
USES
- idTable, particleDefinition
updateDensity/FillStaticDensity [ Functions ]
[ Top ] [ updateDensity ] [ Functions ]
NAME
subroutine FillStaticDensity
PURPOSE
In the case of static density, this fills the fields densField and totalDens with values of the density parametrization. Needed in the case of RMF calculations and also for Coulomb potential.
updateDensity/updateDensityBox [ Functions ]
[ Top ] [ updateDensity ] [ Functions ]
NAME
subroutine updateDensityBox
PURPOSE
This updates the density in a box dynamically. It also calculates the momentum distribution
densitymodule/storeFieldsRMF [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine storeFieldsRMF
PURPOSE
Store the old values of the omega, rho and density fields.
densitymodule/updateRMF [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine updateRMF(Parts,doInit)
PURPOSE
Updates the sigma, omega and rho fields needed when the propagation with the RMF is done. Updates also the baryon velocities, which are needed in the subsequent updating of the baryon 4-current by the subroutine updateDensity.
INPUTS
- type(particle), dimension(:,:) :: Parts
- logical, optional :: doInit
NOTES
The scalarDens is computed as well.
densitymodule/TensorRMF [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine TensorRMF(Parts)
PURPOSE
Calculates the energy-momentum tensor and the four-momentum density fields.
INPUTS
NOTES
Applicable in RMF mode (both Walecka and PDM).
densitymodule/TensorRMF_fields [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
function TensorRMF_fields
PURPOSE
Calculates the fields contribution Tens_fields(0:3,0:3) to the energy-momentum tensor at the grid point specified by the indices I1,I2,I3.
NOTES
Applicable in RMF mode (both Walecka and PDM).
densitymodule/TotalEnergyRMF [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine TotalEnergyRMF
PURPOSE
Calculates the total energy of the system (w/o Coulomb part).
INPUTS
OUTPUT
- real :: Etot ! total energy (GeV)
NOTES
Applicable in RMF mode (both Walecka and PDM).
densitymodule/Particle4MomentumRMF [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
function Particle4MomentumRMF(Part) result(momentum)
PURPOSE
This subroutine determines the canonical four-momentum in computational frame (i.e. where mesonic mean fields are given).
INPUTS
- type(particle),intent(in) :: Part --- Particle
OUTPUT
NOTES
Should be used in RMF-mode. It is supposed, that the kinetic four-momentum of the particle is already determined by the subroutine energyDeterminationRMF earlier.
Electromagnetic part is not included.
densitymodule/true4MomentumRMF [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
function true4MomentumRMF(Part,inside_grid_flag) result(momentum)
PURPOSE
This subroutine determines the "true" single-particle 4-momentum, i.e. the 4-momentum which is additive to produce the total 4-momentum of the system in the computational frame.
INPUTS
OUTPUT
- real, dimension(0:3) :: momentum --- "true" 4-momentum of the particle
- logical, optional :: inside_grid_flag --- .true. if the particle is inside grid, .false. otherwise
NOTES
- Should be used in RMF-mode. The input particle kinetic 4-momentum must be given in the computational frame (where the density field is defined).
- Formula for the fieldenergy updated; gradient terms replaced the corresponding sources using the meson-field equations and partial integrations.
densitymodule/SelfEnergy_vector [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
real function SelfEnergy_vector(i1,i2,i3,k,id,charge,antiFlag)
PURPOSE
calculates the vector component of the RMF selfenergy of a particle
INPUTS
- integer :: i1,i2,i3 -- index in the grid
- integer :: k -- component of the vector (0..3)
- integer :: id -- id of the particle
- integer :: charge -- charge of the particle
- logical :: antiFlag -- antiparticle or not
NOTES
- gv_kaon = 3/(8 * f_pi*^2)
densitymodule/SelfEnergy_vector_old [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
real function SelfEnergy_vector_old(i1,i2,i3,k,id,charge,antiFlag)
PURPOSE
calculates the vector component of the RMF selfenergy of a particle from the previous time step; needed for time derivatives in propagation_RMF
INPUTS
- integer :: i1,i2,i3 -- index in the grid
- integer :: k -- component of the vector (0..3)
- integer :: id -- id of the particle
- integer :: charge -- charge of the particle
- logical :: antiFlag -- antiparticle or not
NOTES
- gv_kaon = 3/(8 * f_pi*^2)
densitymodule/getDensitySwitch [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
function getDensitySwitch()
PURPOSE
If not yet done, reads input from jobcard and then returns densitySwitch.
densitymodule/getGridSpacing0 [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
function getGridSpacing0()
PURPOSE
returns gridSpacing
RESULT
real, dimension(1:3) :: gridSpacing -- in units of fermi
densitymodule/getGridSpacing [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
function getGridSpacing()
PURPOSE
returns gridSpacing, but rescaled when linear interpolation is used. This is used for calculating derivatives.
RESULT
real, dimension(1:3) :: gridSpacing -- in units of fermi
densitymodule/getGridPoints [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
function getGridPoints()
PURPOSE
returns GridPoints
RESULT
integer, dimension(1:3) :: gridPoints -- numbers
densitymodule/boostToLRF [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine boostToLRF(Part, switch, density)
PURPOSE
Boosts particle between "Local Rest Frame (LRF)" and "calculation frame (CF)".
INPUTS
- type(particle), intent(inout) :: Part ! Particle to be boosted
- integer, intent(in) :: switch ! 1= boost from CF to LRF ! 2= boost from LRF to CF
NOTES
- The LRF is the frame in which the baryon current vanishes.
- If the density is very small, then no boost takes place.
- This boost may not work in RMF mode, since %baryon(0) may vanish, even if the vector components are non-zero. (In RMF mode this boost should not be necessary anyway.)
densitymodule/fermiMomentum_sym [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
real function fermiMomentum_sym(rho)
PURPOSE
Evaluate the fermi momentum for symmetric nuclear matter. Assumption: rho_p=rho_n !!!
INPUTS
- real :: rho ! density in fm^-3
RESULT
- Fermi momentum in GeV
densitymodule/fermiMomentum_noIsospin [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
real function fermiMomentum_noIsospin(rho)
PURPOSE
Evaluate the fermi momentum for a gas of fermions.
INPUTS
- real :: rho ! density in fm^-3 ATTENTION: Do not use rho(nucleon) but rho(proton) or rho(neutron)
RESULT
- Fermi momentum in GeV
densitymodule/FermiMomAt [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
real function FermiMomAt(pos,charge)
PURPOSE
calculate the fermi momentum at some position. If no charge is given it uses the averaged proton/neutron densities, otherwise it uses the corresponding isospin channel
INPUTS
- real, dimension(1:3) :: pos -- the space coordinates
- integer, OPTIONAL :: charge -- the isospin channel
densitymodule/writeDensityPlane [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine writeDensityPlane(fName,iPlane)
PURPOSE
Write the density to a file as cuts according some planes
INPUTS
- character*(*) :: fName -- name of file to write to
- integer :: iPlane -- selection of plane to write (see below)
possible values for iPlane:
- 1: yz-plane (through origin) aka x = 0
- 2: xz-plane (through origin) aka y = 0
- 3: xy-plane (through origin) aka z = 0
densitymodule/set_pF_Box [ Subroutines ]
[ Top ] [ densitymodule ] [ Subroutines ]
NAME
subroutine set_pF_Box(pF)
PURPOSE
set the internal values pF_Box.
These values are only used for adjusting the binning of the momentum distribution for densitySwitch=4
densitymodule/distMomBox [ Functions ]
[ Top ] [ densitymodule ] [ Functions ]
NAME
real function distMomBox(mom,charge)
PURPOSE
return the value of the distribution function for given momentum and charge of the nucleon