WARNING! Obsolete version!
The changes incorporated in VIKAR 4.2 reflect debugging efforts resulting from reported segmentation faults, and the addition of code to deal with stopping targets which were not previously considered. Improved control of bad simulations, and debugging capacity is included. The functional improvements are:
Capacity to model stopping targets
Output plot of ejectile angle vs recoil angle
More sophisticated debugging variables
Exit clause to stop never-ending simulations (exits if detection efficiency is below 0.1% after 10000 events simulated)
Updated product_proc to version 1.4 to reflect correct energy variable being passed to E_straggle (to fix seg faults), add debugging variables
Updated energy loss calculations for jet targets
Fixed energy loss calculations for upstream target backing
Applied check if beam stops in upstream target backing
Applied check to determine if reactions are energetically possible
Updated cart2sphere to version 1.1 to fix minor bug if x = y = 0
Updated kindeux to version 3.1 to include debugging output
Updated new_resolution_cyl to version 1.1 to correct for energy bug when incomplete_Q
Updated new_resolution_plan to version 1.1 to correct for energy bug when incomplete_Q
Details of file changes are documented below.
1) Stopping targets are now modelled. Previously, the interaction depth in the target was selected randomly across the entire target thickness (appropriate for transmission targets). Now, the code determines whether the beam stops in the target, and if so, the interaction point is now selected randomly along the range of the beam in the target.
2) VIKAR 4.2 checks if the energy at the reaction point is above threshold for the reaction entered, avoiding simulating energetically-impossible reactions (important for stopping targets, and operator error).
3) Improved debugging modes are added, affecting output to terminal. The debugging variable can be set to:
0 - Silent, except simulation time and efficiency reporting
1 - Basic reporting of suspect events, such as stuck particles or double hits
2 - Event dump mode (forces full level-9 debugging, followed by code halt, for a
specific event number as appended on extra line at end of input file)
8 - Full event-by-event reporting to terminal of parameters in VIKAR only
9 - Full event-by-event reporting to terminal of parameters in VIKAR, and
in subroutines such as product_proc
4) An automatic exit clause is incorporated, to stop run-on simulations. The VIKAR gives up the ghost when 10000 events have been simulated if the detection efficiency is below 0.1%. If that's a problem - modify the code, or design a better experiment.
5) Output files are generated of ejectile angle vs recoil angle, useful for modelling coincidence
experiments.
6) Numerous debugging activities in files documented above.