1 #ifndef _PhotosDebugRandom_included_
2 #define _PhotosDebugRandom_included_
4 * @class PhotosDebugRandom
6 * @brief Random generator for debugging purposes
8 * Random generator with ability to save and restore state, set custom
9 * state and print current state. This class extends PhotosRandom class.
10 * PhotosRandom is a static class, therefore this extension works
11 * automatically for FORTRAN code without any changes.
12 * Our random generator is the C++ follow-up of FORTRAN generator by
13 * F. James DD-Report, November 1988. and G. Marsaglia and A. Zaman,
16 * @author Tomasz Przedzinski
17 * @date 28th June 2012
20 #include "PhotosRandom.h"
25 class PhotosDebugRandom : PhotosRandom
28 /* Save current state */
29 static void saveState();
31 /* Restore state from save */
32 static void restoreState();
34 /* Set current state provided by user */
35 static void setState(int i, int j, double c, double list[97]);
37 /* Save state provided by user */
38 static void setSaveState(int i, int j, double c, double list[97]);
40 /* Print state in a form that can be easily copied into the code */
46 static double uran_saved[97];
47 static double cran_saved;
50 } // namespace Photospp