*****************************************************************************
**        Hall-A Single Arm Monte Carlo Simulation Tool in C
**--------------------------------------------------------------------------------------------------------------------
**         Release by Zhihong Ye, but most credits are given to Alexander Deur and Huan Yao.
**         09/30/2013
**
** ---- Updated: Fix bugs so the program can be compiled with gfortran on ifarm 64 bit OS. -- 09/15/2014
** ---- Updated: Clean up QFS cross section model in the package. Now the code has no model -- 09/30/2014.

**         630-252-2305, yez@jlab.org
*****************************************************************************
  • Check the files here

  • Download the clean code

  • Download the code with QFS model

  • Download "libg2c.so" ( for f77@32bit only)

  • This is a C++ version of SAMC which was orginally developed by A. Deur using FORTRAN,
    and was converted into a C++ package by Huan Yao. I made some small modification and added a generator.
    The package is released "AS IT IS" and we (especially A. Deur and H. Yao) don't hold any responsibility
    for updating the code, removing bugs, etc. Make sure you know the code well and feel free to do any
    modifications.

    It is a well  organized package and you can use it by only changing the input file, where all parameters
    related to the experimental setup is defined (e.g., c12_input.dat). The generated events are stored in
    a ROOT file. The event seeds can be uniformly generated in the code, or can be specified outside the code
    using a generator (no physics yet) in ./Generator if you have special request.

    The HRS transportation functions were generated using SNACK by J. LeRose and they are coded in the
    FORTRAN subroutines. "libg2c.so" is required to sucessuflly compile this package when using 'F77'.
    If using "gfortran", make sure to use the "-lgfortran" in your C++ complier flag.

    The clean code has no physics models in there but only has the energy loss process.
    You should add you own cross section model in the code (in SAMCEvent.h, Line-445).
    The QFS cross section model is coded in the SAMC_QFS.tar.gz package as an example.